Prb liste deroulante php css
Résolu
mariline285
Messages postés
76
Date d'inscription
Statut
Membre
Dernière intervention
-
mariline285 Messages postés 76 Date d'inscription Statut Membre Dernière intervention -
mariline285 Messages postés 76 Date d'inscription Statut Membre Dernière intervention -
Bonjour à tous,
J ai un petit probleme j aimerai mettre une liste déroulante dan mon tableau(le premier) mais sa marche pas.
QUELQU UN PEUT M AIDER SVP????
voici mon code:
<style>
/* Affiche le titre de la description */
.titre
{
position :absolute;
overflow : auto;
width:100%;
top: 65%;
height:5%;
background-color:#33CCFF;
}
/* Affiche la description du ticket*/
.description
{
position :fixed;
overflow : auto;
width:100%;
top: 70%;
height:25%;
background-color:#33CCFF;
}
.enteteListe {
position : absolute;
width:100%;
top:20%;
/*background-color : blue;*/
}
.contenuListe {
position : absolute;
width:100%;
top:20%;
height : 40%;
overflow : auto;
float : center;
}
.listeMesTickets {
width : 100%;
}
.listeMesTickets th {
background-color : blue;
color : white;
}
.listeMesTickets a {
color : white;
text-decoration : none;
}
</style>
<?php
$html = "<table class=\"listeMesTickets\">";
$html .= "<div class=\"enteteListe\">";
$html .= "<tr><th><a href=\"#\">NOM</a></th><th><a href=\"#\">PRENOM</a></th></tr>";
$html .= "</div>";
$html .= "<input type=\"hidden\" name=\"oldId\" id=\"oldId\" value=\"null\">";
$html .= "<div class=\"contenuListe\">";
$html .= "<tr class=\"tr_Normal\"><td>TOTO</td><td>TOTO</td></tr>";
$html .= "<tr class=\"tr_Normal\"><td>TOTO</td><td>TOTO</td></tr>";
$html .= "<tr class=\"tr_Normal\"><td>TOTO</td><td>TOTO</td></tr>";
$html .= "<tr class=\"tr_Normal\"><td>TOTO</td><td>TOTO</td></tr>";
$html .= "<tr class=\"tr_Normal\"><td>TOTO</td><td>TOTO</td></tr>";
$html .= "<tr class=\"tr_Normal\"><td>TOTO</td><td>TOTO</td></tr>";
$html .= "</div>";
$html .= "</table>";
echo $html;
// Affiche la titre Description du Ticket
$html ="<div align=center class=\"titre\">";
$html .="<TABLE><tr><th><font color=\"black\">DESCRIPTION DU TICKET : </font></th></tr></table></div>";
echo $html;
// Affiche la description selon la ligne selectionnée
$html ="<div class=\"description\">";
$html .="<TABLE><tr><td id=\"description\"></td></tr>";
$html .="</table></div>";
echo $html;
?>
J ai un petit probleme j aimerai mettre une liste déroulante dan mon tableau(le premier) mais sa marche pas.
QUELQU UN PEUT M AIDER SVP????
voici mon code:
<style>
/* Affiche le titre de la description */
.titre
{
position :absolute;
overflow : auto;
width:100%;
top: 65%;
height:5%;
background-color:#33CCFF;
}
/* Affiche la description du ticket*/
.description
{
position :fixed;
overflow : auto;
width:100%;
top: 70%;
height:25%;
background-color:#33CCFF;
}
.enteteListe {
position : absolute;
width:100%;
top:20%;
/*background-color : blue;*/
}
.contenuListe {
position : absolute;
width:100%;
top:20%;
height : 40%;
overflow : auto;
float : center;
}
.listeMesTickets {
width : 100%;
}
.listeMesTickets th {
background-color : blue;
color : white;
}
.listeMesTickets a {
color : white;
text-decoration : none;
}
</style>
<?php
$html = "<table class=\"listeMesTickets\">";
$html .= "<div class=\"enteteListe\">";
$html .= "<tr><th><a href=\"#\">NOM</a></th><th><a href=\"#\">PRENOM</a></th></tr>";
$html .= "</div>";
$html .= "<input type=\"hidden\" name=\"oldId\" id=\"oldId\" value=\"null\">";
$html .= "<div class=\"contenuListe\">";
$html .= "<tr class=\"tr_Normal\"><td>TOTO</td><td>TOTO</td></tr>";
$html .= "<tr class=\"tr_Normal\"><td>TOTO</td><td>TOTO</td></tr>";
$html .= "<tr class=\"tr_Normal\"><td>TOTO</td><td>TOTO</td></tr>";
$html .= "<tr class=\"tr_Normal\"><td>TOTO</td><td>TOTO</td></tr>";
$html .= "<tr class=\"tr_Normal\"><td>TOTO</td><td>TOTO</td></tr>";
$html .= "<tr class=\"tr_Normal\"><td>TOTO</td><td>TOTO</td></tr>";
$html .= "</div>";
$html .= "</table>";
echo $html;
// Affiche la titre Description du Ticket
$html ="<div align=center class=\"titre\">";
$html .="<TABLE><tr><th><font color=\"black\">DESCRIPTION DU TICKET : </font></th></tr></table></div>";
echo $html;
// Affiche la description selon la ligne selectionnée
$html ="<div class=\"description\">";
$html .="<TABLE><tr><td id=\"description\"></td></tr>";
$html .="</table></div>";
echo $html;
?>
A voir également:
- Prb liste deroulante php css
- Liste déroulante excel - Guide
- Liste déroulante en cascade - Guide
- Liste déroulante google sheet - Accueil - Guide bureautique
- Liste code ascii - Guide
- Easy php - Télécharger - Divers Web & Internet
3 réponses
une liste déroulant s'écrit comme ceci :
<SELECT size=1 NAME="lenom">
<OPTION VALUE="valeur de l'option 1">option1</option>
<OPTION VALUE="valeur de l'option2"> option 2</option>
</SELECT>
<SELECT size=1 NAME="lenom">
<OPTION VALUE="valeur de l'option 1">option1</option>
<OPTION VALUE="valeur de l'option2"> option 2</option>
</SELECT>
pour le problème 2 je pense que sa vient de là :
met plutot :
pour l'autre essai de jouer avec les float et essai en enlevant les positions
$html .= "<tr class=\"tr_Normal\"><td>TOTO</td><td>TOTO</td></tr>"; $html .= "</div>"; $html .= "</table>"; echo $html;
met plutot :
$html .= "<tr class=\"tr_Normal\"><td>TOTO</td><td>TOTO</td></tr>"; $html .= "</table>"; $html .= "</div>"; echo $html;
pour l'autre essai de jouer avec les float et essai en enlevant les positions
Bonjour.
Premier point : Ne jamais mettre de DIV dans un TABLEau !
Ici, tu dis "je mets un bloc TABLEau, à l'intérieur duquel je mets un bloc DIVers. Et à l'intérieur de ce bloc DIVers, je mets des lignes de tableau TR." C'est incohérent...
Deuxième point : A quoi sert ton <input> ?
Surtout que normalement, il devrait être dans un FORMulaire...
Troisième point : Que veux tu dire, quand tu parles de curseur ?
Quatrième point : Si je comprends bien, tu veux avoir, si besoin, un scroll dans ton tableau "PRENOM-NOM" pour ne pas empièter sur ton tableau DESCRIPTION DU TICKET ?
=> Structure du html (je te laisse le soin de faire le php ;-)
Tu définis un bloc DIV avec une hauteur fixée, et un scroll si besoin (overflow:auto).
A l'intérieur, tu mets un tableau. Si la taille du tableau est supérieure à celle du DIV, tu auras le scroll.
Problème : l'en-tête du tableau est victime du scroll... Solution : je n'en ai pas d'élégante, mais en bidouillant :
Sinon, vas voir ICI, ça a l'air de correspondre à ce que tu veux...
Premier point : Ne jamais mettre de DIV dans un TABLEau !
Ici, tu dis "je mets un bloc TABLEau, à l'intérieur duquel je mets un bloc DIVers. Et à l'intérieur de ce bloc DIVers, je mets des lignes de tableau TR." C'est incohérent...
Deuxième point : A quoi sert ton <input> ?
Surtout que normalement, il devrait être dans un FORMulaire...
Troisième point : Que veux tu dire, quand tu parles de curseur ?
Quatrième point : Si je comprends bien, tu veux avoir, si besoin, un scroll dans ton tableau "PRENOM-NOM" pour ne pas empièter sur ton tableau DESCRIPTION DU TICKET ?
=> Structure du html (je te laisse le soin de faire le php ;-)
<div class="contenuListe"> <table class="listeMesTickets"> <th>...</th> <tr>...</tr> ... </table> </div>
Tu définis un bloc DIV avec une hauteur fixée, et un scroll si besoin (overflow:auto).
A l'intérieur, tu mets un tableau. Si la taille du tableau est supérieure à celle du DIV, tu auras le scroll.
Problème : l'en-tête du tableau est victime du scroll... Solution : je n'en ai pas d'élégante, mais en bidouillant :
<table class="entete"> <th>...</th> </table> <div class="contenuListe"> <table class="contenu"> <tr>...</tr> ... </table> </div>
Sinon, vas voir ICI, ça a l'air de correspondre à ce que tu veux...
VOUS POUVEZ M AIDER SVPPPP
MERCI