| | |
PHP testing server no syntax error just blank web page
Please support our PHP advertiser: PostgreSQL or MySQL? Compare and contrast the two most popular open source databases
![]() |
•
•
Join Date: Jun 2007
Posts: 2
Reputation:
Solved Threads: 0
Hi - I am just learning PHP. I installed Apache, PHP and MySql on my computer (XP pro) and it is working. I use dreamweaver and when I preview it - my php code works. However, when my code does not work, instead of getting a syntax error, I just get a blank web page, so I have no idea what I am doing wrong. I have no clue how to get the syntax error to show up.
I did notice that the title of my webpage in the firefox tab, when my code works, is the html title, but when it does not work, I get the complete file name and path. I don't know if that means much, but I wanted to mention it in case it did.
Thanks for any help you can provide - I greatly appreciate it!
Dawn
I did notice that the title of my webpage in the firefox tab, when my code works, is the html title, but when it does not work, I get the complete file name and path. I don't know if that means much, but I wanted to mention it in case it did.
Thanks for any help you can provide - I greatly appreciate it!
Dawn
This is a common error. Either it means PHP is not installed properley or that you are using the wrong tags
<? and ?> are called short tags <?php and ?> are called long tags. Certain versions of apache support ONLY long tags. Try this and see if it works. If it works it should display your PHP statistics and settings
<?php
phpinfo();
?>
<? and ?> are called short tags <?php and ?> are called long tags. Certain versions of apache support ONLY long tags. Try this and see if it works. If it works it should display your PHP statistics and settings
<?php
phpinfo();
?>
If i am helpful, please give me reputation points.
•
•
Join Date: Jun 2007
Posts: 2
Reputation:
Solved Threads: 0
OK - I did that and it did work - is there some kind of setting in the php config file that I need to change - I'm so afraid to go into that file!
I did notice that the program I am using (called Web-Developer Controller) has a error log and the parse errors show up in there -but I would really like for them to show up in my browser. I have version 5.2.1 of PHP
Thanks!
I did notice that the program I am using (called Web-Developer Controller) has a error log and the parse errors show up in there -but I would really like for them to show up in my browser. I have version 5.2.1 of PHPThanks!
Under php.ini there is an option called "short_open_tag". It is probably set to off, or no or false or something like that. Change it and reboot.
Using the short tags is BAD practice though because they can conflict with XMLs tag which is <?xml . However, many (badly written) applications like dreamweaver still use them...
Using the short tags is BAD practice though because they can conflict with XMLs tag which is <?xml . However, many (badly written) applications like dreamweaver still use them...
Last edited by jbennet; Jun 11th, 2007 at 10:33 pm.
If i am helpful, please give me reputation points.
•
•
•
•
Under php.ini there is an option called "short_open_tag". It is probably set to off, or no or false or something like that. Change it and reboot.
Using the short tags is BAD practice though because they can conflict with XMLs tag which is <?xml . However, many (badly written) applications like dreamweaver still use them...
Now, in order to see your errors along with the rest of the code, you have to open the php.ini file and look for a directive named: error_reporting.
You can search for it in the php.ini file. If it has semicolon infront or has no value after the = sign, in order to see all errors you have to set it like this
error_reporting = E_ALL
Then restart the apache in order to reset the php and all your errors will show along with the code.
Good luck.
p.s. Oh, one more thing, check also the value of directive display_errors = .... it should be sent to ON
Last edited by Rhyan; Jun 15th, 2007 at 4:26 am. Reason: Post Scriptum
" Of all the things I've lost,
I miss my mind the most...."
Mark Twain
I miss my mind the most...."
Mark Twain
![]() |
Similar Threads
- syntax error, unexpected $end in ndex.php on line 127 (PHP)
- Internet Explorer Navagation to web page cancelled (Windows NT / 2000 / XP)
- php socket server - can't connect from flash xml client socket (PHP)
- cannot find server or DNS error...i know... (Viruses, Spyware and other Nasties)
- Error message when posting Web page into Word (Windows Software)
Other Threads in the PHP Forum
- Previous Thread: php and mysql db
- Next Thread: Problem when configure PHP5 with Apache2
| Thread Tools | Search this Thread |
ajax apache api array beginner binary body broken cakephp checkbox class cms code cron curl database date date/time display dynamic echo email error file files folder form forms function functions gc_maxlifetime global google host href htaccess html image include insert integration ip java javascript joomla limit link list login loop mail memmory menu mlm msqli_multi_query multiple mycodeisbad mysql navigation oop parameter parsing paypal pdf php problem query radio random recourse recursion regex registrationform remote script search seo server sessions sms soap source space sql static syntax system table tutorial update upload url validator variable video web webdesign wordpress xml youtube






