phatruss
08-10-2005, 01:38 AM
Ok this is what I am trying to do. If you would kindly take a look at this page:
http://www.templatehelp.com/aff/preview.php?aff=coolhomepages&skin=22&locale=en¤cy=0&pr=yes&src=yes&nt=yes&help=yes&sample=yes&faq=yes&nmg=yes&auth=yes&down=yes&chm=&hide_flash=0&search=&PHPSESSID=aa542ba9363d1d51f823461b1e768be1&referer=http%3A%2F%2Fwww.coolhomepages.com%2Fstore%2Ftemplatemonster_page2.html&i=8851
the images are controlled by little links on the bottom. I am trying to achieve this through some scripting. I think I may have something. (I am by no means a coder myself, I just like to tinker and mess around). This is the code I have.
Can someone who is good at this tell me how I can change/add my code to get the effect I am looking for ???
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<title>Untitled</title>
<script language="JavaScript1.2" type="text/javascript">
var current = 1
function loadintoIframe(iframeid, url){
if (document.getElementById)
document.headerpic.src=url
}
function nextpage()
{
if (current >=6) {
current = 1
} else {
current = current + 1;
}
document.headerpic.src=current+".html";
}
function prevpage()
{
if (current <=1) {
current = 6
} else {
current = current - 1;
}
document.headerpic.src=current+".html";
}
</script>
</head>
<body bgcolor="#FF9F40" leftmargin=0 topmargin=0>
<table width="660" border="0" cellspacing="0" cellpadding="0" align="center" bgcolor="White">
<tr valign="top">
<td valign="top" align="center">
<iframe src="1.html" name="headerpic" id="headerpic" width="660" height="290" marginwidth="0" marginheight="0" align="middle" scrolling="no" frameborder="0"></iframe>
</td>
</tr>
<tr>
<td align="center">
<form>
<img src="leftarrow.gif" onclick='prevpage()' value='PREVIOUS' javascript:loadintoIframe('headerpic')>
<img src="rightarrow.gif" onclick='nextpage()' value='NEXT' javascript:loadintoIframe('headerpic')>
</form>
</td>
</tr>
</table>
</body>
</html>
I know what I have there is probally totally wrong. But I am trying...
Thanks,
Russ
http://www.templatehelp.com/aff/preview.php?aff=coolhomepages&skin=22&locale=en¤cy=0&pr=yes&src=yes&nt=yes&help=yes&sample=yes&faq=yes&nmg=yes&auth=yes&down=yes&chm=&hide_flash=0&search=&PHPSESSID=aa542ba9363d1d51f823461b1e768be1&referer=http%3A%2F%2Fwww.coolhomepages.com%2Fstore%2Ftemplatemonster_page2.html&i=8851
the images are controlled by little links on the bottom. I am trying to achieve this through some scripting. I think I may have something. (I am by no means a coder myself, I just like to tinker and mess around). This is the code I have.
Can someone who is good at this tell me how I can change/add my code to get the effect I am looking for ???
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<title>Untitled</title>
<script language="JavaScript1.2" type="text/javascript">
var current = 1
function loadintoIframe(iframeid, url){
if (document.getElementById)
document.headerpic.src=url
}
function nextpage()
{
if (current >=6) {
current = 1
} else {
current = current + 1;
}
document.headerpic.src=current+".html";
}
function prevpage()
{
if (current <=1) {
current = 6
} else {
current = current - 1;
}
document.headerpic.src=current+".html";
}
</script>
</head>
<body bgcolor="#FF9F40" leftmargin=0 topmargin=0>
<table width="660" border="0" cellspacing="0" cellpadding="0" align="center" bgcolor="White">
<tr valign="top">
<td valign="top" align="center">
<iframe src="1.html" name="headerpic" id="headerpic" width="660" height="290" marginwidth="0" marginheight="0" align="middle" scrolling="no" frameborder="0"></iframe>
</td>
</tr>
<tr>
<td align="center">
<form>
<img src="leftarrow.gif" onclick='prevpage()' value='PREVIOUS' javascript:loadintoIframe('headerpic')>
<img src="rightarrow.gif" onclick='nextpage()' value='NEXT' javascript:loadintoIframe('headerpic')>
</form>
</td>
</tr>
</table>
</body>
</html>
I know what I have there is probally totally wrong. But I am trying...
Thanks,
Russ