javascript - Location.href and urlrewriting -


hi have urlrewriting in application. this;

www.mydomain.com/pmillio

i using location.href url in 1 of functions,

location.href gives me www.mydomain.com/pmillio

however need change url looks instead;

www.mydomain.com/user-profile.aspx?username=pmillio

how go doing this?

this should it...

location = 'user-profile.aspx?username=' + (location.pathname).replace('/',''); 

Comments

Popular posts from this blog

c# - SharpSVN - How to get the previous revision? -

c++ - Is it possible to compile a VST on linux? -

url - Querystring manipulation of email Address in PHP -