Pete,
I just copied what I had put into the .php.html file in order to get
things working with the redirect and all. Now both GET and POST to the
.php URL seem to work.
I don't know why this is needed if all is essentially back to the way it
was originally. Before all this began, both GET and POST worked as expected.
I am thinking that somewhere, there is still redirection going on for
the GET so this code introduced into the .php.html:
if(strcmp($_SERVER['REQUEST_METHOD'], "GET") == 0)
{
// get the request query bits
if (strpos($_SERVER["REQUEST_URI"], "?")) {
$QueryString = explode("?", $_SERVER["REQUEST_URI"]);
$QueryArray = explode("&", $QueryString[1]);
foreach ($QueryArray as $QueryItem) {
$QuerySegment = explode("=", $QueryItem, 2);
$_GET[$QuerySegment[0]] = urldecode($QuerySegment[1]);
}
}
// get input parameters
$DEBUG_ENABLED = $_GET["test"];
$EMAIL_ADDRESS = $_GET["emailAddress"];
$THUNDERPLUNGER_ID = $_GET["accessKey"];
}
else
{
$DEBUG_ENABLED = $_REQUEST["test"];
$EMAIL_ADDRESS = $_REQUEST["emailAddress"];
$THUNDERPLUNGER_ID = $_REQUEST["accessKey"];
}
in place of the simpler:
$DEBUG_ENABLED = $_REQUEST["test"];
$EMAIL_ADDRESS = $_REQUEST["emailAddress"];
$THUNDERPLUNGER_ID = $_REQUEST["accessKey"];
Is still needed. I have no idea why or if this is what you intend.
But if things are going to stay this way, I can leave my addon as it was
and can remove the update I created yesterday. Please advise.
Thanks for all your time and effort in all of this.
David
>Thanks Pete,
>
>If I change my ThunderPlunger addon's code back to POST instead of GET,
>the .php seems to work. However, a GET to the .php fails for some
>reason. Before all of this, the GET did work for debugging using FF as
>long as the test=1 query parameter was included. Now this isn't >working.
>
>The one other thing I did do in all of this was also suggested by a
>chap on the list. I added the following to my project's local.conf >file:
>
>if(strstr($_SERVER['SCRIPT_URL'], 'validateEmail.php.html'))
> $local_conf_serve_as_is = ON;
>
>I don't see why that should impact anything on the .php URL. Any
>suggestions?
>
>Thanks, David
Pete Collins wrote:
I think I have this fixed.
Can you give it a spin?
Running the javascript POST test code I got an error saying that the
email address was not valid.
So, I think it is working.
Thanks
--pete
_______________________________________________
Project_owners mailing list
Project_owners@mozdev.org
https://www.mozdev.org/mailman/listinfo/project_owners