Jump to content


Blank pages when attempting to read from a database

  • Please log in to reply
1 reply to this topic

#1 Buchead

  • Members
  • PipPipPip
  • Advanced Member
  • 59 posts

Posted 25 July 2006 - 01:12 PM


I've just installed apache/mysql/php/phpmyadmin on an XP machine, and whilst it all works fine, when I write a page to retrieve any data from the database I get a completely blank page. No errors about not connecting to the database (tried using wrong password); just get nothing at all.

If I have a standard php page that doesn't involve a database it works fine! phpmyadmin allows me to update the databases, so that side of it appears to be ok.

It's running:

Apache/1.3.34 (win32)
PHP 5.1.1
Mysql 5.0
phpmyadmin 2.7.0

I've installed it on another PC (albeit slightly different versions) and it works fine, so I know my coding is ok!

Is anyone able to suggest what I've done wrong?


#2 lead2gold

  • Members
  • PipPipPip
  • Advanced Member
  • 164 posts
  • LocationOttawa, On

Posted 25 July 2006 - 01:17 PM

You probably have an error on your php script, but you don't have display errors on. (thus it comes out blank).

What you should do is edit you php.ini file
and look for these line(s) (change them to what you see below):

error_reporting  =  E_ALL & ~E_NOTICE
display_errors = On

It will help you to debug the page and find out why it isn't displaying properly.

It can happen if it failed to open the database, or you have a syntax error in your php script.


0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users