Twitter share - encoding ampersands


#1

I am using a javascript encoded twitter share link like this:
http://twitter.com/intent/tweet?url=’ + encodeURIComponent(location.protocol + “//” + location.host + “/” + queryString)

However as I can successfully see the fully decoded address with query string on the twitter address bar, the tweet box itself only contains the link till the first ampersand http://www.mysite.com/?param1=true … How can i get the tweet box to show the url with full query string?

Any help will be appreciated!


#2

Can you share an example of the output of the string you’re constructing here? The important part is that the URL has the “&” characters escaped as “%26”


#3

And magically the problem is gone =/ could it have been a case of caching? haven’t found much information about caching from twitter side.

Anyways problem solved!


#4