devote / HTML5-History-API

HTML5 History API expansion for browsers not supporting pushState, replaceState
http://spb-piksel.ru
MIT License
1.02k stars 182 forks source link

Url changes not as expected in IE8 #51

Closed juliogc closed 10 years ago

juliogc commented 10 years ago

It works really fine in all browsers, but in IE8 I'm having a few problems with the url redirect. Let me explain:

This is my website url: http://www.sampleurl.com

And this is the expected url to my campaign: http://www.sampleurl.com/mycampaign

I know that a hash (#) will appear in IE8, so the expected url is: http://www.sampleurl.com/#/mycampaign

But, when I access the direct url 'http://www.sampleurl.com/mycampaign' it is changed to: http://www.sampleurl.com/#!/mycampaign With an ! after the hash

And this is breaking the correctly functionality of the redirect. Someone has any idea how this can be fixed?

devote commented 10 years ago

try include script as src="history.js?type=/"

juliogc commented 10 years ago

This solved the problem, thank you so much!