NamePros
Welcome, Guest! Ready to make a name for yourself in the domain business? We welcome both the hobbyist and professional domainer to join the discussion as part of the NamePros community.

Click here to create your profile to start earning reputation for posting, and trader ratings for buying & selling in our free e-marketplace. Build your trader rating with each successful sale. Our system has tracked over 100,000 sales and counting!
FAQ & TOS Register Search Today's Posts Mark Forums Read

Go Back   NamePros.com > Website Development Discussion Forums > Programming
Reload this Page PHP page blank; no errors generated

Programming PHP, Perl, Ruby on Rails, AJAX, HTML, XHTML, CSS, JavaScript, MySQL and any other coding topics.

Advanced Search


Closed Thread
 
LinkBack Thread Tools
Old 02-25-2007, 09:40 AM THREAD STARTER               #1 (permalink)
DNOA Member
Join Date: May 2004
Posts: 5,040
mholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant future
 


Autism Marrow Donor Program 9/11/01 :: Never Forget Multiple Sclerosis Adoption Alzheimer's Lou Gehrig's Disease (ALS)

Thumbs down PHP page blank; no errors generated


Hey all,

I don't usually post here for help... so I feel kinda awkward doing this. Please be nice
????: NamePros.com http://www.namepros.com/programming/298446-php-page-blank-no-errors-generated.html

I have Apache running PHP and MySQL on my local workstation to make dynamic sites without the need to upload them. It works fine, never had any problems, haven't changed anything since 3 weeks ago, and everything's been good with it. So the server/config is not the problem.

It's one particular file that I have which shows up completely blank. Nothing is even outputted to the source. There's no 404 error, there's no PHP errors, and there's no logical errors. I didn't really change anything; and just to double-check it, I added:

echo("Test");

to the beginning of the file to see if it was even working. It's not. So I remove the ; at the end to see if it'll output a syntax error, like it always has. No errors. I haven't changed any config, as I said. Everything is like it always has been. And YES, it's configured to output all standard errors.

And it's just this one file.

I can't show you what's in the file for security reasons, but it's something that I really need to get fixed... any help appreciated.

Thanks,
-Matt
mholt is offline  
Old 02-25-2007, 10:04 AM   #2 (permalink)
NamePros Member
Join Date: Jun 2006
Posts: 195
tanfwc is an unknown quantity at this point
 



Is your Apache working previously? It seems like you got to check the Apache log file and see what's it is complaining about
tanfwc is offline  
Old 02-25-2007, 10:15 AM   #3 (permalink)
Senior Member
Join Date: Dec 2006
Location: England
Posts: 1,568
Matthew. has much to be proud ofMatthew. has much to be proud ofMatthew. has much to be proud ofMatthew. has much to be proud ofMatthew. has much to be proud ofMatthew. has much to be proud ofMatthew. has much to be proud ofMatthew. has much to be proud ofMatthew. has much to be proud of
 


Adoption Breast Cancer Breast Cancer Cancer Survivorship
Originally Posted by tanfwc
Is your Apache working previously? It seems like you got to check the Apache log file and see what's it is complaining about
Exactly what i was going to suggest. Failing that try reloading Apache (and subsequently php).
????: NamePros.com http://www.namepros.com/showthread.php?t=298446

Definitely sounds like a server problem.

Matt
Matthew. is offline  
Old 02-25-2007, 10:29 AM THREAD STARTER               #4 (permalink)
DNOA Member
Join Date: May 2004
Posts: 5,040
mholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant future
 


Autism Marrow Donor Program 9/11/01 :: Never Forget Multiple Sclerosis Adoption Alzheimer's Lou Gehrig's Disease (ALS)
Hmm... I didn't think to check the server logs, however:

Originally Posted by Apache .log file
[Sat Feb 24 17:27:37 2007] [notice] Parent: Created child process 5628
PHP Warning: PHP Startup: Unable to load dynamic library 'C:\\Program Files\\PHP\\ext\\php_exif.dll' - The specified module could not be found.\r\n in Unknown on line 0
PHP Warning: Module 'mysql' already loaded in Unknown on line 0
[Sat Feb 24 17:27:38 2007] [notice] Child 5628: Child process is running
[Sat Feb 24 17:27:38 2007] [notice] Child 5628: Acquired the start mutex.
[Sat Feb 24 17:27:38 2007] [notice] Child 5628: Starting 250 worker threads.
[Sat Feb 24 17:27:38 2007] [notice] Child 5628: Starting thread to listen on port 80.
Today is Sunday, though. Do you think it could have anything to do with it? If so, why does it only affect one file? It's just like others I have which work fine.

EDIT: I also see this happened previously several times... but the server restarts just fine. I'm not sure why it's not giving me any errors on restart like this.
mholt is offline  
Old 02-25-2007, 10:36 AM   #5 (permalink)
NamePros Member
Join Date: Jun 2006
Posts: 195
tanfwc is an unknown quantity at this point
 



Originally Posted by chulium
Hmm... I didn't think to check the server logs, however:



Today is Sunday, though. Do you think it could have anything to do with it? If so, why does it only affect one file? It's just like others I have which work fine.

EDIT: I also see this happened previously several times... but the server restarts just fine. I'm not sure why it's not giving me any errors on restart like this.
If you suspect it is your script having problem, put this at the top of the code

Code:
error_reporting(E_ALL);
It SHOULD throw you error message now

If not, run your script through console (best place to debug stuff).

Code:
c:\PHP\php.exe <full_path_to_script>
Of course, change the php.exe path to your install directory
tanfwc is offline  
Old 02-25-2007, 11:18 AM   #6 (permalink)
Domains my Dominion
 
sdsinc's Avatar
Join Date: Aug 2005
Location: Web 1.0
Posts: 9,552
sdsinc Has achieved greatnesssdsinc Has achieved greatnesssdsinc Has achieved greatnesssdsinc Has achieved greatnesssdsinc Has achieved greatnesssdsinc Has achieved greatnesssdsinc Has achieved greatnesssdsinc Has achieved greatnesssdsinc Has achieved greatnesssdsinc Has achieved greatnesssdsinc Has achieved greatness
 


Third World Education Find Marrow Donors! Find Marrow Donors! Find Marrow Donors! Find Marrow Donors! Animal Rescue Animal Cruelty AIDS/HIV Animal Rescue Wildlife Breast Cancer Animal Rescue Wildlife
You may have to check your PHP.ini file. There is one line which says whether to display errors or not. On production sites this setting is often set to Off.
__________________
NameNewsletter.com - free lists of available domain names
ZoneFiles.net (beta) - ccTLD and gTLD droplists
sdsinc is offline  
Old 02-25-2007, 11:33 AM THREAD STARTER               #7 (permalink)
DNOA Member
Join Date: May 2004
Posts: 5,040
mholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant future
 


Autism Marrow Donor Program 9/11/01 :: Never Forget Multiple Sclerosis Adoption Alzheimer's Lou Gehrig's Disease (ALS)
Thanks again for more help, but nothing there works. Like I've said, errors ARE outputted and configured correctly. All other files work, show errors, etc, except this particular one.

EDIT: I'm giving rep to those that try to help Thanks.
mholt is offline  
Old 02-25-2007, 02:15 PM   #8 (permalink)
cef
NamePros Regular
Join Date: May 2004
Location: NYC
Posts: 236
cef is a jewel in the roughcef is a jewel in the roughcef is a jewel in the rough
 


Animal Rescue
The log shows that PHP couldn't load the exif extensions. Are you calling any exif functions in the script?

Also, try commenting out the entire contents of the script so that you only have your Test echo as the script body:

PHP Code:
<?php
    
echo 'Test';
?>
If that works, try adding things back in in blocks until it starts working again. If it doesn't...well...bad disk sectors maybe?

Also --and this might sound weird-- did you cut and paste any of the code from somewhere else? Sometimes this copies hidden characters which get embedded in the script (for example, this happens to me sometimes when cutting and pasting source from a .chm file). You might have to retype the code by hand, or strip all bad characters from your source file (most program editors have a way to do that).
????: NamePros.com http://www.namepros.com/showthread.php?t=298446

And of course, last bit of advice for windows -- did you reboot the entire machine? (only half joking here).
cef is offline  
Old 02-25-2007, 03:20 PM THREAD STARTER               #9 (permalink)
DNOA Member
Join Date: May 2004
Posts: 5,040
mholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant future
 


Autism Marrow Donor Program 9/11/01 :: Never Forget Multiple Sclerosis Adoption Alzheimer's Lou Gehrig's Disease (ALS)
Tried the echo thing, the removing/adding blocks of code thing, and all the code is original.

Oh well, thanks for the help. I'll just re-write the file or something.
mholt is offline  
Old 02-25-2007, 04:03 PM   #10 (permalink)
Domains my Dominion
 
sdsinc's Avatar
Join Date: Aug 2005
Location: Web 1.0
Posts: 9,552
sdsinc Has achieved greatnesssdsinc Has achieved greatnesssdsinc Has achieved greatnesssdsinc Has achieved greatnesssdsinc Has achieved greatnesssdsinc Has achieved greatnesssdsinc Has achieved greatnesssdsinc Has achieved greatnesssdsinc Has achieved greatnesssdsinc Has achieved greatnesssdsinc Has achieved greatness
 


Third World Education Find Marrow Donors! Find Marrow Donors! Find Marrow Donors! Find Marrow Donors! Animal Rescue Animal Cruelty AIDS/HIV Animal Rescue Wildlife Breast Cancer Animal Rescue Wildlife
It is difficult to say without seeing the full code. But I can tell you that PHP has some bugs. The version you are using could be at fault. Could it be that you are using a particular function in that page ?
__________________
NameNewsletter.com - free lists of available domain names
ZoneFiles.net (beta) - ccTLD and gTLD droplists
sdsinc is offline  
Old 02-25-2007, 04:34 PM THREAD STARTER               #11 (permalink)
DNOA Member
Join Date: May 2004
Posts: 5,040
mholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant future
 


Autism Marrow Donor Program 9/11/01 :: Never Forget Multiple Sclerosis Adoption Alzheimer's Lou Gehrig's Disease (ALS)
Possibly Thanks for all your help ... I'll just rewrite it and avoid some methods I used in this file.
mholt is offline  
Old 02-25-2007, 04:40 PM   #12 (permalink)
Senior Member
Join Date: Dec 2006
Location: England
Posts: 1,568
Matthew. has much to be proud ofMatthew. has much to be proud ofMatthew. has much to be proud ofMatthew. has much to be proud ofMatthew. has much to be proud ofMatthew. has much to be proud ofMatthew. has much to be proud ofMatthew. has much to be proud ofMatthew. has much to be proud of
 


Adoption Breast Cancer Breast Cancer Cancer Survivorship
Can i suggest uploading it to a live server to actually determine if it is your local setup or not?

You could be saving yourself a lot of hassle...

Matt
Matthew. is offline  
Old 02-26-2007, 09:05 AM   #13 (permalink)
NamePros Regular
Join Date: Feb 2006
Posts: 584
jerometan is a name known to alljerometan is a name known to alljerometan is a name known to alljerometan is a name known to alljerometan is a name known to alljerometan is a name known to alljerometan is a name known to alljerometan is a name known to all
 



If I didn't remember wrongly, if a PHP module fails to load, PHP wouldn't load as well.

If you're completely not getting ANY output, you might want to check if PHP is actually running by using another script.

EG. <?php phpinfo(); ?>
jerometan is offline  
Old 02-26-2007, 10:21 AM THREAD STARTER               #14 (permalink)
DNOA Member
Join Date: May 2004
Posts: 5,040
mholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant future
 


Autism Marrow Donor Program 9/11/01 :: Never Forget Multiple Sclerosis Adoption Alzheimer's Lou Gehrig's Disease (ALS)
PHP *IS* RUNNING. It's only one file that has the problem! How can I not make myself clearer??

Regardless, I fixed the problem.
mholt is offline  
Old 02-26-2007, 02:31 PM   #15 (permalink)
cef
NamePros Regular
Join Date: May 2004
Location: NYC
Posts: 236
cef is a jewel in the roughcef is a jewel in the roughcef is a jewel in the rough
 


Animal Rescue
Originally Posted by chulium
Regardless, I fixed the problem.
I think we're all dying to know...HOW???
cef is offline  
Old 02-26-2007, 03:14 PM THREAD STARTER               #16 (permalink)
DNOA Member
Join Date: May 2004
Posts: 5,040
mholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant futuremholt has a brilliant future
 


Autism Marrow Donor Program 9/11/01 :: Never Forget Multiple Sclerosis Adoption Alzheimer's Lou Gehrig's Disease (ALS)
Oh, sorry.

I had missed a ] to close an array index.

The error_reporting(E_ALL); at the beginning of the file didn't seem to work, as previously stated...

I get parse errors on every other file except this one, which didn't use any EXIF functions either.

So yeah, I dunno what happened. But it's fixed; that's all I care about. Thanks for the help.
mholt is offline  
Old 02-27-2007, 04:32 AM   #17 (permalink)
NamePros Regular
Join Date: Feb 2006
Posts: 584
jerometan is a name known to alljerometan is a name known to alljerometan is a name known to alljerometan is a name known to alljerometan is a name known to alljerometan is a name known to alljerometan is a name known to alljerometan is a name known to all
 



display_errors and error_reporting php directives may have overrided script settings.
jerometan is offline  
Closed Thread


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools


Liquid Web Smart Servers  
All times are GMT -7. The time now is 09:22 AM.

Managed Web Hosting by Liquid Web
Domain name forum recommended by Domaining.com Powered by: vBulletin® Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.6.0 Ad Management plugin by RedTyger