if(!mysql_select_db(data,$db_link))
is your database named data? If so, it should be:
if(!mysql_select_db("data",$db_link))
otherwise you need to define a constant named data.
define("data", "dbname");
if you alot of places that it issues this warning and your dbname IS data, just define a constant at the top of the pages, that way you don't have to change each line individually.
define("data", "data");
The reason it probably used to work is that the warnings were suppresed. What happens if a constant is not defined is that it echos out the name of the constant and then sends a warning message. If warnings were suppressed, it would have just echoed out the constant name which happens to be the database name.
Hope that made sense, I'm going on very little sleep here..... 🙂
Matt Wade
codewalkers.com