0

Help please. I'm trying to get a login page to work, but for some reason when I run the page it comes up blank. I've tried it with PDO, with mysql, and nothing is working. Any help would be appreciated.

I currently have it setup with the php at the top of the page with the html at the bottom. The button to login calls the same page, prompting the php code to run.

*Side note, this is the mysql version, but the PDO would also show up blank, I think it might not be connecting to the database properly. It is set up correctly because I've done commands in my terminal to double check.

MandyLB
  • 307
  • 1
  • 4
  • 18
  • 2
    white screen of death: error checking\display are off, turn them on to see the error. at the top of your php page add: `ini_set('display_errors', 'On'); ini_set('html_errors', 0); error_reporting(-1);` –  Jul 01 '16 at 04:50
  • show your GroceryOrder.php – Peternak Kode Channel Jul 01 '16 at 04:51
  • 1
    Aside from errors If you want the page to write something (errors?) you have to `echo $error;` Also, you should be adding `exit;` after your `header` redirect. This page itself does not appear that it would output anything. – Rasclatt Jul 01 '16 at 04:52
  • put this code under try catch block and get error information inside catch block and let me know... – Sunny S.M Jul 01 '16 at 05:07

2 Answers2

-1

may be the issues is around here header("location: GroceryOrder.php");..can you show the groceryorder.php code?

J. Zend
  • 88
  • 7
  • Man a valuable answer is ok, but just think yourself how your answer is going to help OP.BTY i am not down-voter. But think for a second yourself. – Alive to die - Anant Jul 01 '16 at 06:15
  • the page was blank...maybe something wrong with his groceryorder.php, thats why i want him to show his file,,,,sigh... – J. Zend Jul 01 '16 at 06:59
  • So you can tell him through comment. And if you are not able to comment. try to give some useful answers on questions,gain reputation and go for it. but with this you will only lose your reputation. May be my lines hurts you but it's beneficial for you. – Alive to die - Anant Jul 01 '16 at 07:04
-1

Please check your "if ($rowExist == 1)" because the the row returns value may be greater than 1. So it will not entered into the condition.

Prakash P
  • 342
  • 1
  • 9