NEED HELP

Ye' old general discussion board. Basically, for everything that isn't covered elsewhere. Come here to shoot the breeze, shoot your mouth off, or whatever suits your fancy.
This forum is not for asking programming related questions.

Moderator: General Moderators

manRay
Forum Commoner
Posts: 78
Joined: Mon Feb 09, 2009 1:57 pm

Re: NEED HELP

Post by manRay »

frankly, no I don't. You told me to make sure there was no spaces. I replied and I didn't get a reply.
User avatar
Benjamin
Site Administrator
Posts: 6935
Joined: Sun May 19, 2002 10:24 pm

Re: NEED HELP

Post by Benjamin »

Code: Select all

 
<?php
$foo = $bar;
$str = "string";
// comment
 
You can press the "quote" button to see how to format code.
manRay
Forum Commoner
Posts: 78
Joined: Mon Feb 09, 2009 1:57 pm

Re: NEED HELP

Post by manRay »

OK, now I am trying to get a field from one of my databases tables and insert into another one.This is what I have..

Code: Select all

$id=mysql_query("SELECT id FROM users WHERE username='$user'");
but when I checked the new table, instead of inserting the id, it started with 0. A little help would be appreciated.
User avatar
Benjamin
Site Administrator
Posts: 6935
Joined: Sun May 19, 2002 10:24 pm

Re: NEED HELP

Post by Benjamin »

Have a look at the examples in the manual..

http://us.php.net/manual/en/function.mysql-query.php
Post Reply