SunQuest
 
      Delphi
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Tutorialized ForumsDesktop ProgrammingDelphi

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Tutorialized Forums Sponsor:
Stay one step ahead of the competition. Evaluate and give feedback on some of the hottest web development tools on the market today. Make your opinion heard! Click Here
  #1  
Old August 5th, 2005, 11:05 AM
peterhoward peterhoward is offline
Junior Member
Tutorialized Newbie (0 - 499 posts)
 
Join Date: Aug 2005
Posts: 1 peterhoward New User: is a brand new recruit and a unknown entity at this point. 
Time spent in forums: < 1 sec
Reputation Power: 0
Send a message via MSN to peterhoward
Can anyone give me a helping hand??

hi i created a testing website where i made a login page and register page i'd enter a new user details and when i click register it comes up with an error /register? no info gets put into the database

i was wondering if anyone could help me make a login page, a register page that will work

or tell me where i'm going wrong

Thanks in advance

Pete

Reply With Quote
  #2  
Old August 10th, 2005, 03:42 PM
jetblacknewyear jetblacknewyear is offline
Member
Tutorialized Newbie (0 - 499 posts)
 
Join Date: Aug 2005
Posts: 36 jetblacknewyear New User: is a brand new recruit and a unknown entity at this point. 
Time spent in forums: < 1 sec
Reputation Power: 0
i'll show you what i've done for mine

Code:
if (isset($login)) 
{
  if(ereg('[^a-zA-Z0-9_]{1,}', $username))
  {
    $no1 = "username contains invalid letters
";
  } 

  if(ereg('[^a-zA-Z0-9_]{1,}', $password))
  {
    $no2 = "password contains invalid letters
";
  } 
  if ((!$no1) and (!$no2))
  {
    $results = @mysql_num_rows(@mysql_query("SELECT * FROM users WHERE password='$password' AND username='$username'"));
    if($results == 1) 
    {
      //person entered the right info
    } 
    else 
    {
      echo "username/password pair not found";
    }
  } 
  else 
  {
    echo $no1;
    echo $no2;
  }
}


hopefully that all works. if it doesn't, just post again

Reply With Quote
Reply

Viewing: Tutorialized ForumsDesktop ProgrammingDelphi > Can anyone give me a helping hand??


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 3 hosted by Hostway