Jump to content

nikes

Members
  • Posts

    19
  • Joined

  • Last visited

    Never

About nikes

  • Birthday 09/30/1993

Contact Methods

  • Website URL
    http://graphamation.com

Profile Information

  • Gender
    Male

nikes's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. i'm still getting the NULL NULL fatal error. What am i doing wrong?
  2. ok for example (this is the other part of the functions.php file ) i put var_dump($db) after global $db right? <?php function checkLogin ( $levels ) { session_start (); global $db; $kt = split ( ' ', $levels ); if ( ! $_SESSION['logged_in'] ) { $access = FALSE; if ( isset ( $_COOKIE['cookie_id'] ) ) {//if we have a cookie $query = 'SELECT * FROM ' . DBPREFIX . 'users WHERE ID = ' . $db->qstr ( $_COOKIE['cookie_id'] ); if ( $db->RecordCount ( $query ) == 1 ) {//only one user can match that query $row = $db->getRow ( $query ); //let's see if we pass the validation, no monkey business if ( $_COOKIE['authenticate'] == md5 ( getIP () . $row->Password . $_SERVER['USER_AGENT'] ) ) { //we set the sessions so we don't repeat this step over and over again $_SESSION['user_id'] = $row->ID; $_SESSION['logged_in'] = TRUE; //now we check the level access, we might not have the permission if ( in_array ( get_level_access ( $_SESSION['user_id'] ), $kt ) ) { //we do?! horray! $access = TRUE; } } } } } else { $access = FALSE; if ( in_array ( get_level_access ( $_SESSION['user_id'] ), $kt ) ) { $access = TRUE; } } if ( $access == FALSE ) { header ( "Location: " . REDIRECT_TO_LOGIN ); } } ?>
  3. Do var_dump($db) and see what it echoes. :-\Sorry I'm a beginner at this........ where do i do this at?
  4. this is line 76: $row = $db->getRow ( 'SELECT Level_access FROM ' . DBPREFIX . 'users WHERE ID = ' . $db->qstr ( $user_id ) ); and how do i check if $db is instantiated when this function is called.
  5. Fatal error: Call to a member function on a non-object in functions.php on line 76.. this is the part that has the line error: <?php function get_level_access ( $user_id ) { global $db; $row = $db->getRow ( 'SELECT Level_access FROM ' . DBPREFIX . 'users WHERE ID = ' . $db->qstr ( $user_id ) ); return $row->Level_access; } ?>
  6. I trying to do a full integration of phpbb3 into dolphin 6.1.4. I'm currently looking at some steps on how to do so. I'm stuck on this step: (instead of (users) it's (profiles)) How do i do this?
  7. Yes, i see the my.cnf file in the directory /etc/mysql/my.cnf
  8. in the error log it says "log file not found" and how do you find/edit the permissions on the sock file?
  9. Yes, i can connect from the command line. It shows every thing about the mysql. The socket that it's using is: UNIX socket: /var/run/mysqld/mysqld.sock
  10. my web hosting provider website is down...i will post the output when the site is back up. sorry... sounds like it's time for a new web hosting provider lol ok it's back up: here is the output: cannot connect to server: Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)
  11. my web hosting provider website is down...i will post the output when the site is back up. sorry...
  12. <?php $host=""; // Host name $username=""; // Mysql username $password=""; // Mysql password $db_name=""; // Database name //Connect to server and select database. mysql_connect("$host", "$username", "$password")or die("cannot connect to server"); mysql_select_db("$db_name")or die("cannot select DB"); ?>
×
×
  • 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.