In order for registration to be completed you must specify a username."; error($head, $message, $back, $backtext); } //check to make sure there isn't already a user with the same username in the DB $namequery = mysql_query("select count(*) from regenduser where uname = '$username'"); if (!$namequery) { dohead($head); $message = "Unable to upload your details.
TheGlasgowStory has encountered a database error."; error($head, $message, $back, $backtext); } //transforms result into an int $namequery = mysql_result($namequery, 0, 0); //if result is 1 then that user name already exists if ($namequery !=0) { dohead($head); $message = "The username ".$username." has already been chosen by someone else."; error($head, $message, $back, $backtext); } if (empty($fname)) { dohead($head); $message = "You did not enter a forename.
In order for registration to be completed you must supply your forename."; error($head, $message, $back, $backtext); } if (empty($sname)) { dohead($head); $message = "You did not enter a surname.
In order for registration to be completed you must supply your surname."; error($head, $message, $back, $backtext); } if (empty($pword1)) { dohead($head); $message = "You did not enter a password.
If the problem persists e-mail webmaster@theglasgowstory.com quoting error code TGSEU026."; error($head, $message, $back, $backtext); } if (empty($pword2)) { dohead($head); $message = "You did not enter the password twice.
If the problem persists e-mail webmaster@theglasgowstory.com quoting error code TGSEU027."; error($head, $message, $back, $backtext); } //checks to make sure both passwords are the same if ($pword1 != $pword2) { dohead($head); $message = "The two passwords you entererd were not the same.
If the problem persists e-mail webmaster@theglasgowstory.com quoting error code TGSEU028."; error($head, $message, $back, $backtext); } //checks to make sure password is the correct length if (strlen($pword1) >10 || strlen($pword1) <4) { dohead($head); $message = "Your password must be between 4 and 10 characters long.
If the problem persists e-mail webmaster@theglasgowstory.com quoting error code TGSEU029."; error($head, $message, $back, $backtext); } if (empty($email)) { dohead($head); $message = "You did not enter an e-mail address.
In order for registration to be completed you must supply an e-mail address."; error($head, $message, $back, $backtext); } if (!eregi("^[a-zA-Z0-9_\.\-]+@[a-zA-Z0-9_\-]+\.[a-zA-Z0-9\-\.]+$", $email)) { dohead($head); $message = $email." does not appear to be a valid e-mail address.
If the problem persists e-mail webmaster@theglasgowstory.com quoting error code TGSEU029."; error($head, $message, $back, $backtext); } //get the time of registration $date = date(U); //encrypt password $pword1 = crypt($pword1, 'xx'); /***************************************** * Query to upload user details to the DB * *****************************************/ $upload = mysql_query("insert into regenduser set uname = '$username', pword = '$pword1', fname = '$fname', sname = '$sname', email = '$email', createdate = '$date', active = 'Y'"); if (!$upload) { dohead($head); $message = "Unable to upload your details.
If the problem persists e-mail webmaster@theglasgowstory.com quoting error code TGSEU030."; error($head, $message, $back, $backtext); } /************************ * Log user registration * ************************/ $date = date(U); $log = mysql_query("insert into accesslog set ip = '$userip', uname = '$user', logdate = '$date', actiontype = 'Registration', details = 'Username = $username'"); /***************************** * Mail the user if requested * *****************************/ if ($send == 1 && !empty($email)) { $to = $email; $sub = "TheGlasgowStory registration"; $message = "Dear ".stripslashes($fname).". \n\nYou have been successfully registered with TheGlasgowStory. \nYour user name is '".$username."' and your password is '".$pword2."'. \n\nYou can now log on to www.theglasgowstory.com \n\nIf you think you have been sent this e-mail by mistake or have any questions about your user account you can e-mail TheGlasgowStory at: webmaster@theglasgowstory.com"; $worked = mail($to, $sub, $message, "From: webmaster@theglasgowstory.com\r\n"); if (!$worked) echo("Mail error"); } } if ($accept == 99 && $register !=99) { /********************************************* * Code to run if register button not pressed * *********************************************/ session_register("accept"); $link = urldecode($link); $link = urlencode($link); } format_pre("N", "TheGlasgowStory Registration", $feature, $_COOKIE); ?>

Registration

Please read the Terms and Conditions for registration and click the 'Accept' button to continue.

"); ?>

Terms and Conditions

You have been successfully registered with TheGlasgowStory!

Log on to TheGlasgowStory by entering your username and password in the boxes on the right hand side of any page on the website.
Once you have logged on you can save the contents of your photo album and reload them each time you log on to TheGlasgowStory.

How to save a photo album
Once you have logged on click on the 'view photo album' link found on the right hand side of every page. If you have any images in your album the option to save your album will appear at the bottom of the page.

How to view your saved albums
Once you have logged on a link to 'view your saved photo albums' will appear on the right hand side of every page. Click on this to open a page listing your saved albums. You can also delete your saved albums from this page.

Register with TheGlasgowStory and you can save up to five photo albums. Saved photo albums can be reloaded whenever you visit the site allowing you to access your favourite images at the click of a button.

Registration is completely free of charge. All you need to do is fill in the form below and press the 'Register' button. Once you have registered you can log on to TheGlasgowStory by entering your username and password in the boxes located on the right hand side of every page.

TheGlasgowStory will not send you any unsolicited e-mails or make your details known to any other organisation or company. Read our privacy statement for further information (opens in a new window).

How to fill in the form
Username: This is the name you will enter when logging on. Your username has to be unique - if you choose a username that someone else has already chosen you will be asked to choose another.
Password: The password you will enter when logging on. Your password needs to be between 4 and 10 characters long and isn't case sensitive.
Password again: Enter your password again to confirm it.
 

  Would you like TheGlasgowStory to send you an e-mail confirming your registration?
1. Username (maximum of 20 characters long)
2. Forename
3. Surname
4. Password
5. Password (again)
6. E-Mail