Re: BASIC function question

From: Date: Tue, 24 Apr 2001 03:39:04 +0000
Subject: Re: BASIC function question
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-50009@lists.php.net to get a copy of this message
On Tue, 24 Apr 2001 12:57, Martin Skjöldebrand wrote: > I have a function on an include page that says > > function update_stuff($database) > { > include("includes/connect.inc.php"); > include("config/db.conf.php"); > $query="SELECT * FROM $database"; > $query_res=mysql_query($query, $mysql_link); > $isequip=mysql_num_rows($query_res); > } > > If I call it from a script as > update_stuff(equipment); > > I don't get any result (I want to page to automagically update it's > contents) while if I include the query lines after each edit case > it does update the page contents. > > I'm missing something basic, but what? > > Martin S. Your function isn't doing anything to return values of the rows you are selecting. -- David Robley | WEBMASTER & Mail List Admin RESEARCH CENTRE FOR INJURY STUDIES | http://www.nisu.flinders.edu.au/ AusEinet | http://auseinet.flinders.edu.au/ Flinders University, ADELAIDE, SOUTH AUSTRALIA I'm no stranger, just a friend you haven't met...

« previous php.general (#50009) next »