View unanswered posts | View active topics It is currently Thu Dec 14, 2017 10:05 am



Reply to topic  [ 3 posts ] 
 check this please 
Author Message
Junior Member

Joined: Sun Nov 07, 2004 12:22 am
Posts: 8
Post 
Code:
<?

$linkID = @mysql_connect("mysql2.brinkster.com" , "zerographics2", "wwwwwwww") or
die ("connection lost");
mysql_select_db("shopping", $linkID);
mysql_query("INSERT INTO customer (customerID, firstName, lastName) VALUES (109, 'Martine', 'Edwards')", $linkID);

mysql_close($linkID);

$result = mysql_query("INSERT INTO customer (customerID,
firstName, lastName) VALUES (109, 'Martine', 'Edwards')",
"$linkID");
if ($result == true) {
print "Record Added";
} else {
print "Record Failed";
}
$resultID = mysql_query("SELECT * FROM customer", "$linkID");
print "<table><tr><td>Customer ID</td>";
print "<td>First Name</td><td>Last Name</td></tr>";
while ($row = mysql_fetch_row($resultID))
{
print "<tr>";
foreach ($row as $field)
{
print "<td>$field</td>";
}
print "</td>";
}
print "</table>";
?>

_________________
[url=\'http://www.zerographics.org/forums\']http://www.zerographics.org/forums[/url]


Mon Feb 21, 2005 5:08 pm
Report this post
Profile
Junior Member

Joined: Wed Mar 24, 2004 9:05 pm
Posts: 5
Location: Canton, NY
Post 
It's very hard to check code without having a sense of what error message you might be getting and what your code is trying to accomplish. I also hope that your password etc is faked! It looks like it.

Would you kindly post a commentary on exactly why you need help, what went wrong, exactly what task you are trying to accomplish?

Thanks!

Harvey Ramer
http://www.designdelineations.com


Mon Feb 21, 2005 5:18 pm
Report this post
Profile WWW
Junior Member

Joined: Sun Nov 07, 2004 12:22 am
Posts: 8
Post 
oh my bad, here is an error message i am recieving

Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in \\brink-premfs1\sites\premium4\zerographics2\webroot\tests\testing.php on line 12
Record Failed
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in \\brink-premfs1\sites\premium4\zerographics2\webroot\tests\testing.php on line 18
Customer ID First Name Last Name

Warning: mysql_fetch_row(): supplied argument is not a valid MySQL result resource in \\brink-premfs1\sites\premium4\zerographics2\webroot\tests\testing.php on line 21

_________________
[url=\'http://www.zerographics.org/forums\']http://www.zerographics.org/forums[/url]


Mon Feb 21, 2005 5:38 pm
Report this post
Profile
Display posts from previous:  Sort by  
Reply to topic   [ 3 posts ] 

Who is online

Users browsing this forum: No registered users and 0 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
© Copyright 2003-2008 www.php-editors.com. The ultimate PHP Editor and PHP IDE site.