httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Eric Belardo" <eric.bela...@comcast.net>
Subject RE: [users@httpd] New List member Problem
Date Sun, 28 Dec 2003 20:12:47 GMT
Jonas,

This is the exercise:

First this HTML:

HTML>
<HEAD>
<TITLE> Redirection Menu </TITLE>
</HEAD>

<BODY>

<FORM METHOD="post" ACTION="do_redirect.php">

<P> Choose The Website you wish to visit: 

<SELECT name="location">

	<OPTION value="http://www.themomshack.com/">The Mom
Shack</OPTION>
	<OPTION value="http://www.nolonelynights.com/">No Lonely Nights
Dating</OPTION>
	<OPTION value="http://www.pearlsofwealth.com/themomshack/">The
Mom shack Safelist</OPTION>

</SELECT>

<P><INPUT TYPE="submit" NAME="submit" Value="Click Here to Go!"></P>

</FORM>
</BODY>
</HTML>

CALLS THIS PHP SCRIPT:

<?
header( "Location: $_POST[location]");
exit;
?>

ANY THOUGHTS??? 

Please I would appreciate ANY HELP !!!!

Eric 


-----Original Message-----
From: Jonas Eckerman [mailto:jonas_lists@frukt.org] 
Sent: Sunday, December 28, 2003 2:42 PM
To: users@httpd.apache.org
Subject: RE: [users@httpd] New List member Problem

On Sun, 28 Dec 2003 13:33:38 -0500, Eric Belardo wrote:

>  ScriptAlias /cgi-bin/ "C:/Program Files/Apache Group/Apache/cgi-
>  bin/" ScriptAlias /php/ "C:/Documents and Settings/Eric Belardo/My
>  Documents/WebSite Development/PHP4.3.4./php-4.3.4-Win32/"

This doesn't look like enough to actually use PHP. All you do here is
tell Apache that stuff in "C:/Documents and Settings/Eric Belardo/My
Documents/WebSite Development/PHP4.3.4./php-4.3.4-Win32/" are CGIs.

Have you added a handler that makes Apache call PHP for files ending in
.php? The PHP site has documentation for how you enable PHP with Apache
on Windows.

>  simple script which uses PHP to redirect to another website

>  It still gave me the error 405 POST

This is odd. What does your script look like, and how do you invoke it?
A simple redirect to another site should not make the browser send a
POST (unless it is a POST that gets redirected), and if you just put in
the URL to the script in your browser, that shouldn't generate any POSTs
either.

Why did the browser send a POST? Are you sure you're not using forms or
anything like that here?
If you are, don't. Keep everything as simple as possible while testing
wether PHP works or not. Actually, don't even try to redirect, start
testing with a simple "Hello world" PHP page. After you've got a "Hello
world" to work, try with a php_info. Once that works and looks right, go
on with redirects or whatever.

And: Is this error message from your server or the one you try to
redirect to? It is possible that the redirect actually works but
redirects a POST to a server that doesn't allow POST.

Regards
/Jonas
-- 
Jonas Eckerman, jonas_lists@frukt.org
http://www.fsdb.org/


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server
Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Mime
View raw message