db.php errors on v3

Asked by TheRealDamiani

I get this error on top of the home page (logged in or not)---->> Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/damiani0/public_html/includes/db.php on line 1030

/* COMMON UPDATES */

 function getTwitterOptions($userID)
 {
  $query = $this->send("SELECT `twitter` FROM `users` WHERE `id`='$userID'");
LINE 1030---->> if (mysql_num_rows($query)) {
   return unserialize(mysql_result($query, 0));
  }
  else return false;
 }

And i get this error when i sign in below following stats ----->> Warning: mysql_result(): supplied argument is not a valid MySQL result resource in /home/damiani0/public_html/includes/db.php on line 1222

/**
  * It returns the number of 'unread' followers
  *
  * @param string $ID
  * @return void
  * @author Marcos García
  */
 function countUnreadFollowers($ID)
 {
  $query = $this->send("SELECT COUNT(*) FROM `relationships` WHERE `who`='".(int)$ID."' AND `read` =0");
LINE 1222--->> $result = mysql_result($query, 0);
  return $result;
 }

Can someone please help me thx!

Question information

Language:
English Edit question
Status:
Answered
For:
Jisko Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
Marcos Garcia (marcosgdf) said :
#1

I think you didn't install the latest 3.0beta1 from a clean install:

1. Remove all your tables of the database
2. Then follow the Jisko installation wizard
3. Remove install.php

There you go!

El 21/04/2010 18:54, "TheRealDamiani" <email address hidden>
escribió:

New question #108063 on Jisko:
https://answers.launchpad.net/jisko/+question/108063

I get this error on top of the home page (logged in or not)---->> Warning:
mysql_num_rows(): supplied argument is not a valid MySQL result resource in
/home/damiani0/public_html/includes/db.php on line 1030

/* COMMON UPDATES */

       function getTwitterOptions($userID)
       {
               $query = $this->send("SELECT `twitter` FROM `users` WHERE
`id`='$userID'");
LINE 1030---->> if (mysql_num_rows($query)) {
                       return unserialize(mysql_result($query, 0));
               }
               else return false;
       }

And i get this error when i sign in below following stats ----->> Warning:
mysql_result(): supplied argument is not a valid MySQL result resource in
/home/damiani0/public_html/includes/db.php on line 1222

/**
        * It returns the number of 'unread' followers
        *
        * @param string $ID
        * @return void
        * @author Marcos García
        */
       function countUnreadFollowers($ID)
       {
               $query = $this->send("SELECT COUNT(*) FROM `relationships`
WHERE `who`='".(int)$ID."' AND `read` =0");
LINE 1222--->> $result = mysql_result($query, 0);
               return $result;
       }

Can someone please help me thx!

--
You received this question notification because you are an answer
contact for Jisko.

Can you help with this problem?

Provide an answer of your own, or ask TheRealDamiani for more information if necessary.

To post a message you must log in.