Jo has attended:
Dreamweaver 8 Introduction course
My rollover isn't working!
(now using MX).
I am trying to create a rollover image but it doesn't seem to be working. I've copied the CSS below - hoping you might be able to identify why it doesn't work when I F12. Thanks! Jo
</tr>
</table> </td>
<td> </td>
<td height="299" colspan="2" align="center" valign="top"><div align="center"><!-- InstanceBeginEditable name="Editable region_picture1" --><a href="#" onMouseOut="MM_swapImgRestore()" onMouseOver="MM_swapImage('About Us','','Images/Berkscoll374x250.jpg',0)"><img src="Images/about_us336x250.jpg" name="About Us" width="374" height="250" border="0"></a><!-- InstanceEndEditable --></div></td>
</tr>
<tr>
RE: My rollover isn't working!
Hi Jo,
Thanks for your question.
The mark-up looks fine to me, so there maybe another problem.
a) do both images exist? ie. can you see about_us336x250.jpg and Berkscoll374x250.jpg in the Images folder. Check for case of characters within the filename too, sometimes this can cause problems. (ie. Berkscoll and berkscoll are completely different)
Ensure your Images folder is within the same folder as your HTML file that the rollover appears on.
b) sometimes the roll-over works online, but not when you check it using F12 (local) - have you uploaded the file to your web server and checked it online (ensure images are uploaded too)
c) The MM_swapImgRestore and MM_swapImage functions are not linked or included in your file. Check your source code between the HEAD tags. Are these functions declared here? If not, check any <script> tags for references to .js files. If there is a link to a .js file, open it in Dreamweaver and see if the functions are declared there.
If they're not declared or linked, then your browser (F12) has no idea about the functions. To fix this problem:
- remove your rollover
- ensure there is an editable region between the HEAD tags (you may have to create the region)
- insert the rollover again
If this fails, please send the whole HTML file to me via forum@stl-training.co.uk and I'll have a look.
If this answer resolves your query, please mark the question as 'resolved' (see below). Otherwise, please post a follow-up response to this post, and I will assist you further.
Regards, Rich