View unanswered posts | View active topics It is currently Sun Sep 24, 2017 12:42 pm



Reply to topic  [ 1 post ] 
 Error message 
Author Message
Junior Member

Joined: Fri May 18, 2012 7:21 am
Posts: 2
Post Error message
helo

pleas help me.

Third error is displayed on the my web


Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in view_express_ad.php on line 635

Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in view_express_ad.php on line 645

Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in view_express_ad.php on line 659


These three lines are within a function ((function get_groups in view_express_ad.php ))

function get_groups Code:

Code:
  function get_groups()

  {

    $id = $_GET['id'];

    $query = "SELECT * FROM express_ads WHERE ID=$id";

    $result = mysql_query($query);

    $row = mysql_fetch_array($result);    *****line 635******

    $sgid = $row['GroupID'];



    $query = "SELECT * FROM groups WHERE ID=$sgid";

    $result = mysql_query($query);

    $row = mysql_fetch_array($result);       *****line 645******

    $parentid = $row['ParentID'];



    $query = "SELECT * FROM groups WHERE ParentID=$parentid";

    $result = mysql_query($query);



    $groups_html .= "<p align=\"right\"><ul>";

    while (($row = mysql_fetch_array($result)))        *****line 659******

      {

      $name = $row['Name'];

      $id   = $row['ID'];

      if ($id == $sgid)

        $bgcolor = "background-color: #ffddbb";

      else

        $bgcolor = "";



      $groups_html .= "<li style=\"$bgcolor\"><a href=\"sub_group.php?id=$id\">$name</a></li>";

      }



    $groups_html .= "</ul></p>";

    return $groups_html;

  }




Please guide me,
Regards,
Sara,


Fri May 18, 2012 7:47 am
Report this post
Profile
Display posts from previous:  Sort by  
Reply to topic   [ 1 post ] 

Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
© Copyright 2003-2008 www.php-editors.com. The ultimate PHP Editor and PHP IDE site.