Code Explanation

This page explains how the invitation is activated and fulfilled with the code of the demo page. So you may add custom code to your website to install 123 web messenger.

<html>
<head>
<title>123WebMessenger</title>
</head>
<body>
<script>
var init_user="tom";
var init_password="tom";
</script>

<script language="javascript" src="js/123webmessenger.js"></script>
<script language="javascript" src="js/config.js"></script>
<script language="javascript" src="js/cookies.js"></script>
<script language="javascript" src="js/fly.js"></script>
<script language="javascript" src="js/dc.js"></script>
<script language="javascript">dcInit();</script>

<a href="javascript:FC_invite_1to1_chat('Jack')">Invite Jack</a>

</body>
</html>

It defines the user name and password to login; you can get them on the fly from session or cookie. For example:
(PHP):
var init_user=<? php echo $_SESSION['username'];?>;
Embed the following code between the HTML tags <body> and </body> and the username and password definition must be embedded before this.

The code runs the invitation method when a user presses the “invite” link. You can create a custom link to replace it, but it must call a JavaScript method named "invite" to launch the invitation, and the invited user's name must be passed as the parameter of the invitation method.

The invited person will see a small invitation window scroll down from the top left of the webpage which contains the web messenger code.


123 Flash Chat Product Suite




Powered by TopCMM Software Corp.