Hey en der ved hvordan jeg gør så den hente et navn med rank cl.
Jeg har en mysql database. hvor tablen hedder "crew" i det er der nogle info's. navn , alder , rank osv
så har jeg en side som viser crew'et.
det står sådan her op:
Team CsC
Cl: blabla
CoCl:
Member:
så tænke på om man kan hente et navn fra databasen med cl i sin rank så det kommer til og stå under Cl.
Crew siden:
<head>
<meta http-equiv="Content-Language" content="da">
</head>
<form name="form1" method="post" action="">
<table border="0" width="430" id="table1" style="border-collapse: collapse" bordercolor="#000000">
<tr>
<td width="205" colspan="2" style="border-bottom-style: solid; border-bottom-width: 1px">
<p align="center"><b><font size="1" face="Verdana">Team CsC</font></b></td>
<td width="20" style="border-bottom-style: none; border-bottom-width: medium" align="center" colspan="2"> </td>
<td width="205" colspan="2" style="border-bottom-style: solid; border-bottom-width: 1px">
<p align="center"><b><font size="1" face="Verdana">Team jr</font></b></td>
</tr>
<tr>
<td width="205" colspan="2" style="border-right-style: none; border-right-width: medium; border-top-style: solid; border-top-width: 1px">
<font size="1"> </font></td>
<td width="10" style="border-left-style: none; border-left-width: medium; border-top-style: solid; border-top-width: 1px; border-bottom-style: none; border-bottom-width: medium" align="center">
<font size="1"> </font></td>
<td width="10" style="border-left-style: solid; border-left-width: 1px; border-right-style: none; border-right-width: medium; border-top-style: solid; border-top-width: 1px; border-bottom-style: none; border-bottom-width: medium" align="center">
<font size="1"> </font></td>
<td width="205" colspan="2" style="border-left-style: none; border-left-width: medium; border-top-style: solid; border-top-width: 1px">
<font size="1"> </font></td>
</tr>
<tr>
<td width="25"><font size="1" face="Verdana">Cl:</font></td>
<td width="185" style="border-right-style: none; border-right-width: medium">
<p align="center"><font face="Verdana" size="1"><?
include ('config.php');
$resultat = mysql_query("select nick from crew ORDER BY rank DESC");
while ($raekke = mysql_fetch_array($resultat)) {
extract($raekke);
echo "$nick";
}
?></font></td>
<td width="6" align="center" style="border-left-style: none; border-left-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style: none; border-bottom-width: medium"> </td>
<td width="9" align="center" style="border-left-style: solid; border-left-width: 1px; border-right-style: none; border-right-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style: none; border-bottom-width: medium"> </td>
<td width="25" style="border-left-style: none; border-left-width: medium">
<font size="1" face="Verdana">CL:</font></td>
<td width="182">
<p align="center"><font face="Verdana" size="1">jr^cl</font></td>
</tr>
<tr>
<td width="50"><font size="1" face="Verdana">Cocl:</font></td>
<td width="185" style="border-right-style: none; border-right-width: medium">
<p align="center"><font face="Verdana" size="1"><?
include ('config.php');
$resultat = mysql_query("select nick from crew ORDER BY rank DESC");
while ($raekke = mysql_fetch_array($resultat)) {
extract($raekke);
echo "$nick";
}
?></font></td>
<td width="6" align="center" style="border-left-style: none; border-left-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style: none; border-bottom-width: medium"> </td>
<td width="9" align="center" style="border-left-style: solid; border-left-width: 1px; border-right-style: none; border-right-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style: none; border-bottom-width: medium"> </td>
<td width="50" style="border-left-style: none; border-left-width: medium">
<font size="1" face="Verdana">Cocl:</font></td>
<td width="182">
<p align="center"><font face="Verdana" size="1">jr^cocl</font></td>
</tr>
<tr>
<td width="50"><font size="1" face="Verdana">Member:</font></td>
<td width="185" style="border-right-style: none; border-right-width: medium">
<p align="center"><font face="Verdana" size="1"><?
include ('config.php');
$resultat = mysql_query("select nick from crew ORDER BY rank DESC");
while ($raekke = mysql_fetch_array($resultat)) {
extract($raekke);
echo "$nick";
}
?></font></td>
<td width="6" align="center" style="border-left-style: none; border-left-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style: none; border-bottom-width: medium"> </td>
<td width="9" align="center" style="border-left-style: solid; border-left-width: 1px; border-right-style: none; border-right-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style: none; border-bottom-width: medium"> </td>
<td width="50" style="border-left-style: none; border-left-width: medium">
<font size="1" face="Verdana">Member:</font></td>
<td width="182">
<p align="center"><font face="Verdana" size="1">jr^member</font></td>
</tr>
<tr>
<td width="50"> </td>
<td width="185" style="border-right-style: none; border-right-width: medium"> </td>
<td width="6" align="center" style="border-left-style: none; border-left-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style: none; border-bottom-width: medium"> </td>
<td width="9" align="center" style="border-left-style: solid; border-left-width: 1px; border-right-style: none; border-right-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style: none; border-bottom-width: medium"> </td>
<td width="50" style="border-left-style: none; border-left-width: medium"> </td>
<td width="182"> </td>
</tr>
<tr>
<td width="235" colspan="2" style="border-bottom-style: solid; border-bottom-width: 1px">
<p align="center"><b><font face="Verdana" size="1">Bnc admins</font></b></td>
<td width="6" align="center" style="border-left-style: none; border-left-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style: solid; border-bottom-width: 1px"> </td>
<td width="9" align="center" style="border-left-style: solid; border-left-width: 1px; border-right-style: none; border-right-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style: solid; border-bottom-width: 1px"> </td>
<td width="232" style="border-left-style: none; border-left-width: medium; border-bottom-style: solid; border-bottom-width: 1px" colspan="2">
<p align="center"><b><font size="1" face="Verdana">Cup admins</font></b></td>
</tr>
<tr>
<td width="235" colspan="2" style="border-top-style: solid; border-top-width: 1px"> </td>
<td width="6" align="center" style="border-left-style: none; border-left-width: medium; border-bottom-style: none; border-bottom-width: medium"> </td>
<td width="9" align="center" style="border-left-style: solid; border-left-width: 1px; border-right-style: none; border-right-width: medium; border-bottom-style: none; border-bottom-width: medium"> </td>
<td width="232" style="border-left-style: none; border-left-width: medium; border-top-style: solid; border-top-width: 1px" colspan="2"> </td>
</tr>
<tr>
<td width="50"><font size="1" face="Verdana">Dansk:</font></td>
<td width="185" style="border-right-style: none; border-right-width: medium">
<p align="center"> </td>
<td width="6" align="center" style="border-left-style: none; border-left-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style: none; border-bottom-width: medium"> </td>
<td width="9" align="center" style="border-left-style: solid; border-left-width: 1px; border-right-style: none; border-right-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style: none; border-bottom-width: medium"> </td>
<td width="50" style="border-left-style: none; border-left-width: medium">
<p align="left"><font face="Verdana" size="1">Gather:</font></td>
<td width="182">
<p align="center"> </td>
</tr>
<tr>
<td width="50"><font size="1" face="Verdana">Engelsk:</font></td>
<td width="185" style="border-right-style: none; border-right-width: medium">
<p align="center"> </td>
<td width="6" align="center" style="border-left-style: none; border-left-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style: none; border-bottom-width: medium"> </td>
<td width="9" align="center" style="border-left-style: solid; border-left-width: 1px; border-right-style: none; border-right-width: medium; border-top-style: none; border-top-width: medium; border-bottom-style: none; border-bottom-width: medium"> </td>
<td width="50" style="border-left-style: none; border-left-width: medium">
<font face="Verdana" size="1">Cup:</font></td>
<td width="182">
<p align="center"> </td>
</tr>
</table>
<table width="49%" border="1" cellpadding="1" cellspacing="1" bordercolor="#000000" style="border-width: 0px">
Som i kan se har jeg lavet så den henter en person men kun hvis det er tal
og den laver bare flere navne i samme felt..
Håber i forstår hvad jeg mener og i vil hjælpe.