...

View Full Version : Signup



Fashong
06-15-2005, 09:19 PM
I know it isn't finished but I will finish I was testing something and it didn't work. I probally made a stupid mistake so it would be great if someone could help me.. ~Thanks



<?php
$title = "Signup";
include("top.php");
?>


<div id="content">
<span>Signup</span>


<p>
<form method="POST" action="signup.php?action=signup">
Username:<br> <input type="text" name="username" size="20" maxlength="15"><br>
Password:<br> <input type="password" name="password" size="20" maxlength="15"><br>
Verify Password:<br> <input type="password" name="verpassword" size="20" maxlength="15"><br>
Email:<br> <input type="text" name="email" size="20" maxlength="15"><br><br>


Note: Your ip will be logged so please do not make multiple accounts<br><br>
<input type="submit" name="action" value="Signup"></form>



<?php
IF ($action == "submit"){
echo $username;
echo $password;
echo $email;
}
?>


</div>

<?php
// signup stuff here
?>


<?php
include("bottom.php");
?>

Fashong
06-15-2005, 10:05 PM
I might need $username = $_POST['usermame']; but it worked the other way before.....

Fashong
06-16-2005, 12:13 PM
Any help??

SeeIT Solutions
06-16-2005, 12:32 PM
Try this...


<?php
$title = "Signup";
include("top.php");
?>


<div id="content">
<span>Signup</span>


<p>
<form method="POST" action="signup.php">
Username:<br> <input type="text" name="username" size="20" maxlength="15"><br>
Password:<br> <input type="password" name="password" size="20" maxlength="15"><br>
Verify Password:<br> <input type="password" name="verpassword" size="20" maxlength="15"><br>
Email:<br> <input type="text" name="email" size="20" maxlength="15"><br><br>
Note: Your ip will be logged so please do not make multiple accounts<br><br>
<input type="submit" name="submit" value="Signup"></form>

<?php
if (isset($_POST['submit']){
echo $_POST['username'];
echo $_POST['password'];
echo $_POST['email'];
}
?>

</div>

<?php
// signup stuff here
?>


<?php
include("bottom.php");
?>

Fashong
06-16-2005, 12:34 PM
Alright, I thought so. Anyway my way would work to IF ($action == "submit") {
stuff here
}

I always thought this way was better...

Fashong
06-16-2005, 12:42 PM
You know what I didn't do right lol.. IF ($action == 'Signup'){

SeeIT Solutions
06-16-2005, 01:24 PM
Your way would only work with global variables on, the default is off so it is better to do it the way I showed you.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum