redarrow Posted April 10, 2006 Share Posted April 10, 2006 I wont to echo all the ids with the row statement how.thank you.ps. somethink not in my learning cd please help.example 1[code]for ($i=0; $i<count($result); $i++);while($record=mysql_fetch_row($result){$id=row['id'];echo $id;}[/code]example 2[code]while($record=mysql_fetch_row($result){$id=row['id'];echo $id;}[/code] Link to comment https://forums.phpfreaks.com/topic/7001-solved-echo-id-with-row-statement-how-thank-you/ Share on other sites More sharing options...
adamjnz Posted April 10, 2006 Share Posted April 10, 2006 change mysql=fetch_row to mysql_fetch_row Link to comment https://forums.phpfreaks.com/topic/7001-solved-echo-id-with-row-statement-how-thank-you/#findComment-25413 Share on other sites More sharing options...
redarrow Posted April 10, 2006 Author Share Posted April 10, 2006 [!--quoteo(post=363206:date=Apr 10 2006, 07:14 AM:name=AdamJ NZ)--][div class=\'quotetop\']QUOTE(AdamJ NZ @ Apr 10 2006, 07:14 AM) [snapback]363206[/snapback][/div][div class=\'quotemain\'][!--quotec--]change mysql=fetch_row to mysql_fetch_row[/quote]sorry my fault in spelling still dosent show all the ids Link to comment https://forums.phpfreaks.com/topic/7001-solved-echo-id-with-row-statement-how-thank-you/#findComment-25414 Share on other sites More sharing options...
redarrow Posted April 10, 2006 Author Share Posted April 10, 2006 [code]<?$db=mysql_connect("localhost","xxxx","xxxx");mysql_select_db("freedating",$db);$query="select id from xxxx";$result=mysql_query($query);while($row=mysql_fetch_assoc($result)){$id=$row["id"];echo "$id<br>";}?>[/code][!--sizeo:5--][span style=\"font-size:18pt;line-height:100%\"][!--/sizeo--]solved[!--sizec--][/span][!--/sizec--] Link to comment https://forums.phpfreaks.com/topic/7001-solved-echo-id-with-row-statement-how-thank-you/#findComment-25415 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.