Thank you for the code, when I did that (which I should have done, you're right) it worked fine. So, now I gotta find out where this is going wrong and why the same code is working in one place but not the other. While my connection function is only run once (due to my debug code I know this) however somewhere the mysql_select_db function is being called again so I just gotta find out where.
I won't bother you all again. If anyone wants to know how I fix this when I eventually do, write me personally. Thanks for your help and patience.
Ok fine. just as I had expected.
As you are using functions to do work for you, it is possible that certain functions are not being made available the required variables.
Also KIM that the resources returned by mysql_connect() and mysql_select_db() are by default global. (Unless otherwise configured, or older version). Thus the output from these functions don't need to be "returned".
I wouldn't mind if you would email me personally with your script file. Usually 4 eyes work better than 2 "un-trained" eyes. If your script includes other files, it will do some good to send those in too. (Preferably with some compression).
-- Think to think more, work to work more. __________________________________________ Meet the guy at http://www.meetRajesh.com/
-- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]