Jump to content

PeterLazarov

New Members
  • Posts

    3
  • Joined

  • Last visited

Posts posted by PeterLazarov

  1. When i was going trough the registraion I found two new mistakes in register.php that i didn`t see the last time.They are :

    $register = $_GET['register']; ( Undefined index)

    and  

    $success = mysql_query("INSERT INTO users(username, password, fullname, location, gender) VALUES ('$username', '$password', '$full_name','$location','$gender')"); ( Undefined variable)

    EDIT: I found a way that makes the error statement go away, but it seems a little questionable. The solution(??) is:

    Undefined index.
    Couldn't you just declare it in the line before to get rid of the error.
    $_GET['register']='';

     

  2. what debugging have you done to pin down where the problem is at?

     

    do you have php's error_reporting set to E_ALL and display_errors set to ON so that php will help you by reporting and displaying the errors it detects?

    I just added 

    ini_set("display_errors", 1);
    ini_set("track_errors", 1);
    ini_set("html_errors", 1);
    error_reporting(E_ALL);

    and no error was found

  3. Hello!
    I am new to PHP programming and am currently working on an account system. I have posted my work so far. From what I understand the problem is that when I log in the php script doesn`t acknowledge it and acts as if noone is logged in. Thanks in advace!

     

    Here are my files: 

    users.sql : 

    
    
    
    
    
    
    CREATE TABLE IF NOT EXISTS `users` (
      `id` int(11) NOT NULL AUTO_INCREMENT,
      `username` varchar(30) DEFAULT NULL,
      `password` varchar(255) DEFAULT NULL,
      `fullname` varchar(100) DEFAULT NULL,
      `location` varchar(200) DEFAULT NULL,
      `gender` varchar(10) DEFAULT NULL,
      PRIMARY KEY (`id`)
    ) ENGINE=InnoDB DEFAULT CHARSET=latin1 AUTO_INCREMENT=1 ;
    
    /*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
    /*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
    /*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
    

    auth_check.php

    common.php

    dashboard.php

    index.php

    login.php

    logout.php

    register.php

     

     

    auth_check.php

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.