Rotation bannieres pub en html

Résolu
Bonjour,
je recherche un script en html simple pour faire une variation de mes bannières de pub toutes les 25sec.
merci de votre aide.

2 réponses

  1. Bonsoir,
    J'ai trouvé un script en PHP plutôt sympa sur internet, j'espère que cela vas t'être utile. Par contre sa ne varie pas toute les 25 secondes, mais à chaque rafraîchissement. Ce qui est tout autant sympa.
    <?php
     
    /****************************************************
        Tableau associatif des bannieres et banniere choisie
    *****************************************************/
    $tabBannieres = array(
     
        1 => array('http://www.site1.com','1.png','Description  1'),
        2 => array('http://www.site2.com','2.png','Description 2'),
        3 => array('http://www.site3.com','3.png','Description 3')
    );
     
    /****************************************************
        Détermination de la banniere à afficher
    *****************************************************/
    $choix = 1;
    $choix = array_rand($tabBannieres, 1);
     
    /****************************************************
        Affichage des bannieres
    *****************************************************/
    echo '<a href="', $tabBannieres[$choix][0] ,'" title="', $tabBannieres[$choix][2] ,'">';
    echo '<img src="', $tabBannieres[$choix][1] ,'" alt="', $tabBannieres[$choix][2] ,'" />';
    echo '</a>';
     
    ?>