php sql update problem
Posted: Sat Feb 09, 2008 2:03 am
hey there, I just recently created a code which automatically generates and updates a sql database. It worked fine on my test computer, but when uploaded to my webhost I beleive the problem is that the webhost is php 4, whereas i run php 5 on my computer. Does anyone know how i can get this code to work on the webhost? The code is
Does anyone know howi can make this run on PHP4? Or is it not working for another reason.Like i said, it works on my home test server, but not my webhost.
Thanks for any help given
Code: Select all
while($row = mysql_fetch_array($result)){
$variable=mysql_fetch_array(mysql_query("SELECT woodincome FROM buildings WHERE name='$row[name]'"))or die(mysql_error());
mysql_query("UPDATE table SET info=info+('$infoinc[infoincome]'*$row[infoname])")or die(mysql_error());
Thanks for any help given