Confirm Page Variables? - Page 1

User 69715 Photo


Registered User
30 posts

Hello, all

I'm trying to set up a confirmation page using the redirect URL option in WFB. The redirect works but I don't seem able to call up any of the $_POST or $_GET variables from the form.

Am I missing something?

:0/

Perchpole

User 187934 Photo


Senior Advisor
20,190 posts
Online Now

<?php
$myvariablename = $_POST['myvariablename'];
echo $myvariablename;
?>
I can't hear what I'm looking at.
It's easy to overlook something you're not looking for.

This is a site I built for my work.(RSD)
http://esmansgreenhouse.com
This is a site I built for use in my job.(HTML Editor)
https://pestlogbook.com
This is my personal site used for testing and as an easy way to share photos.(RLM imported to RSD)
https://ericrohloff.com
User 69715 Photo


Registered User
30 posts

Hi, Eric -

That's exactly what I'm using but there's nothing coming back. I've used the following code to print out the entire array:

<?php
print('<pre>');
print_r($_POST);
print('</pre>');
?>

but all I get is...

Array
(
)

Most annoying!

:0/

Perchpole
User 187934 Photo


Senior Advisor
20,190 posts
Online Now

Try this.
<?php
print '<pre>';
print_r ($_POST);
print '</pre>';
?>
I can't hear what I'm looking at.
It's easy to overlook something you're not looking for.

This is a site I built for my work.(RSD)
http://esmansgreenhouse.com
This is a site I built for use in my job.(HTML Editor)
https://pestlogbook.com
This is my personal site used for testing and as an easy way to share photos.(RLM imported to RSD)
https://ericrohloff.com
User 69715 Photo


Registered User
30 posts

Hi, Eric -

Just the same. All I get is an empty array.

Array
(
)

:0/

Perchpole
User 187934 Photo


Senior Advisor
20,190 posts
Online Now

Did you try grabbing a single variable?
I can't hear what I'm looking at.
It's easy to overlook something you're not looking for.

This is a site I built for my work.(RSD)
http://esmansgreenhouse.com
This is a site I built for use in my job.(HTML Editor)
https://pestlogbook.com
This is my personal site used for testing and as an easy way to share photos.(RLM imported to RSD)
https://ericrohloff.com
User 69715 Photo


Registered User
30 posts

Yes. There's nothing there! It just isn't passing the $_POST data to the confirmation page.
User 187934 Photo


Senior Advisor
20,190 posts
Online Now

Sorry I miss understood your post. You have to do this on the mydformname.php. So build your own and replace the one that the form builder makes then do a redirect from there.
I can't hear what I'm looking at.
It's easy to overlook something you're not looking for.

This is a site I built for my work.(RSD)
http://esmansgreenhouse.com
This is a site I built for use in my job.(HTML Editor)
https://pestlogbook.com
This is my personal site used for testing and as an easy way to share photos.(RLM imported to RSD)
https://ericrohloff.com
User 69715 Photo


Registered User
30 posts

Eric -

myformname.php looks like this...

<?php

$scriptpath = substr( $_SERVER['SCRIPT_FILENAME'], 0, -4 );
$paths = explode ( DIRECTORY_SEPARATOR , $scriptpath );
$myName = end($paths);
require $scriptpath . '/fbapp/php/config.inc.php';


if( strtoupper( $_SERVER['REQUEST_METHOD'] ) == 'POST' ) {

$ctl = new FormController();
$ctl->Dispatch();

} else {

if( ! isset( $_GET['action'] ) ) $myPage->ReportStats( 'NotifyFormView' );
}

ob_start();

$myPage->Show();
ob_end_flush();

?>


Can you explain what I need to change, please?

Perchpole

User 187934 Photo


Senior Advisor
20,190 posts
Online Now

Make your own with the code you were using before.:)
I can't hear what I'm looking at.
It's easy to overlook something you're not looking for.

This is a site I built for my work.(RSD)
http://esmansgreenhouse.com
This is a site I built for use in my job.(HTML Editor)
https://pestlogbook.com
This is my personal site used for testing and as an easy way to share photos.(RLM imported to RSD)
https://ericrohloff.com

Have something to add? We’d love to hear it!
You must have an account to participate. Please Sign In Here, then join the conversation.