Search found 9 matches

by vray
Wed Jul 28, 2004 1:04 pm
Forum: Databases
Topic: INSERT data using variables created on the fly.
Replies: 13
Views: 805

Ok, I left out the closing brace... now I get the following error: Notice: Undefined variable: 2 in /home/www/html/auth/submit_review.php on line 48 Notice: Undefined variable: 1 in /home/www/html/auth/submit_review.php on line 49 etc... Progress at last! The posting is working, that's the 2 and 1 I...
by vray
Wed Jul 28, 2004 12:52 pm
Forum: Databases
Topic: INSERT data using variables created on the fly.
Replies: 13
Views: 805

yes, i am not sure of the syntax of the $sql = "INSERT etc.. Especially the VALUES line with all the $sql variables. Does it look okay to you? This is the string I believe i am not closing.
by vray
Wed Jul 28, 2004 12:37 pm
Forum: Databases
Topic: INSERT data using variables created on the fly.
Replies: 13
Views: 805

Ok., thanks. i am getting a parse error:
Parsing Error: \\Bboard\www\html\auth\submit_review.php line 60 - parse error, unexpected $end

Line 60 is the closing tag ?>

Any ideas?
by vray
Wed Jul 28, 2004 12:25 pm
Forum: Databases
Topic: INSERT data using variables created on the fly.
Replies: 13
Views: 805

$_POST["r1_".$record->user_id];
or
$_POST['r1_'.$record->user_id];

Single or double quotes?
by vray
Wed Jul 28, 2004 12:18 pm
Forum: Databases
Topic: INSERT data using variables created on the fly.
Replies: 13
Views: 805

Thanks, I'll try that.
by vray
Wed Jul 28, 2004 12:16 pm
Forum: Databases
Topic: INSERT data using variables created on the fly.
Replies: 13
Views: 805

Hmm, no, register globals is off. I'll give it a try with them on.
by vray
Wed Jul 28, 2004 11:50 am
Forum: Databases
Topic: INSERT data using variables created on the fly.
Replies: 13
Views: 805

A quick explanation of the app: This application is a peer review app. User1 logs on, all the members of user1's team are loaded into a form, except for user1 himself. User1 can now rate the co-workers and leave a comment. So when the review is submitted, I submit the user_id of the reviewer, the us...
by vray
Wed Jul 28, 2004 11:32 am
Forum: Databases
Topic: INSERT data using variables created on the fly.
Replies: 13
Views: 805

yes, here is the code that creates the variables: <?php query = "SELECT * FROM user WHERE user_name != '$user_name'"; $result = mysql_query($query); print("<FORM METHOD=post ACTION=submit_review.php>\n"); while ($row = mysql_fetch_object($result)) { print("<TABLE BORDER=1 ce...
by vray
Wed Jul 28, 2004 10:15 am
Forum: Databases
Topic: INSERT data using variables created on the fly.
Replies: 13
Views: 805

INSERT data using variables created on the fly.

Could someone please check my syntax and my logic in the insert code below? I converted a small code snippet to suit my needs, but am not understanding the code well enough to debug it properly. If anyone could give me some pointers i'd be much appreciative. If more info is needed, or if the code th...