Double barre de soulignement [resolu]

Double barre de soulignement [resolu] - PHP - Programmation

Marsh Posté le 01-05-2008 à 18:52:43    

Bonjour à tous  
 
j'ai trouvé à scrypt de pagination que j'ai accomodé à ma sauce tout marche mais lorsque je fais sur la page concerné il y a une double barre de soulignement dans les titres une fois sur trois:   http://www.devouring.eu/index.php
 
 
quelqu'un pourrai m'expliquer pourquoi ca fait ca? ? ?
 
voici le code de la page  
 
 

Citation :

<html>
   <head>
       <title>Bienvenue sur mon site</title>
        <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
        <style type="text/css">
  a
{
background-color:bef7fb; color:00adef; text-align:left; font-family:verdana,Arial,Helvetica,Sans-serif; font-size:11px; text-decoration:none; border:1px ; margin:1px; padding:1px;
}
a:hover
{
background-color:bef7fb; color:a5ae51; font-weight:bold;
text-align:left;
}
p
{
font-family: verdana,Arial,Helvetica,Sans-serif; font-size: 11px; color:626262; bgcolor:ffffff; text-decoration:none;  
}
.text {  font-family: Arial, Helvetica, sans-serif; font-size: 11px; font-style: normal; line-height: normal; font-weight: normal; font-variant: normal; text-transform: none; color: #535252}
 
   .pagination a {color: black;}
 .pagination a:hover {color: red; text-decoration: none;}
 .pagination a:visited {color: red; text-decoration: none;}
        </style>
    </head>
     
    <body bgcolor="#bef7fb" text="#535252">
    <?
 $host = "XXX";
 $user = "XXX";
 $pass = "XXX";
 $data = "XXX";  
 $connect = mysql_connect($host, $user, $pass)
 or die("Connexion au serveur impossible !" );
 $db = mysql_select_db($data, $connect)
 or die("Sélection de la base impossible !" );  
 
 
 $table = "news";  
 $champ = "id";  
 $sql = "SELECT * FROM news";  
 
$parpage = 5;  
 $url = $_SERVER['PHP_SELF']."?limit=";
 $total = mysql_query($sql);  
 $nblignes = mysql_num_rows($total);  
 
 
 $nbpages = ceil($nblignes/$parpage);
 
 
 $result = validlimit($nblignes,$parpage,$sql);
 
 
 
 
while ($donnees = mysql_fetch_array($result))
 
//C'est ici que mes news s'affichent
 
{
?>
<p class="text">
<div style="font-family:Century Gothic; font-size: 16px; margin-bottom:1px; font-style: normal; line-height: normal; font-weight: normal; font-variant: small-caps; text-transform: none; color:ff00f6; border-bottom:1pt #ff00f6 solid">
 
        <?php echo $donnees['titre']; ?>
         
    </div>
     
 
    <div style="font-family: Arial, Helvetica, sans-serif; font-size: 11px; font-style: normal; line-height: normal; font-weight: normal; font-variant: normal; text-transform: none;  text-align:justify; padding:3px; margin-top:5px; margin-bottom:30px; color:535252">
    <?php
     
    $contenu = nl2br(stripslashes($donnees['contenu']));
    echo $contenu;
    ?><br>
   
</div>
 
<?php
}
 
 
 
 
 
 echo "<div class='pagination'>";
 echo '<p align="center">Page : ';
 echo pagination($url,$parpage,$nblignes,$nbpages);
 echo '</p>';
 echo "</div>";
 
 
 mysql_free_result($result);
 
 function pagination($url,$parpage,$nblignes,$nbpages)
 {
 
 $html = precedent($url,$parpage,$nblignes);  
 if ($nbpages > 1) {
 
 for ($i = 0 ; $i < $nbpages ; ++$i) {
 $limit = $i * $parpage;
 $limit = $limit.",".$parpage;  
 
 $html .= "<a href=".$url.$limit.">".($i + 1)."</a> | " ;
 }
 }
 
 else {
 $html .= "";
 }
 $html .= suivant($url,$parpage,$nblignes);  
 return $html;
 }
 function validlimit($nblignes,$parpage,$sql)
 {
 
 if (isset($_GET['limit'])) {
 $pointer = split('[,]', $_GET['limit']);  
 $debut = $pointer[0];
 $fin = $pointer[1];
 
 if (($debut >= 0) && ($debut < $nblignes) && ($fin == $parpage)) {
 
 $limit = $_GET['limit'];
 $sql .= " LIMIT ".$limit.";";  
 $result = mysql_query($sql);  
 }
 
 else {
 $sql .= " LIMIT 0,".$parpage.";";  
 $result = mysql_query($sql);  
 }
 }
 
 else {
 $sql .= " LIMIT 0,".$parpage.";";  
 $result = mysql_query($sql);
 }
 
 return $result;
 }
 function precedent($url,$parpage,$nblignes)
 {
 
 if ($nblignes > $parpage) {
 
 if (isset($_GET['limit'])) {
 
 $pointer = split('[,]', $_GET['limit']);
 
 $pointer = $pointer[0]-$parpage;
 
 if ($pointer < 0) {
 $precedent = "";
 }
 
 else {
 $limit = "$pointer,$parpage";
 $precedent = "<a href=".$url.$limit."><</a> | ";
 }
 }
 else {
 $precedent = "";  
 }
 }
 else {
 $precedent = "";  
 }
 return $precedent;
 }
 function suivant($url,$parpage,$nblignes)
 {
 
 if ($nblignes > $parpage) {
 
 if (isset($_GET['limit'])) {
 
 $pointer = split('[,]', $_GET['limit']);
 
 $pointer = $pointer[0] + $parpage;
 
 if ($pointer >= $nblignes) {
 $suivant = "";
 }
 
 else {
 $limit = "$pointer,$parpage";
 $suivant = "<a class='pagination' href=".$url.$limit.">></a>";
 }
 }
 
 if (@$_GET['limit']== false) {
 $suivant = "<a href=".$url.$parpage.",".$parpage.">></a>";
 }
 }
 else {
 $suivant = "";  
 }
 return $suivant;
 }
 
 ?>  
 
 
</body>
</html>


Message édité par strossus le 01-05-2008 à 23:28:09
Reply

Marsh Posté le 01-05-2008 à 18:52:43   

Reply

Marsh Posté le 01-05-2008 à 22:23:05    

J'ai pas regardé ton code, mais ta CSS fixe le border-bottom-width à "1pt".  Avec 1pt = 1/72in. Bref, il y a peu de chance que ça tombe sur un pixel exactement. Si tu veux que ça tombe sur 1 pixel, bah mets "1px".

Reply

Marsh Posté le 01-05-2008 à 23:27:45    

merci je me doutait que ca venais d'un probleme de style et pas de code mais je voyais pas d'où d'autant que sur ma page HTML qui avait le meme style ca marchait nickel  
en tout cas merci ca fonctionne

Reply

Sujets relatifs:

Leave a Replay

Make sure you enter the(*)required information where indicate.HTML code is not allowed