Trent Cruising « visit
This is my Source Code and I don't want to show it here
View Source Code only (as overlay)
// That code snippet belongs to Trent Cruising - http://trentcruising.com
$(document).ready(function(){
// remove link background images since we're re-doing the hover interaction below
// (doing it this way retains the CSS default hover states for non-javascript-enabled browsers)
// we also want to only remove the image on non-selected nav items, so this is a bit more complicated
$(".nav").children("li").each(function() {
var current = "nav current-" + ($(this).attr("class"));
var parentClass = $(".nav").attr("class");
if (parentClass != current) {
$(this).children("a").css({backgroundImage:"none"});
}
});
// create events for each nav item
attachNavEvents(".nav", "p1");
attachNavEvents(".nav", "p2");
attachNavEvents(".nav", "p3");
attachNavEvents(".nav", "p4");
attachNavEvents(".nav", "p5");
attachNavEvents(".nav", "p6");
attachNavEvents(".logo");
function attachNavEvents(parent, myClass) {
$(parent + " ." + myClass).mouseover(function() {
$(this).append('<div class="nav-' + myClass + '"></div>');
$("div.nav-" + myClass).css({display:"none"}).fadeIn(400);
}).mouseout(function() {
$("div.nav-" + myClass).fadeOut(200, function() {
$(this).remove();
});
}).mousedown(function() {
$("div.nav-" + myClass).attr("class", "nav-" + myClass + "-click");
}).mouseup(function() {
$("div.nav-" + myClass + "-click").attr("class", "nav-" + myClass);
});
}
$(".leftnav a").not(".leftnav .selected a").hover(function() {
$(this).stop().animate({paddingLeft: "12px"}, 400);
}, function() {
$(this).stop().animate({paddingLeft: "0px"}, 200);
});
$(".logo").hover(function(){
$(this).stop().fadeTo(400, 0.7); // This should set the opacity to 100% on hover
},function(){
$(this).stop().fadeTo(200, 1.0); // This should set the opacity back to 60% on mouseout
});
$( "#footer a.more").hover(function(){
$(this).stop().fadeTo(400, 0.7); // This should set the opacity to 100% on hover
},function(){
$(this).stop().fadeTo(200, 1.0); // This should set the opacity back to 60% on mouseout
});
});
Syndicate
Categories
Statistics
There are 330 Sites with 745 Links of Interest in 18 Categories. The latest Site was added 4 months ago.
About
This is a project by Sebastian Senf, for his part jQuery user and lover too. Follow me.