RSS Forums RSS
Please support our PHP advertiser: Lunarpages PHP Web Hosting

unable to connect PHP with Mysql

Join Date: Nov 2006
Location: South Wales
Posts: 159
Reputation: phper is an unknown quantity at this point 
Rep Power: 3
Solved Threads: 11
phper's Avatar
phper phper is offline Offline
Junior Poster

Re: unable to connect PHP with Mysql

  #6  
Apr 28th, 2007
Once you have completed all the above you should use the following code to connect -

mysql_connect('HOSTNAME', 'USERNAME', 'PASSWORD');

if(mysql_error()) {
echo mysql_errno().'<BR>
mysql_error();
}
If you find my post useful please add to my reputation!! Thanks!

ajtrichards web solutions
http://www.ajtrichards.co.uk
Reply With Quote  
Forums | Blogs | Tutorials | Code Snippets | Whitepapers | RSS Feeds | Advertising
All times are GMT -4. The time now is 1:17 am.
Newsletter Archive - Sitemap - Privacy Statement - Acceptable Use Policy - Contact Us
Forum system based on vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC