Ajax reloading entire page on href link click
I have a website bui开发者_Python百科lt in ajax. It has both English and French versions. English is at /public_html and french in /public_html/fr.
Ajax is only reloading the middle frame and not the header or footer. So, when I click the link to the French page, it shows it in the middle, but the header and footer are still from the English page.
So, basically a "#" is coming from nowhere when I click the link: eg. http://www.mysite.com/index.html#http://www.mysite.com/fr/index.html
English to French:
<li class="contact"><a href="/fr/index.html">French Version</a></li>
French to English:
<li class="contact"><a href="/index.html">English Version</a></li>
I need that, on click, the entire page is reloaded. What should I do?
Thanks!
I'll take a stab. It sounds like you're describing a framed site with a non-ajax hyperlink in the middle of it. The link is "refreshing" the middle frame because that's where the link is. You can add a target
to the anchor tag to tell it to reload the whole page.
<a href="/fr/index.html" target="_top">French Version</a>
PS While you're at it, don't forget to localize the words "French Version" (Version française? :-)
精彩评论