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

url path wrong only on 1 file

Thread began 4/03/2010 12:16 pm by webmaster403691 | Last modified 4/12/2010 9:42 pm by Jimmy Wu | 905 views | 5 replies |

webmaster403691

url path wrong only on 1 file

Hi all,

1 little issue has me stumped. User registers, gets email confirmation link and is successful, goes to log in page registra...sers_LogIn.php

Upon submitting their u and p, the page that comes up showing an error, and the url is wrong registra...ers_LogIn.php?

You'll notice the folder registration//registration/ twice. Why is it putting the folder in 2 times? All other paths work... strange, my global settings are as follows:

<?php
$WAGLOBAL_Root_URL = "http://www.guestmoments.com/registration/" ;
$WAGLOBAL_Captcha_Width = "200" ;
$WAGLOBAL_Captcha_Height = "40" ;
$WAGLOBAL_Captcha_Characters = "5" ;
$WAGLOBAL_Captcha_Font = "Fonts/MOM_T___.TTF" ;
$WAGLOBAL_Captcha_BG = "ffffff" ;
$WAGLOBAL_Captcha_Noise = "437b9f" ;
$WAGLOBAL_Captcha_Text = "000000" ;
$WAGLOBAL_Captcha_BG_transparent = "0" ;
$WAGLOBAL_Email_Server = "mail.guestmoments.com " ;
$WAGLOBAL_Verification_Email_Subject = "Guest Moments Partner Program Email Verification" ;
$WAGLOBAL_Verification_Email_FROM = "partners@guestmoments.com" ;
$WAGLOBAL_Verification_Email_CC = "" ;
$WAGLOBAL_Verification_Email_BCC = "" ;
$WAGLOBAL_Registration_Email_Subject = "Welcome to the Guest Moments Partner Program" ;
$WAGLOBAL_Registration_Email_FROM = "partners@guestmoments.com" ;
$WAGLOBAL_Registration_Email_CC = "" ;
$WAGLOBAL_Registration_Email_BCC = "" ;
$WAGLOBAL_Password_Email_Subject = "Your Guest Moments Partner Program Password" ;
$WAGLOBAL_Password_Email_FROM = "partners@guestmoments.com" ;
$WAGLOBAL_Password_Email_CC = "" ;
$WAGLOBAL_Password_Email_BCC = "" ;
$WAGLOBAL_Admin_UserName = "xxxxxx" ;
$WAGLOBAL_Admin_Password = "xxxxxx" ;
?>

Thanks for all your assistance!

Dino

Sign in to reply to this post

Jimmy Wu

On your users_Login.php page, do a search for successRedirect and make sure that the line of code looks like this:
"successRedirect" => "users_Profile.php",

If its forwarding with an extra /registration, that line might look like this:
"successRedirect" => "/registration/users_Profile.php",

Sign in to reply to this post

webmaster403691

url path wrong only on 1 file

Hi Jimmy,

Code looks fine... any other ideas?

<?php require_once('Connections/localhost.php');?>
<?php require_once("WA_ValidationToolkit/WAVT_Scripts_PHP.php"); ?>
<?php require_once("WA_ValidationToolkit/WAVT_ValidatedForm_PHP.php"); ?>
<?php require_once( "WA_SecurityAssist/Helper_PHP.php" ); ?><?php
if (!isset($_SESSION)) {
session_start();
}
?>
<?php
if (isset($_POST["LogIn_x"])) {
$WAFV_Redirect = "users_LogIn.php?valid=false";
$_SESSION['WAVT_usersLogIn_Errors'] = "";
if ($WAFV_Redirect == "") {
$WAFV_Redirect = $_SERVER["PHP_SELF"];
}
$WAFV_Errors = "";
$WAFV_Errors .= WAValidateEM(((isset($_POST["username"]))?$_POST["username"]:"") . "",true,1);
$WAFV_Errors .= WAValidateEL(((isset($_POST["userpassword"]))?$_POST["userpassword"]:"") . "",6,50,true,2);
$WAFV_Errors .= WAValidateRX(((isset($_POST["userpassword"]))?$_POST["userpassword"]:"") . "","/[0-9]/",true,3);
$WAFV_Errors .= WAValidateRX(((isset($_POST["userpassword"]))?$_POST["userpassword"]:"") . "","/[a-z,A-Z]/",true,4);

if ($WAFV_Errors != "") {
PostResult($WAFV_Redirect,$WAFV_Errors,"usersLogIn");
}
}
?>
<?php
if (isset($_POST["LogIn_x"])) {
setcookie("AutoLoginUN", "", time()+(60*60*24*30), "/", "", 0);
}
?><?php
if ((((isset($_POST["autologinoption"]))?$_POST["autologinoption"]:"") != "")) {
setcookie("AutoLoginPWD", "".((isset($_POST["userpassword"]))?$_POST["userpassword"]:"") ."", time()+(60*60*24*30), "/", "", 0);
}
?><?php
if ((((isset($_POST["autologinoption"]))?$_POST["autologinoption"]:"") != "")) {
setcookie("AutoLoginUN", "".((isset($_POST["username"]))?$_POST["username"]:"") ."", time()+(60*60*24*30), "/", "", 0);
}
?><?php
if ((((isset($_POST["remembermeoption"]))?$_POST["remembermeoption"]:"") != "")) {
setcookie("RememberMePWD", "".((isset($_POST["userpassword"]))?$_POST["userpassword"]:"") ."", time()+(60*60*24*30), "/", "", 0);
}
?><?php
if ((((isset($_POST["remembermeoption"]))?$_POST["remembermeoption"]:"") != "")) {
setcookie("RememberMeUN", "".((isset($_POST["username"]))?$_POST["username"]:"") ."", time()+(60*60*24*30), "/", "", 0);
}
?><?php
if (isset($_POST["LogIn_x"]) && !isset($_POST["remembermeoption"])) {
setcookie("RememberMePWD", "", time()+(60*60*24*30), "/", "", 0);
}
?><?php
if (isset($_POST["LogIn_x"]) && !isset($_POST["remembermeoption"])) {
setcookie("RememberMeUN", "", time()+(60*60*24*30), "/", "", 0);
}
?>
<?php
if(($_SERVER["REQUEST_METHOD"] == "POST") && (isset($_SERVER["HTTP_REFERER"]) && strpos(urldecode($_SERVER["HTTP_REFERER"]), urldecode($_SERVER["SERVER_NAME"].$_SERVER["PHP_SELF"])) > 0) && isset($_POST)){
$WA_Auth_Parameter = array(
"connection" => $localhost,
"database" => $database_localhost,
"tableName" => "users",
"columns" => explode($WA_Auth_Separator,"UserEmail".$WA_Auth_Separator."UserPassword"),
"columnValues" => explode($WA_Auth_Separator,"".((isset($_POST["username"]))?$_POST["username"]:"") ."".$WA_Auth_Separator."".((isset($_POST["userpassword"]))?$_POST["userpassword"]:"") .""),
"columnTypes" => explode($WA_Auth_Separator,"text".$WA_Auth_Separator."text"),
"sessionColumns" => explode($WA_Auth_Separator,"UserID".$WA_Auth_Separator."UserEmailVerified".$WA_Auth_Separator."UserEmail"),
"sessionNames" => explode($WA_Auth_Separator,"UserID".$WA_Auth_Separator."UserEmailVerified".$WA_Auth_Separator."UserEmail"),
"successRedirect" => "users_Profile.php",
"failRedirect" => "users_LogIn.php?failed=1",
"gotoPreviousURL" => TRUE,
"keepQueryString" => TRUE
);

WA_AuthenticateUser($WA_Auth_Parameter);
}
?>
<?php
if((((isset($_SESSION["UserID"]) && $_SESSION["UserID"] != "")?"LoggedIn":"") == "")&&(((isset($_COOKIE["AutoLoginUN"]))?$_COOKIE["AutoLoginUN"]:"") != "")&&(((isset($_COOKIE["AutoLoginPWD"]))?$_COOKIE["AutoLoginPWD"]:"") != "")){
$WA_Auth_Parameter = array(
"connection" => $localhost,
"database" => $database_localhost,
"tableName" => "users",
"columns" => explode($WA_Auth_Separator,"UserEmail".$WA_Auth_Separator."UserPassword"),
"columnValues" => explode($WA_Auth_Separator,"".((isset($_COOKIE["AutoLoginUN"]))?$_COOKIE["AutoLoginUN"]:"") ."".$WA_Auth_Separator."".((isset($_COOKIE["AutoLoginPWD"]))?$_COOKIE["AutoLoginPWD"]:"") .""),
"columnTypes" => explode($WA_Auth_Separator,"text".$WA_Auth_Separator."text"),
"sessionColumns" => explode($WA_Auth_Separator,"UserID".$WA_Auth_Separator."UserEmailVerified".$WA_Auth_Separator."UserEmail"),
"sessionNames" => explode($WA_Auth_Separator,"UserID".$WA_Auth_Separator."UserEmailVerified".$WA_Auth_Separator."UserEmail"),
"successRedirect" => "users_Profile.php",
"failRedirect" => "",
"gotoPreviousURL" => TRUE,
"keepQueryString" => TRUE
);

WA_AuthenticateUser($WA_Auth_Parameter);
}
?>

Sign in to reply to this post

Jimmy Wu

Can you attach a copy of the users_Login.php page that you have please and also the WA_Globals.php file as well?

Can you send me a link to the live page so I can try registering?

Sign in to reply to this post

webmaster403691

Hi Jimmy,

Got it all figured out.

Thank you very much.

Sign in to reply to this post

Jimmy Wu

Great to hear it. If you would be willing to outline the steps you took to resolve the issue, that'd be appreciated, since other users may benefit from it as well. If you run into any additional issues, feel free to open a new thread.

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...