Discover Habbo's history
Treat yourself with a Secret Santa gift.... of a random Wiki page for you to start exploring Habbo's history!
Happy holidays!
Celebrate with us at Habbox on the hotel, on our Forum and right here!
Join Habbox!
One of us! One of us! Click here to see the roles you could take as part of the Habbox community!


Results 1 to 5 of 5
  1. #1
    Join Date
    Aug 2006
    Location
    United Kingdom
    Posts
    3,843
    Tokens
    1,121

    Latest Awards:

    Default User System Error

    Im using the OH user system and it comes up with the error
    Fatal error: Call to undefined function lock() in /home/studio/public_html/user/config.php on line 3
    on the login.php page
    URL to the error is
    http://www.studiohabbo.com/user/login.php

    The config file is
    <?php
    include("nonban_config.php"); //Do not edit
    lock("Cdhg3H2fg12GB2q", "OurHabbo"); //This must remain intact, else the software will not work
    ?>
    And the nonban_config file is
    <?php
    ob_start();
    // edit the following
    $database_host = "localhost";
    $username = "*******";
    $password = "******";
    $database = "*******";
    // stop editing
    $conn = mysql_connect("$database_host", "$username", "$password");
    mysql_select_db("$database") or die(mysql_error());
    if (isset($_COOKIE['id']) && isset($_COOKIE['pass'])) {
    $id = $_COOKIE['id'];
    $password = $_COOKIE['pass'];
    $info = mysql_query("SELECT * FROM users WHERE id='" . $id . "'") or die(mysql_error());
    $data = mysql_fetch_array($info);
    if ($data['password'] == $password) {
    $_SESSION['id'] = $id;
    $_SESSION['pass'] = $password;
    }
    }
    if (isset($_SESSION['id']) && isset($_SESSION['pass'])) {
    $logged = mysql_query("SELECT * FROM users WHERE id='" . $_SESSION['id'] . "' AND password = '" . $_SESSION['pass'] . "'");
    $logged = mysql_fetch_array($logged);
    }
    ?>
    <?
    if($logged[username])
    {
    $updatepage = mysql_query("UPDATE `users` SET `page` = '".$_SERVER['REQUEST_URI']."' WHERE `username` = '$logged[username]'"); // Queries the database and updates the page field to what you're viewing
    }
    if($logged[username])
    {
    //the visitor is logged in
    $update_pages = mysql_query("update users set pageviews = pageviews+1 where id = '$logged[id]'");
    }
    ?>
    <?
    if($logged[username]) //if logged in
    {
    if($logged[alert] == 'NONE') //if no alert
    {
    echo (""); //echo nothing
    }
    if($logged[alert]) //if there is an alert
    {
    echo ("
    <script>
    alert ('Moderator Says: $logged[alert]')
    </script>
    "); //send it
    mysql_query("UPDATE `users` SET `alert` = '' WHERE `username` = '$logged[username]'"); //then delete alert
    }
    }
    $offline = 300; //How long is considered online?
    $current = time(); //gets the time on the server (unformatted)
    $offline = ($current-$offline); //
    if ($logged[username])
    {
    $update = mysql_query("UPDATE users set online = '$current' where username = '$logged[username]'");
    //the above line sets the time the user was online to the current time
    }
    ?>
    <?
    $license_key = 'G93hsG40ahfG';
    ?>
    Thanks, +REP for all help

    Moved by Mattps22004 (Forum Moderator) from Website Designing & Development: Please post in the correct forum next time, thanks.
    Last edited by Matt.; 24-07-2007 at 03:58 PM.

  2. #2
    Join Date
    Jul 2007
    Location
    United Kingdom
    Posts
    92
    Tokens
    0

    Default

    Remove this line.

    lock("Cdhg3H2fg12GB2q", "OurHabbo"); //This must remain intact, else the software will not work

    It will work.
    REMOVED

    Edited by jesus (Forum Super Moderator): Please do not have fonts in your signature which are over size 4.

  3. #3
    Join Date
    Aug 2006
    Location
    United Kingdom
    Posts
    3,843
    Tokens
    1,121

    Latest Awards:

    Default

    ty
    Last edited by Sunny.; 24-07-2007 at 12:03 PM.

  4. #4
    Join Date
    Jan 2007
    Posts
    825
    Tokens
    0

    Default

    Its Ironic. They put the line there and say if its gone it wont work. I found this problem out when I used it but you'll find it has many other bugs.
    That post was really sensible!

  5. #5
    Join Date
    Sep 2006
    Posts
    2,114
    Tokens
    0

    Latest Awards:

    Default

    sunny will u answer the pm i sent u yesterday please
    Looking for a good desiner to design a social networking template.

    PM me.

Posting Permissions

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