Auto Log-in & Load - Use Your Existing Database

all.gif

 

Auto Log-in of your Web site's registered users into your chat room is accomplished by passing a user name variable from your database, session cookie, or through the URL, and placing it into the chat applet HTML. Through some minor customization to the chat applet HTML, the user will be logged directly into the chat room without requiring a secondary log-in through the chat client's log-in panel.

 

For example, if you place your chat room in a members-only area of your web site, and you require users to authenticate themselves to gain access to the member area, their user name can be passed into the chat room to automatically log them in with their registered user name. User authentication remains a function of your web-server, and not of the chat client or server. Your chat service already includes the Auto Log-in feature.

 

Required Parameters

 

There are 2 mandatory parameters to add to your chat applet HTML to utilize the Auto Log-in feature. The parameters are:

 

Ctrl.AutoLogin

Net.User

 

Default Iframe Room Code Parameter Example:

 

 

Add these 2 mandatory parameters to the iframe code:

 

Ctrl.AutoLogin=true&Net.User=<place user name here>&

 

<!-- Begin ParaChat Room Code -->

<table border="1" bgcolor="eeeeee"><tr><td>

<iframe src="http://host7.parachat.com/pchat/applet/if.php?site=315xx&room=Lobby&Ctrl.AutoLogin=true&Net.User=<place user name here>&width=700&height=500" framespacing="0" frameborder="no" scrolling="no" width="700" height="500" style="background-color:#eeeeee;">

<p>You do not have iframes enabled. <a href="http://www.parachat.com/faq/iframe">More Info</a></p></iframe><a href="http://www.parachat.com"><img src="http://www.parachat.com/images/basic.png" border="0"></a>

</td></tr></table>

<!-- End ParaChat Room Code -->

 

 

Java Applet (legacy)  Room Code Parameter Example:

 

Add these 2 mandatory parameters to the Java Applet Code

 

<param name="Ctrl.AutoLogin" value="true">

<param name="Net.User" value="<user name variable>">

 

The Ctrl.AutoLogin parameter tells the chat room to permit a user to be automatically logged in to the chat room without displaying the log-in panel. The Net.User parameter value is where you need to pass the authenticated user name variable. For example, if a user is logged into your site with user name "Mike", then the correct format for the Net.User parameter value after the user name has been passed would be:

 

Net.User=Mike&

 

or

 

<param name="Net.User" value="Mike">

 

 

Optional Parameters

 

There are 2 optional parameters that can be added to the chat applet HTML, which can be utilized with the Auto Log-in feature. The parameters are:

 

Net.UserPass=<user's password>&

Net.User=<cookie password, etc.>&

 

or

 

<param name="Net.UserPass" value="<user's password>">

<param name="Net.Cookie" value="<cookie password, etc.>">

 

The Net.UserPass parameter is used only to pass a user's password to the chat server for authentication by the chat server, and not by your database. This parameter should only be used if a user profile exists on both the chat server as well as in your own database, and the password in your database matches the user's password on the chat server. There is no requirement to populate the Net.UserPass value with a user's password from your database.

 

info_red_sm.jpg HINT: If the admin user name and password that you supplied is also in your database, you would need to pass this user name and password into the chat applet HTML so you can access the chat room's administrative functions. The chat server requires a valid administrator user name and password to be supplied in order to gain access to the administrative features.