Porkie Posted July 6, 2009 Share Posted July 6, 2009 what am <?php $con = mysql_connect(""); if (!$con) { die('Could not connect: ' . mysql_error()); } mysql_select_db("", $con); $count = "SELECT COUNT(id) FROM gg_video"; echo '</td>'; echo '</tr>'; echo "Currently['$count'] Videos"; ?> i doing wrong when showing queries? cheers Link to comment https://forums.phpfreaks.com/topic/164960-echo-queries/ Share on other sites More sharing options...
Maq Posted July 6, 2009 Share Posted July 6, 2009 Do you want to show the query or the returned values? Link to comment https://forums.phpfreaks.com/topic/164960-echo-queries/#findComment-869832 Share on other sites More sharing options...
Porkie Posted July 6, 2009 Author Share Posted July 6, 2009 returned value please mate, thanks Link to comment https://forums.phpfreaks.com/topic/164960-echo-queries/#findComment-869833 Share on other sites More sharing options...
Maq Posted July 6, 2009 Share Posted July 6, 2009 Try: $count = "SELECT COUNT(id) FROM gg_video"; $result = mysql_query($count); $row = mysql_fetch_array($result); echo ''; echo ''; echo "Currently {$row['COUNT(id)']} Videos"; Link to comment https://forums.phpfreaks.com/topic/164960-echo-queries/#findComment-869835 Share on other sites More sharing options...
Porkie Posted July 6, 2009 Author Share Posted July 6, 2009 still shows nothing mate, any reason why? cheers Link to comment https://forums.phpfreaks.com/topic/164960-echo-queries/#findComment-869838 Share on other sites More sharing options...
will35010 Posted July 6, 2009 Share Posted July 6, 2009 still shows nothing mate, any reason why? cheers try: $count = "SELECT COUNT(id) FROM gg_video"; $result = mysql_query($count); $row = mysql_fetch_array($result); echo '</td>'; echo '</tr>'; echo "Currently ".{$row['COUNT(id)']}." Videos"; [/code Link to comment https://forums.phpfreaks.com/topic/164960-echo-queries/#findComment-869843 Share on other sites More sharing options...
Porkie Posted July 6, 2009 Author Share Posted July 6, 2009 sorted now cheers everyone Link to comment https://forums.phpfreaks.com/topic/164960-echo-queries/#findComment-869868 Share on other sites More sharing options...
Maq Posted July 6, 2009 Share Posted July 6, 2009 Mind sharing? Link to comment https://forums.phpfreaks.com/topic/164960-echo-queries/#findComment-869871 Share on other sites More sharing options...
will35010 Posted July 7, 2009 Share Posted July 7, 2009 Mind sharing? guess he does mind...lol. Link to comment https://forums.phpfreaks.com/topic/164960-echo-queries/#findComment-870153 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.