Hi,
I'm currently using the below script to load content on click of a link. What I would like to know is it possible to visit the url services.html#serviceone
which would then show the content and the active link for that ID?
$(document).ready(function () {
$('#content div.wrap').hide(); // Hide all divs
$('#content div.wrap:first').show(); // Show the first div
$('#tabs ul li a:first').addClass('active'); // Set the class of the first link to active
$('#tabs ul li a').click(function () { //When any link is clicked
$('#tabs ul li a').removeClass('active'); // Remove active class from all links
$(this).addClass('active'); //Set clicked link class to active
var currentTab = $(this).attr('href'); // Set variable currentTab to value of href attribute of clicked link
$('#content div.wrap').hide(); // Hide all divs
$(currentTab).fadeIn('normal'); // Show div with id equal to variable currentTab
return false;
});
});
Hopefully what I'm asking makes some sense. Much appreciated.