Sql error

Started on the old forum in August 2009 · view the original in the archive · old links redirect here

3 replies · 370 views · started 17 years ago · 1 min read

3 participants
crazybrumi Super moderator Principal · 1,064 posts #1

there are no errors showing aswell so its a dead end.

    
$sql = "SELECT path  FROM gallery_files WHERE approved = 1 ";

    $items = mysql_query($sql);
    echo mysql_error();
    
    if(mysql_num_rows($items)>0)
    while ($item = mysql_fetch_array($items))
    {
    $main.="<img src=\"../phpThumb/phpThumb.php?src=$item[0]\" width=\"50\" height=\"50\" alt=\"$item[0]\"/>";
    }

this works in main page but as soon as i put it in index it dosnt work even tho there is a database connection valid as im pullin how many poeple have registered etc but for sum reason this dosnt wna work

Want something coded email me at sales@webnwaphost.com for a prices.

http://flagcounter.com/more/W80q

xcoderx Junior · 43 posts #2

And the error message is?

subzero Super moderator Fellow · 3,954 posts #3

$sql = "select path from gallery_files where approved = '1' ";$items = mysql_query($sql);echo mysql_error();if(mysql_num_rows($items)>0)while ($item = mysql_fetch_array($items)){$main.="<img src="../phpthumb/phpthumb.php?src=$item[0]" width="50" height="50" alt="$item[0]"/>";}


0-0-0- 99999

Visit: Chat4u.mobi - The New Lay Of being a site of your dreams! Visit: WapMasterz Coming Back Soon!


SCRIPTS FOR SALE BY SUBZERO Chat4u Script : coding-talk.com/f28/chat4u-mobi-script-only-150-a-17677/ - > Best Script for your site no other can be hacked by sql or uploaders. FileShare Script : coding-talk.com/f28/file-wap-share-6596/ -> Uploader you will never regret buying yeah it mite be old now but it still seems to own others... _______…

Sign in to reply.

Similar topics

Keyboard shortcuts

g f
Go to forums
g h
Go to your feed
g m
Go to messages
r
Reply (in a topic)
/
Search
j
Next post
k
Previous post
?
This list
Ctrl/⌘ + Enter
Send what you are writing
Ctrl/⌘ + B / I
Bold / italic while writing
Esc
Close