close ad
Install the LAtest Updates to Work with CC 2017 and CC 2018
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Registration Form with php include

Thread began 8/07/2014 1:21 am by Bello | Last modified 8/07/2014 8:43 pm by Jason Byrnes | 1152 views | 5 replies |

Bello

Registration Form with php include

hello, please i have a registration page generated by security assist and with the structure of my site i am to include it into a page that loads multiple php files when u append its url (e.g: trial.php?key=registration)..here is my script below..the issue is whenever the registration page is included..it doesnt submit the form not validate the form...it redirects to the php file that loads the page(i.e trial.php)...any help will be appreciated as i am on a hot sit now thanks.


The page that loads other php files:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
</head>

<body>

header...Goes here


<?php

$key=$_GET['key'];

if($key=='home')
{
include('home.php'); // Home page
}
else if($key=='login')
{
include('login.php'); // Login page
}
else if($key=='registration')
{
include('registration.php'); // Terms page
}
else
{
include('users.php'); // Users Gateway
}
?>

<br />
<br />


footer...Goes here


</body>
</html>



My registration is the normal registration page generated by webassist...i havent tested the logins and update pages but sure i know they might react in similar patter..thanks

Sign in to reply to this post

Jason ByrnesWebAssist

Dont use include() to add the registration page:
include('registration.php'); // Terms page


That is not a very good way to add a page to another as the php code on the registration page above the doctype will now be in the body of the trial page, and it will also include multiple head and body sections.


Instead, Use framework Builder Dynamic Plugins

Open the bindings panel. Click the plus button and create a new URL variable binding, name it key

Then go to WebAssist -> Framework Builder -> Plug-in -> Insert Dynamic Plug-in

for the trigger variable, select the key URL variable. For the Plugin source, select the registration page, and the variable value use reg

Sign in to reply to this post

Bello

Wow...thanks....didnt know i had such a tool at hand...thanks a tone of a million...you reli made my day..pls guys dont sell your company like InterAKT....

Sign in to reply to this post

Jason ByrnesWebAssist

you're welcome.

Sign in to reply to this post

Bello

ok well ..it solved the issue to an extent...but the main issue remains unsolved...i did as commanded..but on clicking submit, the regisration page goes back to the "trial.php" without inserting or even validating the page..i attached the two files for you to see..i can also attach all the files if requested..

here is the scenario: i typed: - "page-loader.php?mod=email-here" - this is the registration page...and after clicking submit button..it goes back to "page-loader.php" without validating or inserting the form in the database...and this happens only of included in another page either by include or by webassist framework.

Attached Files
page-loader.php
registration.php
start-here-1.php
Sign in to reply to this post

Jason ByrnesWebAssist

Since the page is being loaded with a URL variable as the trigger, you will need to modify the action of the registration form so that it passes the URL variable on post.


change the action:
action="<?php echo (htmlentities($_SERVER["PHP_SELF"], ENT_QUOTES)); ?>"

to:
action="<?php echo (htmlentities($_SERVER["PHP_SELF"], ENT_QUOTES)); ?><?php echo (isset($_SERVER["QUERY_STRING"]) && $_SERVER["QUERY_STRING"] != "")?"?".htmlentities($_SERVER["QUERY_STRING"], ENT_QUOTES):""; ?>"

Sign in to reply to this post

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...