We're using Google Translate on our site. When we translate a page and hit a regular link to another page, it displays as translated (that's what we want), however when selecting one of our navigation links (which are javascript includes), the new page goes back to English. Does anyone have a workaround for this? Here's an example of a javascript include for navigation:
<div style="text-align:center; margin-top:20px;" class="localTxtNav">
<script type="text/javascript">
var loc;
loc == "home_index";
if (loc == null || loc.length == 0) {loc = "x";}
if (loc == "home_index") {document.write("| Police Department Home ");}
else {document.write("| <a href=\"/police/\">Police Department Home</a> ");}
if (loc == "help_index") {document.write("| Help Us Help You ");}
else {document.write("| <a href=\"/police/help/\">Help Us Help You</a> ");}
if (loc == "recruit_index") {document.write("| Join the SDPD |");}
else {document.write("| <a href=\"/police/recruiting/\">Join the SDPD</a> |");}
</script>
</div>
Any assistance would be most appreciated.
<div style="text-align:center; margin-top:20px;" class="localTxtNav">
<script type="text/javascript">
var loc;
loc == "home_index";
if (loc == null || loc.length == 0) {loc = "x";}
if (loc == "home_index") {document.write("| Police Department Home ");}
else {document.write("| <a href=\"/police/\">Police Department Home</a> ");}
if (loc == "help_index") {document.write("| Help Us Help You ");}
else {document.write("| <a href=\"/police/help/\">Help Us Help You</a> ");}
if (loc == "recruit_index") {document.write("| Join the SDPD |");}
else {document.write("| <a href=\"/police/recruiting/\">Join the SDPD</a> |");}
</script>
</div>
Any assistance would be most appreciated.