Posteado por: djdonovans | septiembre 16, 2010

Simple Banner Rotator con PHP, jQuery & MySQL

Simple Banner Rotator With PHP, jQuery & MySQL, Otra interesante idea para la sección de anunciantes, un simple PHP, jQuery y un banner rotador MySQL, con el que podrás crear y mostrar los avisos al azar en tu sitio. Una interesante idea si no sabes en qué orden acomodar a cada anunciante, que mejor entonces que todo se haga al azar. Cada vez que la pagina se recargue, todos los anunciantes cambiaran de posición por otros, y así sucesivamente. El efecto puede personalizarse para satisfacer sus propias necesidades.

Ver demoDescarga – Mas Info Simple Banner Rotator With PHP, jQuery & MySQL

JavaScript:

$(document).ready(function(){// Lowering the opacity of all slide in divs
$(‘.banner div’).css(‘opacity’,0.4);

// Using the hover method
$(‘.banner’).hover(function(){

// Executed on mouseenter

var el = $(this);

// Find all the divs inside the banner div,
// and animate them with the new size

el.find(‘div’).stop().animate({width:200,height:200},’slow’,function(){
// Show the «Visit Company» text:
el.find(‘p’).fadeIn(‘fast’);
});

},function(){

// Executed on moseleave

var el = $(this);

// Hiding the text
el.find(‘p’).stop(true,true).hide();

// Animating the divs
el.find(‘div’).stop().animate({width:60,height:60},’fast’);

}).click(function(){

// When clicked, open a tab with the address of the hyperlink

window.open($(this).find(‘a’).attr(‘href’));

});
});


Respuestas

  1. muy bueno


Deja un comentario

Categorías