Results 1 to 3 of 3

Thread: Why is error with activation of account?

  1. #1
    Join Date
    Sep 2005

    Question Why is error with activation of account?

    I have code when user clicks on link in his email and activates account.
    error is:
    PHP Code:
    Warningmysql_fetch_array(): supplied argument is not a valid MySQL result resource in activationuser.php on line 25 
    Line 25 is: while ($row = mysql_fetch_array($result)) and all code:

    PHP Code:
    $query "SELECT * FROM membership WHERE activationnum = '$accountnum'";
      while (
    $row mysql_fetch_array($result))
    $activation $row["activation"];
             if (

          {   echo 
    "<script language='javascript'>
    ;  }

    $query "UPDATE membership SET activation ='1'
                WHERE activationnum = '
    $resultmysql_query ($query) or die ('Can not complete update');

    I have to redirect user to index.php page if he clicks twice on link in his e-mail. So, only once can be pressed on link.

  2. #2
    Join Date
    Jan 2005
    Alicante (Spain)
    Because you haven't run a query. You need the following on the second line of your post.
    PHP Code:
    $result mysql_query($query); 

  3. #3
    Join Date
    Sep 2005
    Thanks, it works now.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
HTML5 Development Center

Recent Articles