Jump to content

jazzman1

Staff Alumni
  • Posts

    2,713
  • Joined

  • Last visited

  • Days Won

    12

Everything posted by jazzman1

  1. I've never used 000webhost I don't know, maybe they limit you.
  2. Most likely the name of this image contains an empty space. Try to wrap the image's name with curly braces. for i in *jpg; do mogrify -colorspace Gray "${i}" done;
  3. This is very interesting question You need to open a new thread I think
  4. The easiest way for you is to use some DB GUI tool like phpMyAdmin, not personally using but for beginners is good. Then, connect to mysql server, open up the database named - "REMOVED_test" and create a table - SiteConfig.
  5. Obviously, you haven't done yet You need to fix the issue if you want to go further.
  6. It's simple - " Table 'REMOVED_test.SiteConfig' doesn't exist"
  7. Again, how do you connect to this remote database from your personal computer or the remote server? Where do you deploy your php / database scripts? As for the syntax error coming from your GUI, no need to apply charset encoding to columns with integer types. Try, the following works for me: CREATE TABLE `aluno`( `Id` int(11) NOT NULL auto_increment, `idfoto` int(11) NOT NULL, `idaula` int(11) NOT NULL, `Nome` varchar(200) charset utf8 collate utf8_unicode_ci NOT NULL, PRIMARY KEY (`Id`) ) ENGINE=InnoDB DEFAULT CHARSET= latin1 AUTO_INCREMENT=4;
  8. google this sql error, i'm going back in 30 min.
  9. Ok, got it. Go to db.php and add the line after the $obd object. Run the script again do a "view source" and post the new error. <?php if(strpos(strtolower($_SERVER['SCRIPT_NAME']),strtolower(basename(__FILE__)))){ die('Error!'); } define('DB_HOST', '*REMOVED*'); define('DB_NAME', '*REMOVED*'); define('DB_USERNAME', '*REMOVED*'); define('DB_PASSWORD', '*REMOVED*'); $odb = new PDO('mysql:host=' . DB_HOST . ';dbname=' . DB_NAME, DB_USERNAME, DB_PASSWORD); $odb->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION); ?>
  10. This error comes from mysqli library not from pdo. Can you explain this? Ah...I googled it comes from pdo as well. So then check if your database credentials are correct, inside db.php file.
  11. I'm not clear yet. So do you want to access and retrieve some records from a remote database or local one? If the database is a remote one, when do you create your php scripts onto the server or your personal machine?
  12. I don't know maybe the file is included inside another included file, you have to tell me
  13. Have you included this file on the top of index.php file?
  14. where is your class with fetchColumn() method?
  15. The email goes to my personal mail server box (inside my local server), so the script works fine. If you want to send an email to google, yahoo or whatever remote mail servers you want, you need to trust your outgoing ip address to your account to this remote mail server.
  16. we need to see your content (or a db class ) of db.php file.
  17. You need to do a "view source" in your browser to see the content of the header! If so...then everything is ok with your script until here!
  18. You have to show us the whole script, but speaking on this part, could you run only this part and tell me what result you get. I want to check the login session. <?php ini_set('display_startup_errors', 1); ini_set('display_errors', 1); error_reporting(-1); session_start(); // added a session start $page = 'Home'; $pageIcon = 'home'; require_once('/home/*REMOVED*/public_html/TZ/v3/includes/db.php'); require_once('/home/*REMOVED*/public_html/TZ/v3/includes/init.php'); if (!($user->LoggedIn())) { if (isset($_GET['referral'])) { $_SESSION['referral'] = preg_replace("/[^A-Za-z0-9-]/", "", $_GET['referral']); header('Location: register.php'); die(); } header('location: login.php'); die(); } else { echo "The user is login"; } if (!($user->notBanned($odb))) { header('location: logout.php'); die(); } require_once('header.php'); If the user is login you should get the message - "The user is login".
  19. we need to know what output you're expecting to get of the script above. Also are you still using output buffering set it up with ob_start() ?
  20. @Csharp, the relative path should be this: require_once('./includes/db.php'); The index file is located in - /home/*REMOVED*/public_html/TZ/v3/index.php ( re-read the first posting )
  21. when using a session / cookies, just delete the cookies if you have them or restart the browser page in case you're using sessions or unset them with php script.
  22. Then, maybe you die() somehow. What result are you expecting to get here?
  23. Try the following and tell me if you get errors, <?php ini_set('display_startup_errors',1); ini_set('display_errors',1); error_reporting(-1); session_start(); // added a session start $page = 'Home'; $pageIcon = 'home'; //ob_start(); require_once('/home/*REMOVED*/public_html/TZ/v3/includes/db.php'); require_once('/home/*REMOVED*/public_html/TZ/v3/includes/init.php'); if(!($user->LoggedIn())){ if(isset($_GET['referral'])){ $_SESSION['referral'] = preg_replace("/[^A-Za-z0-9-]/","", $_GET['referral']); header('Location: register.php'); die(); } header('location: login.php'); die(); } if(!($user->notBanned($odb))){ header('location: logout.php'); die(); } require_once('header.php');
  24. A chance to see some part of this problematic script?
  25. Add this on top of your index.php file to check for actual errors. ini_set('display_startup_errors',1); ini_set('display_errors',1); error_reporting(-1);
×
×
  • 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.