Hey,
Sorry i don't have a live example to show u,
but ill do my best to explain my problem.
Full JQuery code:
Html Element code:Code:$(document).ready(function(){ $('#mainDiv').load("Home.html"); $('li.home').click(function() { $('#mainDiv').load("Home.html"); }); $('li.about').click(function() { $('#mainDiv').load("About.html"); }); $('li.products').click(function() { $('#mainDiv').load("Products.html"); }); $('li.tech').click(function() { $('#mainDiv').load("Technical.html"); }); $('li.palette').click(function() { $('#mainDiv').load("Palette.html"); }); $('li.contact').click(function() { $('#mainDiv').load("Contact.html"); }); $('.palettebtn').click(function() { $('#mainDiv').load("Palette.html"); }); });
The part of the code im having trouble with:Code:<a href="#" class="palettebtn"> <img src="images/Palette.png" width="200" height="200" alt="Palette" border="0"/> </a>
This code used to work fine,Code:$('.palettebtn').click(function() { $('#mainDiv').load("Palette.html"); });
I have looked over it several times and havnt spotted the problem yet.
When i open the web page with the element on my local pc
and when the .palettebtn image is clicked, it sends the user to the top of the screen.
Where it should load "Palette.html" into #mainDiv
I hope i have given enough info
Any input would be appreciated
Thanks



Reply With Quote

Bookmarks