Register system

Hi, i want to know the best way to make a register system, that’s will be very hard to hack, and what i will need, some books for help me, some sites, any way to helpme, and some kinds of tricks of how to use others way to find you friends, like, if two members, friends on facebook, register on my site, they will get a notice that the friends has make the new account, or the new when create the account find every person in the moment that he create(like on facebook) or both… thanks

Hello, and welcome to SitePoint, Felipi!

You will need to give us some more information before we can help you out. What’s the plan, in greater detail?

As in; what application are you writing? What programming language are you using? Any specific frameworks or libraries? You get my point. :slight_smile:

I wanna make a web site, with a register system, using html5 and css for design (or if you have a better way you could tell)
i want to make a game that i can run on desktops and portables like tablets, ds and psp… by log-in my site and the game part of it to find others players
and then run the game that must be downloaded for avoid to re-download the game every time you play…
with the typical peer-to-peer network—all computers interact with each other – and the server still connect to them but just for check if the actions are true,(avoid hackers)
like, its not possible that person gives more than 40dmg, the web server must download all the variables and check if they are true… and if they = false; make the user disconect
some apis that don’t need lot of graphics like an calculator, with different types of problems like find the delta in a mathematic operation… by inserting the 3 variables…
i secure way for only i have access modify/view the files(crypto-graphed files) like and admin user in the(sql) for avoid massive hacks by opening the data
Make a friend list/chat system/ and video-conference system…
Enable your web pages to communicate with a web server without a page reload. so i don’t need refresh all the html5 and css just the content that need to be changed to avoid upload unnecessary data…
Create JavaScript events that react to visitor actions…
Create content that i can drag with mouse like the same calculator that i mention before, imagine a object with a canvas size with width:300; and height:300; that you can drag in your page(of course i could change the size)
Options to share youtube videos sound cloud musics, and same(video/audio files) from others sites

A page that like face book load friend posts…

I think i will need use JavaScript & Jquery for the site interactivity, and visual effects…(for keep the site running and growing automatically, like options for create posts the selected areas)
Html5 and CSS, for basic graphics like site structure… a easy system to
Java or C/c++/c# for make the game
PhP or JavaScript and Mysql or any other database system (for keep the site running and growing automatically, store the new files, like posts and photos)

Im just making research in every away to make it, i don’t care if its the hardest to make, i just want to make sure that it run in the maximum of consoles at the same time (like i mentioned before, im aiming for portables nintendo ds psp, ipad, android, and desktop) i think they all run java files if you put the jre so i think java can be a nice pick, mixed with JS Jquery or even php

Honestly, if your struggling to know how to create a registration system, from what you have said, you might be trying to run before you can walk.

Anyway…

Firstly, the HTML5, CSS3, jQuery stuff; thats all cosmetic really; its the under the hood PHP stuff you need to figure out and understand first, you can overlay the cool UI stuff on top of it later.

What you need to do is first consider your registration flow, typically most registration systems will do something like this:

  1. Registration Screen with CAPTCHA where user enters their account details
    Nice jQuery things to add would be things like, checking the email address, password and username on entry, making sure the username and email are valid and available (i.e. not already in use) and that the password is valid. You may also have stuff like date of birth that validates the minimum age. These features are added ON TOP as UI features and are not relied upon for validation.

You also want a CAPTCHA to help verify that the user isnt a bot.

  1. When they submit, you collect the form variables and validate them. That jQuery stuff I mentioned before is just UI polish, you don’t rely on it; thats not your validation, this point is. If all the data entered is valid, you create the account BUT you want a flag in the user database on whether the user is active or pending verification. At this point dispatch an email to the users email address with a verification link, this link has a unique code attached to it along with some kind of user reference.

  2. The user clicks the link which goes to a script that verifies the user reference and the unique code (a hash key), if valid then set the account from pending to active.

Then your login screen, accept the username and password, if the account is active allow login, else do not.

Thats a simple reg system, the HTML5 and jQuery stuff is just cosmetics you can add on later.

It’s the same with your features, I wouldn’t recommend making a site where its all javascript, you use javascript as an overlay for nice UI features, not as the UI itself.

actually i’m trying to build the registration system from php already have the mysql and myphpadmin running, i will need make later some security system but still running…
the email i pretend verify if its true by sending a mail with a captcha in jpeg for they can’t just copy and past the code in a bot…
this is the list
User: (6-18 characters)
Email: (10~32characters)
Facebook: (10~32characters)(the facebook email)
Twitter: (10~32characters)(the twitter email)
Password: (6-18 characters)
Name: (6-32 characters)
Sex&Birthday: <input type=hidden name=todo value=submit>
<table border=“0” cellspacing=“0” >
<tr><td>

this is my mysql and php versions,
Apache/2.2.21 (Win32) mod_ssl/2.2.21 OpenSSL/1.0.0e PHP/5.3.8 mod_perl/2.0.4 Perl/v5.10.1
Versão do cliente MySQL: mysqlnd 5.0.8-dev - 20102224 - $Revision: 310735 $
Extensão do PHP: mysql

so with my html5 and css3 i do the design, and php makes my site run automaticly by checking if the email is true to register… and then they keep the file of the user in other paste separatly and keeps running in he and he log in…

Making the javascripts apart you know and using just for aplications, by the way i bought a javascript from sitepoint and now only left i learn to use

what im trying to ask is how many books and the names of them for make this in the most actual system so if could point me the direction thanks, the games will be simples like a mario for supernintendo and thinks like it with little improvement in the graphics, so what books i will need? they will have a cd with the source?? i wanna from the start to the very end, how to make a site with register that i can use my and put online, you know web intersect?? is some site like that with more interactivity so if you could point the books for i make it all thank you, i just don’t want start to buy books and get stuck somewhere and just need to learn another tecnology from the begin just for learn it

so there is no one that could help me with that? point all the books i need? =( sorry for the re post but have passed 12 days and no one gives a answer that could point a direction for me, if no one on this site really could help me please lock down thx post, and sorry for that, but i’m feeling really disappointed that no one can even point anything to start…

the game make was the first thing i ever studied in programming and it was 7 years ago when i was 12, i make something like a supermario (super-nintendo) in c++ and a mugen, from 0 both, some calculators, things like that for training before… but i stopped to programming and trying to get back to this pratice… learned a bit of java too

thanks for the answers both of you Fizix trying to figure out how to do i’m already what is hard to find is a nice book or a tutorial anything that can help me to make and understand, that is wasting some time just doin lots research in web trying to find any code, any hint, tutorial or anything that can help me =/
here in brazil in your stores the books are overdated and it’s is really really bad when talking about programming i’m trying this to check if user login is correct but its where i’m suck at the moment :

i tried so far 3 ways to do it but no one work

function login_check($uemail, $upassword) {
$uemail = mysql_real_escape_string($uemail);
$login_query = mysql_query(“SELECT COUNT(user_id) AS count , FROM userz WHERE uemail=‘$uemail’ AND upassword='”.md5($upassword).“'”) or die(mysql_error());
return (mysql_result($login_query, 0) == 1) ? mysql_result($login_query, 0, ‘user_id’) : false;
}

but keeps saying, unable to connect to user, and if i take of this option this simples doesn’t echo the user_id, i think the problem is to get the correct info in db and than compare with the input, (i think it is what the function login_check does)
and this

function login_check($email, $password) {
$email = mysql_real_escape_string($email);
$login_query = mysql_query(“SELECT(user_id)FROM userz WHERE email=‘$email’AND password=’”.md5($password).“'”);
return (mysql_result($login_query, 0) == 1) ? mysql_result($login_query, 0, ‘user_id’): false;
}
error:
Warning: mysql_result() [function.mysql-result]: Unable to jump to row 0 on MySQL result index 11 in C:\xampp\htdocs\myarchives\myweb\func\user.func.php on line 14

in my login.php(here come it full)
<form action=“” method=“post” align=“right” >
<p>
Email: <input type=“email” name=“login_uemail” />
Password: <input type=“password” name=“login_upassword” />
<input type=“submit” value=“Log in” />
</p>

</form>
<?php
if(isset($_POST[‘login_uemail’],$_POST[‘login_upassword’])) {

    $login_uemail = $_POST['login_uemail'];
    $login_upassword = $_POST['login_upassword'];
    
    
 $errors = array();

if(empty($login_uemail) || empty($login_upassword)){
$errors = ‘Email and password are required!’;
} else {

$login = login_check($login_uemail, $login_upassword);
echo $login;

if($login === false){
$errors = ‘Unable to log you in’;
}

}if (!empty($errors)){
foreach($errors as $error){
echo $error, ‘<br />’;
}
}
}
?>

If you want me to write and comment a simple login system for you, drop me a PM. It’ll be simple though, just a “template” as it were, that you can learn from.

the register is already done, and now left the login, i have already send the message for you and really thanks for the attention…

so he didn’t sent to me the template or anything, and passed 6 days from last post and since the begin of the post no one really helped me =/
sorry for the double post again… but now let’s make it a little easy…

Anyone here know a book, (or two or three or more…) that will instruct the path of how to create a complete website…
lets just forget the other post and i will make a just a little simplest…
I want to build a site that users can register, people can use my appis, simple ones, like a calculator… or anything that i could make with javascript or pure java or c#/c++/c…
and i can design exactly how the pages looks(with html5 and css3… the site appearance)(i already done this, and put in php, so i just need change 4 to 10 files to change all the site visual no matter how much pages it have)
this include, how build everything from zero, the wanted part is just the php(or another language that you could suggest),
so the most important thing is the register and login system, private message system, and a group message system… newsletter by email, captcha for email authentication
and a way that would be easy to share musics and videos, if i gonna do that only for me i would pick the embbed and just post, but a lot of people don’t want to have that “work”, so if you know a easy way to share thanks…
a safe system for upload images… that’s all i really need and i’m trying do develop, so if you could point a book or anything that i can use to help me please do it… and thank you

hey dude if no one can help me please you can just close the topic… and i will not keep waiting for it, but since passed so much days i think no one here can help…
just a fast question…

how could a site that sell books for programming don’t have one single person that could make a simply register system? anyone could explain this??? things just don’t look clear right now, don’t exist one book from you guys that explain it??? =/

I pm’d you asking for an email address to send a barebones example from my framework to.

ya realy thanks for that dude…

but hey sitepoint team, i find one book that sounds interesting of you guys…
Build your own ASP.NET 4 Website using C# & Visual Basics…
considering i already domain the html5 and css3, this book would help me to build a site with register system, and some more utility’s? what books would be a nice complement? a php? a java script? give me some light i wanna buy your books, but first i want know the best books and what i can do in the end with them all =] if some one could make this clear to me… and it will come with some source codes in extra cd or downloadable?
whats the advantage to buy with you guys?

and again thank you fizix for the help =]