Getting a "Supplied argument is not a valid MySQL result resource" from
a theme I am working with. The lines cited is the one with mysql_fetch_row
in it, below.
echo "<select name="\"topic\"onChange='submit()'">\n"
."<option value="\"\"">"._ALLTOPICS."</option>\n";
while(list($topicid, $topics) = mysql_fetch_row($toplist)) {
if ($topicid==$topic) { $sel = "selected "; }
echo "<option value="\"$topicid\"">$topics</option>\n";
$sel = "";
According to a May 2002 note at php.net,
"mysql_fetch_row($resultset,MYSQL_ASSOC) no longer works"
It recommends the following type of syntax.
$row=mysql_fetch_assoc($resultset);
or
$row=mysql_fetch_array($resultset,MYSQL_ASSOC);
I tried changing the mysql_fetch_row in the theme
to these, but the error remains...
any hints would be most appreciated.
BTW,
_if_ this mysql_fetch_row is causing problems,
it would need to be changed in quite a few themes,
it would seem. Grepping through some theme
directories gives quite a few hits.
Thanks.</select>
Watch
GitHub Core
Show your support for Zikula! Sign up at Github account and watch the Core project!
GitHub Modules
- Paustian responded to »Short URL questions« 05:49 AM
- mesteele101 responded to »Problem in Database Connection« 02:25 AM
- mesteele101 created topic »Bug in the SMTP mail transfer protocol - Port 25 - Zikula 1.2.9« 20. May
- Herr.Vorragend responded to »Clip Documentation and Doubt« 19. May
- mazdev responded to »zikula 1.3.3. and IE9« 19. May
- mesteele101 responded to »How to install Zikula for MSSQL ??? - Part II« 19. May
- mesteele101 created topic »File packaging« 16. May
Zikula Blog
- Anatomy of Open Source Projects on Mar 07
- Continuous Review on Mar 01
- Not Invented Here on Feb 24
- How to Contribute Your Code at Github on Jan 13
- 10 Steps to Coding-Nirvana: Tips for Successful Module Writing on Nov 12
- Submitting Bug Report Tickets That Get Results on Aug 17
- Cozi Tricks #1: Syntax Highlighting on Aug 07
