Re: Inserting data into mySQL...?

From: Date: Thu, 30 Dec 2004 11:24:47 +0000
Subject: Re: Inserting data into mySQL...?
References: 1  Groups: php.install 
Request: Send a blank email to php-install+get-14958@lists.php.net to get a copy of this message
On Wed, 2004-12-29 at 16:59, Oscar J. Ramos wrote: > mySQL version 4.1 > > php 5 > > OS Windows 2003 server > > IIS > > Running php as cgi > > > > Php.ini file configurations > > > > Extension_dir = “c:/php/ext/” > > Extension=php_mysql.dll > > > > PHP code used. > > > > ?> > > @ $db = mysql_connect("localhost", "username", "password"); > > > > > > if (!$db) > > { > > > > echo "<center>Error: Could not connect to database. Please try > again later.</center>"; > > exit; > > > > } > > $id = ''; > > $name = 'Oscar J. Ramos'; > > echo 'Test 1 ' . $name . '<br>'; > > mysql_select_db("dbtest"); > > > > $query = "insert into tbltest values > > ('".$id."', '".$name."')"; > > > > $result = mysql_query($query); > > > > echo $name; > > > > ?> > > > > added path c:\php > > > > Oscar J. Ramos > > Technology Support Technician > > > > By Design LLC. > > > > (212) 500 - 4466 > > x4466 > > ojramos@bydesignllc.com > > www.bydesignllc.com I may not be able to help as I do not use PHP under MS Windows, but you have not told us what problem you are having.If you use code that will show the error messages then post them here, we may be able to help. Regards Chris

« previous php.install (#14958) next »