Account

1000){ // $uid < 0 is a Y_prospect // $uid < 0 is a Y_customer // https://www.printmanager.com/management/ if($uid > 1000){ echo '

Edit Account '; }else{ echo '

Edit Account '; } echo ' Log Out

'; echo '

 

'; if($s=="editprospectaccount" and $uid < 0){ $error = checkprospectdetails($Eemail, $Ecompany, $Efirstname, $Elastname, $Ecity, $Ephone, "edit", $Epassword1, $Epassword2); if($error){ echo "". $error . ""; $s = "editaccount"; }else{ // All good. Save the details $prospectid = $uid * -1; $query = " UPDATE Y_prospects SET company = '$Ecompany', email = '$Eemail', "; if($Epassword1){ $query .= " password = '$Epassword1', "; } $query .= " firstname = '$Efirstname', lastname = '$Elastname', city = '$Ecity', country = '$Ecountry', phone = '$Ephone' WHERE id = '$prospectid' "; // Save the uodated prospect details $update = mysql_query($query); $s = ""; ?>
Log In Email:
First Name:
Last Name:
Company:
Phone:
City:
Country: '; echo''; echo'
Change Password: Again:
 
'; } if(!$s and $uid < 0){ echo '

Welcome '.$uname.'.

'; echo'
Log In Email: '.$uemail.'
First Name: '.$ufirstname.'
Last Name: '.$ulastname.'
Company: '.$ucompany.'
Phone: '.$uphone.'
City: '.$ucity.'
Country: '.$ucountry.'
'; } } function checkprospectdetails($email, $company, $firstname, $lastname, $city, $phone, $type, $password1="", $password2=""){ // Check values $error = ""; //// Company $company = stripslashes_mysql($company); $company = trim($company); $companyClean = $company; $companyClean = strip_tags($companyClean); $companyClean = htmlspecialchars($companyClean); if(!$companyClean or $companyClean != $company){ $error .= "

There was a problem with the company name. Please fill it in, and for security reasons please avoiding special characters.

"; } //// Email $email = stripslashes_mysql($email); $email = strtolower(trim($email)); if(eregi("^[_a-z0-9-]+(\.[_a-z0-9-]+)*@[a-z0-9-]+(\.[a-z0-9-]+)*(\.[a-z]{2,3})$", $email) and trim($email)){ // Good email // now check that it is not a duplicate if($type == "new"){ $result = mysql_query("SELECT email from Y_prospects WHERE LOWER(email) = '$email'"); if($row = mysql_fetch_array($result)){ $error .= "

That email address is already in use. Perhaps you should try to login and request your password.

"; }else{ $result = mysql_query("SELECT email from Y_customers WHERE LOWER(email) = '$email'"); if($row = mysql_fetch_array($result)){ $error .= "

That email address is already in use. Perhaps you should try to login and request your password.

"; } } } }else{ // Bad email $error .= "

There was a problem with the email address. Please check that you have entered in correctly.

"; } // First name $firstname = stripslashes_mysql($firstname); $firstname = trim($firstname); $firstnameClean = $firstname; $firstnameClean = strip_tags($firstnameClean); $firstnameClean = htmlspecialchars($firstnameClean); if(!$firstnameClean or $firstnameClean != $firstname){ $error .= "

There was a problem with your first name. Please fill it in, and for security reasons please avoiding special characters.

"; } // Last name $lastname = stripslashes_mysql($lastname); $lastname = trim($lastname); $lastnameClean = $lastname; $lastnameClean = strip_tags($lastnameClean); $lastnameClean = htmlspecialchars($lastnameClean); if(!$lastnameClean or $lastnameClean != $lastname){ $error .= "

There was a problem with your last name. Please fill it in, and for security reasons please avoiding special characters.

"; } // City $city = stripslashes_mysql($city); $city = trim($city); $cityClean = $city; $cityClean = strip_tags($cityClean); $cityClean = htmlspecialchars($cityClean); if(!$cityClean or $cityClean != $city){ $error .= "

There was a problem with the city. Please fill it in, and for security reasons please avoiding special characters.

"; } // Phone $phone = stripslashes_mysql($phone); $phone = trim($phone); $phoneClean = $phone; $phoneClean = strip_tags($phoneClean); $phoneClean = htmlspecialchars($phoneClean); if(!$phoneClean or $phoneClean != $phone){ $error .= "

There was a problem with the phone number. Please fill it in, and for security reasons please avoiding special characters.

"; } /* // Check username characters $new_com1 = ereg_replace("[^A-Za-z0-9-]", "", $usr); if($new_com1 != $usr and $oktocreate == true){ $oktocreate = false; $ret = "The username must be made up of alphanumeric characters. That is letters and numbers only."; } */ // Check password if($password1){ $password1 = trim($password1); $password2 = trim($password2); if($password1){ if(strlen($password1) < 5){ $error .= "

The password must contain at least five characters.

"; } if($password1 != $password2){ $error .= "

The password did not match the duplicate. Try again.

"; } } } return $error; } if( $action == "saveaccount"){ $error = ""; $error = checkprospectdetails($email, $company, $firstname, $lastname, $city, $phone, "new"); if($error){ echo "". $error . ""; $s = "newaccount"; }else{ // All good. Save the data // Generate the password $password = makerandompassword(); $insert = mysql_query("INSERT INTO Y_prospects( company, email, password, firstname, lastname, city, country, phone ) VALUES ( '".addslashes_mysql($company)."', '$email', '$password', '".addslashes_mysql($firstname)."', '".addslashes_mysql($lastname)."', '".addslashes_mysql($city)."', '".addslashes_mysql($country)."', '".addslashes_mysql($phone)."' ) SELECT LAST_INSERT_ID=@@IDENTITY "); $r = mysql_fetch_assoc($result); $uid = $r['LAST_INSERT_ID']; // Make the number negative as this indicates a prospect user id. $uid = $uid * -1; // Now log the user in $uid = loginuser($email, $password); if(is_numeric($uid) and $uid < 0){ echo '

You have created an account and you are now logged in. Your password has been sent to your email address. Please keep it on record for future use of our services.

'; // Send the password $toemail = $email; $toname = $firstname . " " . $lastname; $subject = "Your Print Manager password"; $fromemail = "support@softwareshelf.com"; $fromname = "Print Manager Service"; $textmessage = "Thank you for signing up to printmanager.com \n\n Here are your login details. \n\n Email: $email \n Password: $password"; $htmlmessage = nl2br($textmessage); $htmlmessage .= '

-----------------------------------------------


Print Manager
PO Box 209, Nevada City, CA 95959
USA Contact: 727-445-1920 | 800-962-2290 | Office Hours: 4:00am to 6:00pm PST
Europe Contact: +44-1342-310950 | 0800 048 8689 | Office Hours: 8:00am to 5:00pm GMT

Sales: sales@printmanager.com
Support: support@printmanager.com
Customer Service: service@printmanager.com
Website: http://www.printmanager.com '; // Send the actual email //include("mailer.php"); include("management/mailman.php"); //echo " - " . $mail->Username; if($urlref64){ $url = base64_decode($urlref64); ?> Oops! That failed. Our fault. Please contact us for any help.

"; } } } if($uid == 0 and $action == "login" and $username and $password){ $uid = loginuser($username, $password); if($uid == 0){ echo "

Login failed. Please check your username and password.

"; }else{ if($urlref64){ $url = base64_decode($urlref64); ?> You are now logged in. Continue

"; } } if($uid == 0 and $action == "login" and $submit == "Lost Password"){ echo "

Lost Password

"; if($username){ $found = false; // Find out who this is - Check Y_customers $result = mysql_query("SELECT id, password, contact from Y_customers WHERE email = '$username'"); if($row = mysql_fetch_array($result)){ $found = true; $passtosend = $row['password']; // Send the actual email $fromemail = "support@printmanager.com"; $fromname = "Print Manager"; $htmlmessage = "

Your password for PrintManager.com was requested.

"; $htmlmessage .= "

Password: ".$passtosend."

"; $htmlmessage .= "

Best regards,
Software Shelf International

"; //$toemail = $row['email']; $toemail = $username; $toname = $row['contact']; $emailtype = "Password Reminder"; //echo "

Send to: $toemail

"; //include_once("mail.php"); include("management/mailman.php"); } if($found == false){ // Find out who this is - Check Y_prospects $result = mysql_query("SELECT id, password, firstname, lastname from Y_prospects WHERE email = '$username'"); if($row = mysql_fetch_array($result)){ $found = true; $passtosend = $row['password']; // Send the actual email $fromemail = "support@printmanager.com"; $fromname = "Print Manager"; $htmlmessage = "

Your password for PrintManager.com was requested.

"; $htmlmessage .= "

Password: ".$passtosend."

"; $htmlmessage .= "

Best regards,
Software Shelf International

"; //$toemail = $row['email']; $toemail = $username; $toname = $row['firstname'] . " " . $row['lastname']; $emailtype = "Password Reminder"; //echo "

Send to: $toemail

"; //include_once("mail.php"); include("management/mailman.php"); } } if($found){ echo "

Your password has been sent to ".$toemail."

"; }else{ echo "

Sorry - We could not find your details. Please contact Print Manager.

"; } }else{ echo "

You need to enter an email address.

"; } } if($s == "newaccount"){ ?>

Company:*

Email:*

First Name:*

Last Name:*

City:*

Country:*

Phone:*

 

Creating an account gives you access to our free trials.

The email address is your login username and also our contact email address for your organisation.

A password is automatically generated and sent to the email address.

* All fields are required.

The email address is our contact email address for your organisation.

The password is automatically generated and if you do not have it already we can send it to the email address - Simply enter your contact email address then click on the lost password button.

If you do not know which email address we hold for your organisation, please contact us now.

 

Email:

Password:

0 and $uid <=1000){ ?>
Mozart
 
Log Out
 
Create New Account