[PHP] Good Damn

2002-08-11 Thread Sascha Braun

$Query = SELECT * FROM basket_db WHERE session_id = '$PHPSESSID';
$Result = mysql_query($Query, $connect);
if ($Result) {
while ($arrResult = mysql_fetch_array($Result, MYSQL_ASSOC)) {
  echo 'tr bgcolor=#fffdd7 class=text01';
  echo 'td'.$arrResult['image_id'].'/td';
  echo 'td'.$arrResult['name'].'/td';
  echo 'tda class=text01 
href='.$PHP_SELF.'?action=deleteid='.$arrResult['id'].'delete/a/td';
  echo 'td Hier Preis'.$arrResult[''].'/td';
  echo 'td hier gesamt'.$arrResult[''].'/td';
  echo '/tr';
}
} else {
  echo 'tr bgcolor=#fffdd7 class=text01';
  echo 'td colspan=5There are no Artikles in Cart./td';
  echo '/tr';
}

This script is not doing what I want it too!

Ich want to see : There are no Artikles in Cart

when there are no Artikels in Cart

But it good damn doesn't work!

Please tell me why



Re: [PHP] Good Damn

2002-08-11 Thread Bas Jobsen

 if ($Result) {
if(mysql_num_rows($Result)0)

Op zondag 11 augustus 2002 16:32, schreef Sascha Braun:
 $Query = SELECT * FROM basket_db WHERE session_id = '$PHPSESSID';
 $Result = mysql_query($Query, $connect);
 if ($Result) {
 while ($arrResult = mysql_fetch_array($Result, MYSQL_ASSOC)) {
   echo 'tr bgcolor=#fffdd7 class=text01';
   echo 'td'.$arrResult['image_id'].'/td';
   echo 'td'.$arrResult['name'].'/td';
   echo 'tda class=text01
 href='.$PHP_SELF.'?action=deleteid='.$arrResult['id'].'delete/a/td'
; echo 'td Hier Preis'.$arrResult[''].'/td';
   echo 'td hier gesamt'.$arrResult[''].'/td';
   echo '/tr';
 }
 } else {
   echo 'tr bgcolor=#fffdd7 class=text01';
   echo 'td colspan=5There are no Artikles in Cart./td';
   echo '/tr';
 }

 This script is not doing what I want it too!

 Ich want to see : There are no Artikles in Cart

 when there are no Artikels in Cart

 But it good damn doesn't work!

 Please tell me why

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] Good Damn

2002-08-11 Thread Matt

 From: Sascha Braun [EMAIL PROTECTED]
Sent: Sunday, August 11, 2002 10:32 AM
Subject: [PHP] Good Damn


$Query = SELECT * FROM basket_db WHERE session_id = '$PHPSESSID';

try:
$Query = SELECT * FROM basket_db WHERE session_id = '$PHPSESSID' or
die(mysql_error());




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php