Don't like ads? PRO users don't see any ads ;-)
Guest

Untitled

By: a guest on May 23rd, 2012  |  syntax: None  |  size: 0.41 KB  |  hits: 13  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. Strange php error with a variable name [closed]
  2. $Fields = mysql_fetch_assoc($Result);
  3.        
  4. <?php echo $Fields['BusinessName']; ?>
  5.        
  6. $strQuery = "SELECT * FROM tblAds WHERE AdRef = '{$ThisAd}' LIMIT 1 ";
  7. $Result = mysql_query($strQuery);
  8. $Field = mysql_fetch_assoc($Result);
  9.        
  10. $Fields = mysql_fetch_assoc($Result);
  11. foreach($Fields as $field){
  12.    echo $field['BusinessName'];
  13. }
  14.        
  15. $Fields[0]['BusinessName'];