PDA

View Full Version : Single Page Password Protect Problem



RNA
08-26-2010, 03:30 PM
Hi I've tried to password protect a single page of a website but its not working correctly, I have added the icon to the page in bluevoda, set the password and published as php. However when I enter the password it takes me to a success page.

I've right clicked the icon in bluevoda but there's no field to set your success page as the page you want to reveal in the properties.

Can somebody please tell me where I'm going wrong.

The page is www.insurancetelesales.co.uk/login.php (http://www.insurancetelesales.co.uk/login.php) and the password is lauaw.

Cheers

navaldesign
08-27-2010, 06:06 AM
Please post here the code of the page

meetmec12
08-27-2010, 09:29 AM
can i create accounts for members,and then give them the user name and password and can i create user name with(nums,specials '/,<.> etc) pls help@all.Okay maybe i should let you folks know what im trying to do.This is it:I want to build a school website and i want the students to buy the pin and serial num(user name and password )which they'll need to open a form page on the website.I hope i get the help i need please my job is at stake here.help a brother.

RNA
08-27-2010, 10:13 AM
<?php
session_start();
$password = '';
if($_SERVER['REQUEST_METHOD'] == 'POST')
{
$password = isset($_POST['password']) ? $_POST['password'] : '';
if ($password == 'lauraw')
{
$_SESSION['password'] = $password;
}
}
else
{
$password = isset($_SESSION['password']) ? $_SESSION['password'] : '';
}
if ($password != 'lauraw')
{
echo "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\">\n";
echo "<html>\n";
echo "<head>\n";
echo "<meta http-equiv=\"Content-Type\" content=\"text/html; charset=ISO-8859-1\">\n";
echo "<title>Untitled Page</title>\n";
echo "</head>\n";
echo "<body>\n";
echo "<center>\n";
echo "<br>\n";
if($_SERVER['REQUEST_METHOD'] == 'POST')
echo "<span style=\"font-size:11px;font-family:Verdana;font-weight:normal;text-decoration:none;color:#FF0000\">The specified password is invalid!<br><br><br></span>\n";
else
echo "<span style=\"font-size:11px;font-family:Verdana;font-weight:normal;text-decoration:none;color:#535353\">This page is password protected.<br><br><br></span>\n";
echo "<form method=\"post\" action=\"".basename(__FILE__)."\">\n";
echo " <table cellspacing=\"0\" cellpadding=\"3\" border=\"0\" bgcolor=\"#FFFFFF\" style=\"border:1px solid #535353;\">\n";
echo " <tr>\n";
echo " <td colspan=\"2\" bgcolor=\"#535353\" style=\"text-align:center;padding:4px;font-size:11px;font-family:Verdana;font-weight:normal;text-decoration:none;color:#FFFFFF\"><b>Login</b></td>\n";
echo " </tr>\n";
echo " <tr>\n";
echo " <td style=\"font-size:11px;font-family:Verdana;font-weight:normal;text-decoration:none;color:#535353\" align=\"right\" width=\"30%\" height=\"60\">Password:</td>\n";
echo " <td style=\"font-size:11px;font-family:Verdana;font-weight:normal;text-decoration:none;color:#535353\" align=\"left\" width=\"70%\" height=\"60\"><input type=\"password\" name=\"password\" value=\"\" style=\"border:1px solid #535353;width:120px;\">&nbsp;&nbsp;<input type=\"submit\" value=\"Login\"></td>\n";
echo " </tr>\n";
echo " </table>\n";
echo "</form>\n";
echo "</center>\n";
echo "</body>\n";
echo "</html>\n";
exit;
}
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Untitled Page</title>
<meta name="GENERATOR" content="Created by BlueVoda">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<div id="bv_Shape3" style="position:absolute;left:0px;top:0px;width:957px;hei ght:1303px;z-index:70;" align="center">
<img src="images/bv01597.gif" id="Shape3" align="top" alt="" title="" border="0" width="957" height="1303"></div>
<div id="bv_Shape1" style="position:absolute;left:170px;top:31px;width:754px; height:1248px;z-index:71;" align="center">
<img src="images/bv01595.gif" id="Shape1" align="top" alt="" title="" border="0" width="754" height="1248"></div>
<div id="bv_Text1" style="position:absolute;left:378px;top:43px;width:245px; height:24px;z-index:72;" align="left">
<font style="font-size:21px" color="#00005E" face="Arial"><b>Lead Submission Form</b></font></div>
<div id="bv_Shape2" style="position:absolute;left:3px;top:31px;width:158px;he ight:681px;z-index:73;" align="center">
<img src="images/bv01596.gif" id="Shape2" align="top" alt="" title="" border="0" width="158" height="681"></div>
<div id="bv_Text2" style="position:absolute;left:15px;top:40px;width:124px;h eight:22px;z-index:74;" align="left">
<font style="font-size:19px" color="#00005E" face="Arial"><b>Reasouces</b></font></div>
<div id="bv_Text3" style="position:absolute;left:19px;top:287px;width:115px; height:16px;z-index:75;" align="left">
<font style="font-size:13px" color="#00005E" face="Arial">Webline Quote</font></div>
<div id="bv_Text4" style="position:absolute;left:16px;top:100px;width:127px; height:32px;z-index:76;" align="left">
<font style="font-size:13px" color="#00005E" face="Arial">Home &amp; Contents Script</font></div>
<div id="bv_Text5" style="position:absolute;left:16px;top:144px;width:150px; height:16px;z-index:77;" align="left">
<font style="font-size:13px" color="#00005E" face="Arial">Bill Protector Script </font></div>
<div id="bv_Text6" style="position:absolute;left:17px;top:177px;width:150px; height:16px;z-index:78;" align="left">
<font style="font-size:13px" color="#00005E" face="Arial">Life Insurance Script</font></div>
<div id="bv_Text7" style="position:absolute;left:17px;top:206px;width:150px; height:32px;z-index:79;" align="left">
<font style="font-size:13px" color="#00005E" face="Arial">Business Insurance Script</font></div>
<div id="bv_Text8" style="position:absolute;left:17px;top:253px;width:124px; height:19px;z-index:80;" align="left">
<font style="font-size:16px" color="#00005E" face="Arial"><b>Quoting</b></font></div>
<div id="bv_Text9" style="position:absolute;left:17px;top:324px;width:124px; height:19px;z-index:81;" align="left">
<font style="font-size:16px" color="#00005E" face="Arial"><b>Websites</b></font></div>
<div id="bv_Text10" style="position:absolute;left:15px;top:75px;width:150px;h eight:19px;z-index:82;" align="left">
<font style="font-size:16px" color="#00005E" face="Arial"><b>Scripts</b></font></div>
<div id="bv_Form1" style="position:absolute;left:253px;top:93px;width:608px; height:1152px;background-color:#E1E1E1;z-index:83;" align="left">
<form name="Lead Submission" method="POST" action="<? echo($_SERVER['PHP_SELF']);?>" id="Form1">
<div id="bv_Text11" style="position:absolute;left:10px;top:15px;width:240px;h eight:16px;z-index:0;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">Sales Advisor:</font></div>
<select name="Combobox1" size="1" id="Combobox1" style="position:absolute;left:260px;top:15px;width:200px; font-family:Arial;font-size:16px;z-index:1">
<option></option>
<option>Sue Reed</option>
<option>Ben Hole</option>
<option>Sarah Taylor</option>
<option>Andrew Campbelton</option>
</select>
<div id="bv_Text12" style="position:absolute;left:10px;top:44px;width:240px;h eight:16px;z-index:2;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">First Name:</font></div>
<input type="text" id="Editbox1" style="position:absolute;left:260px;top:44px;width:200px; font-family:Arial;font-size:16px;z-index:3" name="First Name:" value="">
<div id="bv_Text13" style="position:absolute;left:10px;top:73px;width:240px;h eight:16px;z-index:4;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">Surname:</font></div>
<input type="text" id="Editbox2" style="position:absolute;left:260px;top:73px;width:200px; font-family:Arial;font-size:16px;z-index:5" name="Surname:" value="">
<div id="bv_Text14" style="position:absolute;left:10px;top:102px;width:240px; height:16px;z-index:6;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">Date of Birth:</font></div>
<input type="text" id="Editbox3" style="position:absolute;left:260px;top:102px;width:200px ;font-family:Arial;font-size:16px;z-index:7" name="Date of Birth:" value="">
<div id="bv_Text15" style="position:absolute;left:10px;top:131px;width:240px; height:16px;z-index:8;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">Address:</font></div>
<input type="text" id="Editbox4" style="position:absolute;left:260px;top:131px;width:200px ;font-family:Arial;font-size:16px;z-index:9" name="address" value="">
<div id="bv_Text16" style="position:absolute;left:10px;top:160px;width:240px; height:16px;z-index:10;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">Town:</font></div>
<input type="text" id="Editbox5" style="position:absolute;left:260px;top:160px;width:200px ;font-family:Arial;font-size:16px;z-index:11" name="Town:" value="">
<div id="bv_Text17" style="position:absolute;left:10px;top:189px;width:240px; height:16px;z-index:12;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">City:</font></div>
<input type="text" id="Editbox6" style="position:absolute;left:260px;top:189px;width:200px ;font-family:Arial;font-size:16px;z-index:13" name="City:" value="">
<div id="bv_Text18" style="position:absolute;left:10px;top:218px;width:240px; height:16px;z-index:14;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">Postcode:</font></div>
<input type="text" id="Editbox7" style="position:absolute;left:260px;top:218px;width:200px ;font-family:Arial;font-size:16px;z-index:15" name="Postcode" value="">
<div id="bv_Text19" style="position:absolute;left:10px;top:247px;width:240px; height:16px;z-index:16;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">Phone:</font></div>
<input type="text" id="Editbox8" style="position:absolute;left:260px;top:247px;width:200px ;font-family:Arial;font-size:16px;z-index:17" name="phone" value="">
<div id="bv_Text20" style="position:absolute;left:10px;top:276px;width:240px; height:16px;z-index:18;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">Work:</font></div>
<input type="text" id="Editbox9" style="position:absolute;left:260px;top:276px;width:200px ;font-family:Arial;font-size:16px;z-index:19" name="Work:" value="">
<div id="bv_Text21" style="position:absolute;left:10px;top:305px;width:240px; height:16px;z-index:20;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">Mobile:</font></div>
<input type="text" id="Editbox10" style="position:absolute;left:260px;top:305px;width:200px ;font-family:Arial;font-size:16px;z-index:21" name="Mobile:" value="">
<div id="bv_Text22" style="position:absolute;left:10px;top:334px;width:240px; height:16px;z-index:22;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">Email:</font></div>
<input type="text" id="Editbox11" style="position:absolute;left:260px;top:334px;width:200px ;font-family:Arial;font-size:16px;z-index:23" name="email" value="">
<div id="bv_Text23" style="position:absolute;left:10px;top:363px;width:240px; height:16px;z-index:24;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">Best Time to Contact?</font></div>
<select name="Combobox2" size="1" id="Combobox2" style="position:absolute;left:260px;top:363px;width:172px ;font-family:Arial;font-size:16px;z-index:25">
<option></option>
<option>Mornings</option>
<option>Afternoons</option>
<option>Evenings</option>
</select>
<div id="bv_Text24" style="position:absolute;left:10px;top:392px;width:240px; height:16px;z-index:26;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">Application Type:</font></div>
<select name="Application Type:" size="1" id="Combobox3" style="position:absolute;left:260px;top:392px;width:172px ;font-family:Arial;font-size:16px;z-index:27">
<option></option>
<option>Single</option>
<option>Joint</option>
</select>
<div id="bv_Text25" style="position:absolute;left:10px;top:421px;width:240px; height:16px;z-index:28;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">App 2 Name:</font></div>
<input type="text" id="Editbox12" style="position:absolute;left:260px;top:421px;width:200px ;font-family:Arial;font-size:16px;z-index:29" name="App 2 Name:" value="">
<div id="bv_Text26" style="position:absolute;left:10px;top:450px;width:240px; height:16px;z-index:30;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">App 2 Surname:</font></div>
<input type="text" id="Editbox13" style="position:absolute;left:260px;top:450px;width:200px ;font-family:Arial;font-size:16px;z-index:31" name="App 2 Surname:" value="">
<div id="bv_Text27" style="position:absolute;left:10px;top:479px;width:240px; height:16px;z-index:32;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">Date of Birth:</font></div>
<input type="text" id="Editbox14" style="position:absolute;left:260px;top:479px;width:200px ;font-family:Arial;font-size:16px;z-index:33" name="Date of Birth:" value="">
<div id="bv_Text28" style="position:absolute;left:10px;top:508px;width:240px; height:16px;z-index:34;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">Insurance Type Required</font></div>
<select name="Combobox4" size="1" id="Combobox4" style="position:absolute;left:260px;top:508px;width:319px ;font-family:Arial;font-size:16px;z-index:35">
<option></option>
<option>Buildings and Contents</option>
<option>Bill Protector</option>
<option>Life & Critical illness insurance</option>
<option>General Business Insurance</option>
<option>Shareholder Insurance</option>
</select>
<div id="bv_Text29" style="position:absolute;left:10px;top:537px;width:240px; height:16px;z-index:36;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">Policy Renewal Date:</font></div>
<input type="text" id="Editbox15" style="position:absolute;left:260px;top:537px;width:200px ;font-family:Arial;font-size:16px;z-index:37" name="Policy Renewal Date" value="">
<div id="bv_Text30" style="position:absolute;left:10px;top:566px;width:240px; height:16px;z-index:38;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">Current Provider:</font></div>
<input type="text" id="Editbox16" style="position:absolute;left:260px;top:566px;width:200px ;font-family:Arial;font-size:16px;z-index:39" name="Current Provider:" value="">
<div id="bv_Text31" style="position:absolute;left:10px;top:595px;width:240px; height:16px;z-index:40;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">Current Policy Cost:</font></div>
<input type="text" id="Editbox17" style="position:absolute;left:260px;top:595px;width:200px ;font-family:Arial;font-size:16px;z-index:41" name="Current Policy Cost" value="">
<div id="bv_Text32" style="position:absolute;left:10px;top:624px;width:240px; height:16px;z-index:42;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">Current Buildings Cover ('s)</font></div>
<input type="text" id="Editbox18" style="position:absolute;left:260px;top:624px;width:200px ;font-family:Arial;font-size:16px;z-index:43" name="Current Buildings Cover ('s)" value="">
<div id="bv_Text33" style="position:absolute;left:10px;top:653px;width:240px; height:16px;z-index:44;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">Current Contents Cover ('s)</font></div>
<input type="text" id="Editbox19" style="position:absolute;left:260px;top:653px;width:200px ;font-family:Arial;font-size:16px;z-index:45" name="Current Contents Cover ('s)" value="">
<div id="bv_Text34" style="position:absolute;left:10px;top:682px;width:240px; height:16px;z-index:46;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">Buildings Cover Required</font></div>
<select name="Buildings Cover Required" size="1" id="Combobox5" style="position:absolute;left:260px;top:682px;width:64px; font-family:Arial;font-size:16px;z-index:47">
<option></option>
<option>Yes</option>
<option>No</option>
</select>
<div id="bv_Text35" style="position:absolute;left:10px;top:711px;width:240px; height:16px;z-index:48;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">Contents Cover Required:</font></div>
<select name="Contents Cover Required" size="1" id="Combobox6" style="position:absolute;left:260px;top:711px;width:65px; font-family:Arial;font-size:16px;z-index:49">
<option></option>
<option>Yes</option>
<option>No</option>
</select>
<div id="bv_Text36" style="position:absolute;left:10px;top:740px;width:240px; height:16px;z-index:50;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">Accidental Damaged Required:</font></div>
<select name="Accidental Damage Required" size="1" id="Combobox7" style="position:absolute;left:260px;top:740px;width:65px; font-family:Arial;font-size:16px;z-index:51">
<option></option>
<option>Yes</option>
<option>No</option>
</select>
<div id="bv_Text37" style="position:absolute;left:10px;top:769px;width:240px; height:16px;z-index:52;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">Personal Possesion Cover</font></div>
<select name="Personal Possession Cover" size="1" id="Combobox8" style="position:absolute;left:260px;top:769px;width:64px; font-family:Arial;font-size:16px;z-index:53">
<option></option>
<option>Yes</option>
<option>No</option>
</select>
<div id="bv_Text38" style="position:absolute;left:10px;top:798px;width:240px; height:16px;z-index:54;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">Persoanl Possesion Cover Required ('s)</font></div>
<input type="text" id="Editbox20" style="position:absolute;left:260px;top:798px;width:200px ;font-family:Arial;font-size:16px;z-index:55" name="Persoanl Possesion Cover Required ('s)" value="">
<div id="bv_Text39" style="position:absolute;left:10px;top:827px;width:240px; height:16px;z-index:56;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">Life Cover Required ('s)</font></div>
<input type="text" id="Editbox21" style="position:absolute;left:260px;top:827px;width:200px ;font-family:Arial;font-size:16px;z-index:57" name="Life Cover Required" value="">
<div id="bv_Text40" style="position:absolute;left:10px;top:856px;width:240px; height:16px;z-index:58;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">Critical Illness Cover Required ('s)</font></div>
<input type="text" id="Editbox22" style="position:absolute;left:260px;top:856px;width:200px ;font-family:Arial;font-size:16px;z-index:59" name="Editbox22" value="">
<div id="bv_Text41" style="position:absolute;left:10px;top:885px;width:240px; height:16px;z-index:60;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">Term for Life/Critical Cover (Yrs)</font></div>
<input type="text" id="Editbox23" style="position:absolute;left:260px;top:885px;width:200px ;font-family:Arial;font-size:16px;z-index:61" name="Editbox23" value="">
<div id="bv_Text42" style="position:absolute;left:10px;top:914px;width:240px; height:16px;z-index:62;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">App 1 Smoker?</font></div>
<select name="App 1 Smoker" size="1" id="Combobox9" style="position:absolute;left:260px;top:914px;width:65px; font-family:Arial;font-size:16px;z-index:63">
<option></option>
<option>Yes</option>
<option>No</option>
</select>
<div id="bv_Text43" style="position:absolute;left:10px;top:943px;width:240px; height:16px;z-index:64;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">App 2 Smoker?</font></div>
<select name="App 2 Smoker?" size="1" id="Combobox10" style="position:absolute;left:260px;top:943px;width:66px; font-family:Arial;font-size:16px;z-index:65">
<option></option>
<option>Yes</option>
<option>No</option>
</select>
<div id="bv_Text44" style="position:absolute;left:10px;top:972px;width:240px; height:16px;z-index:66;" align="left">
<font style="font-size:13px" color="#000000" face="Arial">Additional Info</font></div>
<textarea name="TextArea1" id="TextArea1" style="position:absolute;left:108px;top:972px;width:493px ;height:100px;font-family:Arial;font-size:16px;z-index:67" rows="4" cols="65"></textarea>
<input type="reset" id="Button1" name="Button1" value="Reset" style="position:absolute;left:260px;top:1077px;width:96px ;height:25px;font-family:Arial;font-size:13px;z-index:68">
<input type="submit" id="Button2" name="Button2" value="Send" style="position:absolute;left:260px;top:1107px;width:96px ;height:25px;font-family:Arial;font-size:13px;z-index:69">
</form>
</div>
</body>
</html>

navaldesign
08-27-2010, 04:08 PM
To RNA:

Your page works perfectly on my server: http://www.dbtechnosystems.com/BVFORMS/login_plus_form.php

You must also have something else in your page (which is NOT in the above code).

Please also note that the form, as is set, will do nothing, as it submits to the page itself, but no processor exists in the page to process the form submission.

navaldesign
08-27-2010, 04:11 PM
To meetmec12: who are you ? what's your website ?

If you want help, please provide your details.

meetmec12
08-29-2010, 08:47 AM
I'M NEW HERE ABOUT TO SIGN UP.i DON'T HAVE VODAHOST ACCOUNT YET.I WANT TO KNOW IF WHAT I WANT(WRITTEN ABOVE) IS POSSIBLE WITH BV& VH..THANK YOU SIR.

navaldesign
08-29-2010, 09:04 AM
Ther are two ways of doing this:

1. Automatically: the user signs up by filling in a form with his details, then he clicks on a Buy Now button, he is redirected to PayPal, and after payment his membership is automatically activated and he can access the form page. This will require a custom made script in PHP/MySQL

2. Semi - automatically: use the BV Login tools to allow users to signup. After they signup, they click on a PayPal Buy Now button to proceed to Payment. When you receive the payment notification from PayPal, you manually activate the account so they have access to the form page. You only need to use a PayPal button with a field to allow user to include his name so you know who he is, when you receive the payment.

meetmec12
08-29-2010, 07:18 PM
You are the greatest.Thanks but what i need is different from that!i WANT MEMBERS TO SIGN IN WITHOUT SIGNING UP.Just like a page password protect but multiple passwords and username just like html password lock.I have been thinking about signing up many account with my own password and user name .Then i'll give out the passwords to my members but opening 1000 email adrs is crazy.I know they can sign up themselves but that won't serve the purpose .My own password and username is what i want to sell to them so i have to create it.(html lock didn't work wiyh BV.Sorry 4 my trouble@Naval d

RNA
08-30-2010, 02:28 PM
Thank Navaldesign but I'm getting confused how can it work on your server but not mine, and how do I find whats causing the problem on the page if its not in the code?

The page is for sales people working from home to send me information from the form via email to me. So just need a simple page lock to keep junk emails coming from the site.

RNA
08-30-2010, 05:03 PM
I've tried rebuilding the page from scratch and am still having problems, it seem as if password icon code has problems when you are protecting a page with a form on it. Is there anyway we can get the people at bluevoda to have a look at this problem?

When you have a form on the page for some reason the protect form tries to take you to the success page targeted by the form on the page. So it never allows you on the the page itself. It will either take you the the success page or if you set the success page as the page you want it will ask for the password again as soon as you enter it and creating a loop of asking you to log on. Very frustrating!

Any suggestions

navaldesign
09-27-2010, 08:58 PM
The same issue = ??

If you have a form, you need to remove it, or make first a login page and then redirect to the protected page with the form.