Jump to content

Beginner PHP trouble


1981mateo

Recommended Posts

Hi Im having a problem with php, I create a test page using the

<?php

phpinfo();

?>

function and it comes up a blank page or "Unable to connect" page. http://localhost returns a it works page but when i refresh the page it comes up with a "Unable to connect" page.

"[warn] php module is already loaded skipping

 

[warn] php module is already loaded skipping"

Link to comment
https://forums.phpfreaks.com/topic/94207-beginner-php-trouble/
Share on other sites

I did a fresh installof apche2.2 and php5, and didnt modify the default settings that http://16bytes.com/How_to_install_PHP5_Apache_2_2_and_MySQL_5_on_Windows.html said to do

and It works fine with http://localhost everytime but http://localhost/phptest.php comes up: 400 Bad Request

Your browser sent a request that this server could not understand.

 

Im using the apache cgi install which is probably why i dont get the "[warn] php module is already loaded skipping

 

[warn] php module is already loaded skipping" anymore.

 

and

<?php

phpinfo();

?> is the only code.

Link to comment
https://forums.phpfreaks.com/topic/94207-beginner-php-trouble/#findComment-482562
Share on other sites

When I use phpinfo(); I use it to test if certain libraries are enabled, and other settings, etc.. for my hosted server.

I know you're havng problems, but I'm curious why you need to test out phpinfo();?

 

If you haven't already, try testing some other code.

Link to comment
https://forums.phpfreaks.com/topic/94207-beginner-php-trouble/#findComment-482573
Share on other sites

I wasn't mocking him and if i came off that way im sorry, i just didnt understand what he was talking about.

I'm using the phpinfo script to check if php is working on my computer. I'm also using

 

 

<?php

 

  print ("this is a test");

 

?>

 

and the same thing happens, a page with "400 Bad Request

Your browser sent a request that this server could not understand."

 

 

I didn't know phpinfo could be used like that, since I'm a new user I just want to get it installed and properly running.

 

sorry again for any misunderstandings.

Link to comment
https://forums.phpfreaks.com/topic/94207-beginner-php-trouble/#findComment-482583
Share on other sites

It's cool, I didn't take it as offensive in any manner  ;)

 

 

I'm surprised thorpe, or any of the admins haven't shown up yet. They've probably seen errors like this before.

 

If ultimately you can't get localhost to work, I suppose your only other options are to get some free/buy server space, and test it all out there.

Link to comment
https://forums.phpfreaks.com/topic/94207-beginner-php-trouble/#findComment-482588
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • 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.