Getting data from a single row...

Codes here !

Moderators: macek, egami, gesf

Post Reply
New php-forum User
New php-forum User
Posts: 193
Joined: Sat Mar 29, 2003 11:57 pm
Location: Auckland, New Zealand

Post by Joel » Thu Jul 10, 2003 3:33 am

Your problem lies in your mysql query. I haven't used the extract function before, I usually use

$data = mysql_fetch_array($result);

But anyway, you have a "WHERE mobiel='0648938052'" but you have not selected this field. This is what you need to have.

Code: Select all

SELECT userid, mobiel FROM table WHERE mobiel='0648938052'

Then if you used mysql_fetch array you can print the user id for that mobiel (do you mean mobile?) like this

Code: Select all

echo $data["userid"];

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest