||02-27-2008 09:23 AM
an error makes me crazy nuts !!!!!!!
im working on a website but i get this error
and the issue is that the same code is used on many pages but the error is just on 2 pages
here is the code
and here is the error =>
Fatal error: Cannot redeclare dbconn() (previously declared in C:\wamp\www\alfars\controls\function.inc:2) in C:\wamp\www\alfars\controls\function.inc on line 12
looking forward forthe answer
||02-27-2008 10:31 AM
You're double trying to make a connection to the database.
A proper solution would be to make the connection in the config.inc file.
In that case, put this in your
mysql_connect("localhost", "user", "pwd") or die(mysql_error());
mysql_select_db("db") or die(mysql_error());
You can delete the dbconn line now. Every time you include your config file it connects to the database automaticly.
Hope this is what you want though :).
|All times are GMT. The time now is 09:43 AM.
Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.1.0