Ok i recon if you can get this sorted it should be done...
I'm not sure if this is possible but what i'd like to do is to have only the option available that will change the text instead of always having both options like in the site at the moment: www.ace-translation.com.
So if the paragraph...
There is another problem. If there is another link on the page (like the logo link in the code) the "change all" function doen't work...! Any ideas.
The code below simplifies what I'm trying to do on this link: http://www.ace-translation.com/
<html>
<head>
<title></title>
<script...
Works absolutely perfectly! Nice one! Many thanks!
<html>
<head>
<title></title>
<script type="text/javascript">
var ori=new Array();
function makeTxt(id,txt)
{
var obj=document.getElementById(id);
if (!ori[id]) ori[id]=obj.innerHTML;
obj.innerHTML=txt;
}
function reTxt(id)
{
var...
One more thing...
Is there any way of changing and restoring all of them (if you have multiple instances on a page)? something like this:
<html>
<head>
<title></title>
<script type="text/javascript">
var ori=new Array();
function makeTxt(id,txt)
{
var obj=document.getElementById(id);
if...
I'm building a translation website and need to be able to toggle the content of div tags to show how a paragraph looks in each language.
I have used the following code, which works fine:
<script type="text/javascript">
function makeTxt(id,txt){
var obj = document.getElementById(id)...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.