Jump to content

shank888

Members
  • Posts

    119
  • Joined

  • Last visited

Everything posted by shank888

  1. Hey all. For sum reason when I try to acess my register script my server comes up saying service is unavalible. I know my server works for other pages and I am thinking it is the script that is causing this problem. Here is the script below. As well does anyone have any security pointers for me? <?php ini_set ('display_errors', 1); error_reporting (E_ALL & ~E_NOTICE); if (isset ($_POST['submit'])) { $problem = FALSE; // no problems so far if (empty ($_POST['username'])) { $problem = TRUE; print "<p>Please enter a username.</p>"; } if (empty ($_POST['password'])) { $problem = TRUE; print "<p>Please enter a password</p>"; } if ($_POST['password'] != $_POST['cpassword']) { $problem = TRUE; print "<p>Your Passwords did not match.</p>"; } if (!problem) { // If no problems occured print "<p>You have now been registered!</p>"; } function validateEmail($email) { if (eregi("(@.*@)|(\.\.)|(@\.)|(\.@)|(^\.)", $email) || !eregi ("^.+\@(\[?)[-_a-zA-Z0-9\.]+\.([a-zA-Z] {2,3}|[0-9]{1,3})(\]?)$", $email)) { return 1; } else { list($user, $domain) = explode(`@`, $email); if ((!eregi("^[_a-zA-Z0-9\.\-]+$", $user)) || (!eregi("^[_a-zA-Z0-9\.\-]+$", $domain))) { return 1; } else { return 0; } } } if (validateEmail($email) == 1 || validateEmail($email) ==0) { print " E-mail is not in correct format"; } } // Displaying HTML form below print " <form action='register.php' method='post'> Username: <input type='text' name='username' size='20' /> <br /> E-mail: <input type='text' name='email' size='20' /> <br /> Password: <input type='password' name='password' size='20' /> <br /> Confirm Password: <input type='password' name='cpassword' size='20' /> <br /> <input type='submit' name='submit' value='register' /> </form> "; ?>
  2. okay I will be looking more into this, seems like its a .htacess kinda thing which i need to learn. anyways can be marked as solved i guess or just deleted
  3. hmm where can i get mor einfo on mod_rewrite?
  4. For sumreason it refuses to do wha ti want it to do and that is create a new directory in the subdomain. <?php ini_set ('display_errors', 1); error_reporting (E_ALL & ~E_NOTICE); if (isset ($_POST['submit'])) { $problem = FALSE; // no problems so far if (empty ($_POST['username'])) { $problem = TRUE; print "<p>Please enter a username.</p>"; } if (empty ($_POST['password'])) { $problem = TRUE; print "<p>Please enter a password</p>"; } if ($_POST['password'] != $_POST['cpassword']) { $problem = TRUE; print "<p>Your Passwords did not match.</p>"; } if (!problem) { // If no problems occured mkdir("../users.domain.com/$username"); // this should create a new folder for the user in the users.babble-net.com subdomain //print register message print "<p>You have now been registered!</p>"; } else { print "<p>You could not be registed due to an internal system error.</p>"; } } // Displaying HTML form below print " <form action='register.php' method='post'> Username: <input type='text' name='username' size='20' /> <br /> Password: <input type='password' name='password' size='20' /> <br /> Confirm Password: <input type='password' name='cpassword' size='20' /> <br /> <input type='submit' name='submit' value='register' /> </form> "; ?>
  5. Okay now that we are arguing about CSS, does sumone wanna help me how to fix it?
  6. lol my site got the shit kicked outta it. but... I was aware I had tons and tons of security errors and didn't fix them. I guess we learnt our lesson
  7. Hey, I am trying to brign the Welcome table to have a border on the left side of 10px, and make it strecth all the way to the login to within 10 px. as well I want the bottom blue bar to have a spacing of 10 on the top of it. How do I do this? http://beta.babble-net.com/ I know this is quite an easy task, but I can get it working for firefox although not uplaoded ont eh server yet, but for IE and Opera it does not seem to want to work.
  8. I would like to see what you've got. prehaps we can reach an agreement.
  9. Hey, I am trying to brign the Welcome table to have a border on the left side of 10px, and make it strecth all the way to the login to within 10 px. as well I want the bottom blue bar to have a spacing of 10 on the top of it. How do I do this? http://beta.babble-net.com/
  10. first 5 letters of my last name.
  11. the banner. what dont you like? anything in particular or just blah?
  12. Hey all, I am designing an online community / social networking platform. I am asking ya'll to critique my site mainly for ease of use, spelling erros. However design input will muchly be appreciated. Please if you think it sux tell me why it very fusterating to see ppl jsu tbe like it sucks and dont give any input on how I can improve etc. lol anyways... http://www.babble-net.com as well I am trying to design my user profile a link to it can be seen here: http://img112.imageshack.us/img112/9485/babblenetusersprofilev1eu1.jpg any inputs for features to make the ultimate platform please contribute as well. thank you all.
  13. Normally I do. Haha, but like i said I'm 90% sure it wont work. thank you tho. another easier way to look at things
  14. Hmm makes sences lol || means or && means and
  15. Okay well my keyboard is acting up aagin so I am not sure if this script works. infact I am 90% sure it wont missing some quotes and stuff. But I think you may try somethign like: <?php //filename is test.php in this case and we are doing the full script on one page echo "<html> <head></head> <body> <form action='test.php' method='post'> <select name='gender'> <option value=' ' selected='$_POST['gender']'> $_POST['gender']</option> <option value='1'>Female</option> <option value='2'>Male</option> </select> <input type='submit' value='Submit'> <input type='reset' value='Reset'> </form>"; if (isset($_POST['submit'])) { $female = 1; $male = 2; if ($_POST['gender'] != $female || $_POST['gender'] != $male) { ยจ echo "please enter a gender"; } else { echo "echo or whatever you wanna do here"; } } ?> </body> </html>
  16. what is there to check if you can't submit the code. I assume that is the only code you have?
  17. Looks nice for sure. I can register as a blank user and password.
  18. Lol okay haha I dunno what I am doing. But i use if (isset ($_POST['submit'] { for my form action. then i can make it return me back to my form. and then once it returns me the form data will be filled out like it was left. print 'Username: <input type='text' name='username' size='20' value="' .$_POST[username']. '" />': edit: Okay I quit. I am wayy off topic
  19. i go <form> User: <input type='text name='user' value='$_POST['user]' /> </form> or sumfin like that i cant remember
  20. I agree with this. And for the other guy I went to those exact sites. I know what they are. I dont understand what the sites are saying So i came here. If you're soo brilliant maybe you can explain it?
  21. even with that I have found that this script does not work
  22. Cross Site Scripting (XSS) / SQL injection and form hijacking How do we stop it? Any advice, how to's or codes would be muchly appreciate. Thank You All
  23. I dunno much about PHP, as well I am just learning. However if($session->logged_in){ if($form->num_errors > 0){ those dont look quite right. and I dont understand why I can see your PHP source code. seeing as it should be serverside. to make your code look a bit cleaner for the HTML and ONLY html i use ' instead of \" i dont see num_errors. get a value set to it anywhere. -> do you mean => ?
  24. I find the saturation too high.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.