I was looking at the code posted in another thread by herodote92 shown below
[code]
<html>
<head>
<script language=’javascript’>
function ChangeIt() {
document.getElementById(‘my_link’).href =’http://www.altavista.com’;
document.getElementById(‘my_image’).src =’image2.gif’;
}
</script>
</head>
<body>
<table>
<tr>
<td>
<a href=’http://www.google.com’ id=’my_link’>
<image src=’image1.gif’ id=’my_image’></a>
</td>
<td>
<input type=’button’ onclick=’ChangeIt();’ value=’Click here to change’>
</td>
</tr>
</table>
</body>
</html>
[code]
I have been several hours using my limited javascript knowledge trying to adapt this for text links instead of image.
I have given up for now… need to read my books more!!!:D
Would it be possible to select the text- tip[idx] and the link – link[idx] from an array?:confused: