PHP
-
Hi!
Also ich hab da eine DB-Abfrage, aber der zeigt mir nur folgende Fehlermeldung:Parse error: parse error in /data/members/free/tripod/de/m/a/t/matib87/htdocs/auf.php on line 85
Mein Prob daran: die Datei hat nur 84 lines!!!
hier mal der Source (hab unwichtige Teile rausgenommen)
<HEAD> <title>-YPC- Yoyota Pool Clan</title> <style type='text/css'> a:link, a:active, a:visited { text-decoration:none; font-family:verdana; color:#000000; font-size:smaller; font-weight:light; } a:hover { text-decoration:none; font-family:verdana; color:#777777; font-size:smaller; font-weight:light; } </style> </HEAD> <body bgcolor="#dddddd"> <table border="1" bordercolor="#000000" cellspacing="5" cellpadding="5" width="100%"> <tr> ... </tr> <tr> <td bgcolor="#bbbbbb"> <br><br><br><center> <table border="1" bgcolor="#dddddd" bordercolor="#000000" cellspacing="5" cellpadding="5" width="95%"> <tr> .... </tr> <?php $db = mysql_connect(); $sql="SELECT * FROM auf ORDER BY auf"; $res=mysql_query($sql, $db); while ($a = mysql_fetch_object ($res)) { print "<tr>"; print "<td bgcolor=#bbbbbb>$a->nick</td>"; print "<td bgcolor=#bbbbbb>$a->match</td>"; print "<td bgcolor=#bbbbbb>$a->gew</td>"; $verl=$a->match - $a->gew; print "<td bgcolor=#bbbbbb>$verl</td>"; print "<td bgcolor=#bbbbbb>$a->pl</td>"; print "<td bgcolor=#bbbbbb>$a->min</td>"; $diff=$a->pl - $a->min; print "<td bgcolor=#bbbbbb>$diff</td></tr> } mysql_free_result ($res); ?> </table></center> </td> </tr> </table> </body> <noscript><noscript><plaintext>
P.S.: Funktionieren arithmetische Operatoren in PHP wie bei C++?
-
MasterDeath schrieb:
Mein Prob daran: die Datei hat nur 84 lines!!!
Dann ist wohl vorher was schief gelaufen.
MasterDeath schrieb:
print "<td bgcolor=#bbbbbb>$diff</td></tr>
Fehlt in der Zeile nicht was? (psssst ";)
MasterDeath schrieb:
P.S.: Funktionieren arithmetische Operatoren in PHP wie bei C++?
Die funktionieren genau so wie du es in der Schule gelernt hast.
Addition: $a + $b
Subtraktion: $a - $b
Multiplikation: $a * $b
Division: $a / $b
Modulus: $a % $b
...
-
*lol* ab ich wohl übersehen
Ansonsten kann ich nur sagen: thx für allescya