Customer login and wholesale pricing

In Version 4.2.0 we introduced the customer login feature. This allows for wholesale pricing / tax / shipping exemption for login customers and page protection. This means it is possible to offer retail and wholesale pricing without the need for a second database as well as offering tax and shipping exemption to particular users. You can also restrict access to certain pages of your site.

Version 5.3.0 saw the expansion of the customer login system to allow customers to create their own account, view their order history and save billing and shipping addresses.

Enabling customer login

If you would like to have a login status box on each page you will need to add one line of code where you would like the login box to appear. The code you need is the following:

<!--#include file="vsadmin/inc/incminilogin.asp"-->

Paste that into HTML / code view exactly where the login box should appear and make sure that it comes somewhere after the include lines:

<!--#include file="vsadmin/db_conn_open.asp"-->
<!--#include file="vsadmin/includes.asp"-->
<!--#include file="vsadmin/inc/languagefile.asp"-->
<!--#include file="vsadmin/inc/incfunctions.asp"-->

To enable the login you will then need to go to vsadmin/includes.asp and add the line (if it's not already present) enableclientlogin=true

Finally you'll need to set up the login page itself. Open your thanks.asp page and save it as clientlogin.asp. Then go in to HTML / code view and locate this line:

<!--#include file="vsadmin/inc/incthanks.asp"-->

....and change it to

<!--#include file="vsadmin/inc/incclientlogin.asp"-->

Save clientlogin.asp and upload it to your server.

You should now be able to see the login box and the login page on your store.

login screen
Login Box

login screen
Login Box after successful login

login screen
Login Box if enableclientlogin=true
hasn't been set in vsadmin/includes.asp

login screen
Login Dialogue on clientlogin.asp

Once you click on login you will be taken to a page to enter your email address and password

Client login

Once logged in and viewing clientlogin.asp customers can:

... view their account details

Client login

... edit their shipping and billing addresses

Client login

... as well as look up past orders.

Client login

To allow customers to sign up for an account you will need this addition to vsadmin/includes.asp
allowclientregistration=true
To force customers to login before purchasing add this to vsadmin/includes.asp
forceclientlogin=true
To remove the prompt on cart.asp to login then add this to your vsadmin/includes.asp file
noclientloginprompt=TRUE

Customers will be prompted on checkout if they would like to log in or set up an account unless you have added the setting above.

Client login

Setting up a client for wholesale pricing, discounts and shipping / tax exemption

In your home admin page there should be a link client login admin, click to set up your clients'options.

Client login

Click on new client login to add the details and parameters available for each particular customer or use the search feature to modify an existing client.

Customer login admin

Enter the client login name, email address, password, the relevant action (You can use CTRL + Click to select more than one choice) and finally the login level if applicable. When done, click on submit and your client will have been set up with the parameters you have assigned. The promotional email box if checked will write the client's email address to the database and can be used for mail shots.

Login level

You can assign different levels of login permissions on any page to say that a particular page is restricted to anyone below the login level assigned in the login admin section. For example, if you set requiredloginlevel=4 then only people who you have set up with a login value of 4 or above can view the page when logged on. Only place the code on the pages where you need to restrict access, for example, it should not go on clientlogin.asp

To add the level of restriction to individual pages you will need to add the line:

<% requiredloginlevel=4 %>

...where 4 is the threshold of permission for that page. This needs to come anywhere before the line

< !--#include file="vsadmin/inc/incfunctions.asp"-->

Payment methods

From Version 4.9.0 it is now possible to limit certain payment methods to logged in customers if required. Just select from the "Login Level" dropdown in the payment provider admin page.