What's new
HTML Forums | An HTML and CSS Coding Community

Welcome to HTMLForums; home of web development discussion! Please sign in or register your free account to get involved. Once registered you will be able to connect with other members, send and receive private messages, reply to topics and create your very own. Our registration process is hassle-free and takes no time at all!

Change HTML url of current EN html page to link to FR html page

slang7575

New member
I have a site with english and french pages. 1200 each. On the english pages, I'd like users to be able to click a 'french' link that would automatically take them to the French version of the page. SAME URL only /french/ now instead of /english/ and vice versa on the French pages, an English link.

So if my url structure is like this:
files/english/service/home.htm

I'd like the 'french' link to point to:
files/francais/service/home.htm

and vice versa on the French pages, an English link.


Can someone please offer me the code to take the current page url, and substitute ONLY the /english/ for /francais/ in the link code?
I would like to add the code to each of the pages. To make jumping between English and French easier.
 
Back
Top