Quote
-----Original Message-----
Hi...
Howdy.
Quote
I'm using FP2002 and have tried everything I can think
of the achieve a particular mouse over result, but I'm
not quite getting it.
What I'm trying to do is illustrated on this page:
www.jjdonline.com/html_files/design/printtable-">www.jjdonline.com/html_files/design/printtable-
r.html
I want to be able to change the numbers -- as in having
them circled when the mouse is over them -- AND change
the larger photo at the top of the page. I've figured
out how to use the DHTML toolbar (Format>Dynamic HTML
Effects) to change an image (swap picture) when the
mouse is over it (or the mouse is clicked), but I can't
figure out how to have the mouse over one image change
both that image AND another image at the same time. As
on the page linked above, the mouse over the small
numbers changes the image of the number to include the
small circle, AND it changes the larger image above.
FrontPage 2002 can't do this through the GUI, but you can
do it in JavaScript. First, in the <head>section, add
some code like the following:
<script>
var b1ovr= new Image() ; b1ovr.src = "images/b1ovr.gif";
var b1out= new Image() ; b1out.src = "images/b1out.gif";
var b1oth= new Image() ; b1oth.src = "images/b1oth.gif";
var b2ovr= new Image() ; b2ovr.src = "images/b2ovr.gif";
var b2out= new Image() ; b2out.src = "images/b2out.gif";
var b2oth= new Image() ; b2oth.src = "images/b2oth.gif";
function flipPics(btnName, imgBtn, imgOther) {
if (document.images){
document[btnName].src = eval(imgBtn + ".src");
document.otherpic.src = eval(imgOther + ".src");
}
return true;
}
</script>
Where:
b1out.gif is the normal picture for button 1.
b1ovr.gif is the mouseover picture for button 1.
b1oth.gif is the picture located elsewhere for button 1.
and so forth for each button. Then, code each button like
this:
<a href="javascript:nothing();"
onmouseover="flipPics('btnTwo','b2ovr','b2oth')"
onmouseout="flipPics('btnTwo','b2out','b1oth')">
<img name="btnTwo" src="../images/b2out.gif"
border="0"</a>
The href= location can, of course, be any valid URL.
The first argument to flipPics specifies the name of the
button picture (the value of its name= attribute).
The second argument specifies the name of the image
object that will replace the normal button picture.
The third argument specifies the name of the image object
that will replace the picture located elsewhere on the
page.
FP2003 *can* do this through the GUI. You might want to
consider upgrading rather than spending money on a FP2002
add-in.
Jim Buyens
Microsoft FrontPage MVP
www.interlacken.com">
www.interlacken.com
Author of:
*----------------------------------------------------
|\---------------------------------------------------
|| Microsoft Office FrontPage 2003 Inside Out
|| Microsoft FrontPage Version 2002 Inside Out
|| Web Database Development Step by Step .NET Edition
|| Troubleshooting Microsoft FrontPage 2002
|| Faster Smarter Beginning Programming
|| (All from Microsoft Press)
|/---------------------------------------------------
*----------------------------------------------------
-