FORUMS


The Form Tools forums are no longer active, but the old posts have been archived here. Please see the Help page on how to get help / report issues.

Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
SSL and Formtools
#1
Has anyone used a SSL page in Form Tools for capturing credit card info? If so, where did you code the Secure Link info? I have set the $g_db_ssl = "true" parm in the config.php file and added the SSL info on the one page of a 5 page registration form, but so not see the SSL info in the url on that page.

I am using Form Tools 2.0.4 and do have a SSL certificate installed.

I am able to connect to the first page...however, I get :
The requested URL /2011/step1.php was not found on this server. It seems the complete url of my website is missing.

Thanks in advance.
Reply
#2
Hi parrothead,

I only ever used that SSL setting on one site and it was a quite a while back.

I'm actually not quite clear on the problem though: so the first page of the form works okay, but it doesn't redirect to the second? If so, if you're using the API: check the "next_page" parameter value being passed to your ft_api_process_form() function. If you're not using the API, check the Redirect URL field on your Edit Form -> Main tab.

But neither problem should be related to SSL.

Let me know if I misunderstood this!

- Ben
Reply
#3
Thanks for the reply Ben...

The first page is fine with https://ssl4.westserver.net/phinstothewe...ration.php.
(it is the basic instructions and data collection, it transfers to the first pages just fine.

It transfers to https://ssl4.westserver.net/phinstothewe.../step1.php just fine.
I have the parms set in page 1 as:
$params = array(
"submit_button" => "continue",
"next_page" => "step2.php",
"form_data" => $_POST,
"file_data" => $_FILES
);

When I het the continue button, I get
"The requested URL /2011/step1.php was not found on this server" (Step1 is what is showing) it seems the
https://ssl4.westserver.net/phinstothewest.com portion is missing!!!

Does the "next_page" need to have the fully qualified url? That didnt seem to work well either


Thanks So Much!!!
Reply
#4
Ah! The problem is the action attribute of your form tag: in the generated source it has /2011/step1.php - which is incorrect.

Is that value hardcoded? If so, replace it with this:

Code:
<form ...  action="<?php echo $_SERVER["PHP_SELF"]?>" ... >

- Ben
Reply
#5
Hummm.... .

the form code is as below:
registration.php <form action="step1.php" onsubmit="return checkCheckBox(this)">

<table width="100%" cellpadding="0" cellspacing="0">
<TR>

<TD><font face="Comic Sans MS" size="4"><br>


Click on the checkbox to accept the Terms & Conditions for<br> Phin to the West <?php echo $event_year;?><br>
I accept the Terms and Condidions as identified above:
<input type="checkbox" value="0" name="agree"> <br>
This does go to the https://ssl4.westserver.net/phinstothewe.../step1.php page...

Step1.php
<form name="regform" action="<?php echo $_SERVER["PHP_SELF"]?>" onsubmit="return rsv.validate(this, rules)" method="post">

when I click on the continue button I still am getting the
The requested URL /2011/step1.php was not found on this server. from there!


Step2:
<form name="regform" action="<?=$_SERVER['PHP_SELF']?>" method="post">


I just changed the action to your suggestion and updated the form urls... same result
Reply
#6
Huh! Stranger and stranger.

In that case, $_SERVER["PHP_SELF"] is generating an invalid value for your server environment. This is pretty serious.

To test, on your step1.php file, change the action attribute to this:

Code:
action="/phinstothewest.com/2011/step1.php"

PHP_SELF *should* be outputting that value, but it's outputting /2011/step1.php instead - which is invalid!

- Ben
Reply
#7
OK... that works and I can get to the next page...

then same problem.. i can fix that...but then the page after that one (page 4) I can go to a different page dependent on if they are paying by check or credit card... how can I handle that??


if ($fields['Payment_Type'] == 'Check')
{
$params = array(
"submit_button" => "continue",
"next_page" => "step4check.php",
"form_data" => $_POST,
"file_data" => $_FILES,
"no_sessions_url" => "step1.php"
);
ft_api_process_form($params);
}
else
{
$params = array(
"submit_button" => "continue",
"next_page" => "step4credit.php",
"form_data" => $_POST,
"file_data" => $_FILES,
"no_sessions_url" => "step1.php"
);

.....
....

<form method="post" action="<?=$_SERVER['PHP_SELF']?>">


Thanks for your help!


set a variable dependent on the payment selected and use that in the action???
Reply
#8
Yeah, what you described may work - unless the Payment_Type field is on that page. If so, I'd do:

Code:
if ($_POST["Payment_Type"] == "Check")
{
...
}

This is because I think $fields only gets updated by ft_api_process_form & won't contain the right value at that point.

But I'm still a little puzzled about your $_SERVER["PHP_SELF"] doling up an incorrect value... I haven't seen that before. If Form Tools is located at that same location, I can't see it working properly.

I'd be tempted to fire off an email to your host entitled "What the WHAT?" and ask them what's up.

- Ben
Reply
#9
OK things are working well with that change ... ONCE AGAIN... YOU ROCK Ben!!!
Reply
#10
Hosting company replied " use of absolute URL should always be used"
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)