Rather than using your built in survey management to launch a...

Expand / Collapse
 
     

Rather than using your built in survey management to launch a pre-chat I would like to use my own survey? Also, is it possible to embed the pre-chat survey directly in to my webpage?


How do I put a survey in my web page that will open a chat?

You can either use a seperate page on your website for this and have it look like just another page or you can put the survey into an existing page and have the chat start from there.

If you would like this to be a separate page copy and paste the following code into a blank webpage.

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
<HEAD>
<TITLE>Sample embedded chat form</TITLE>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1" />
</HEAD>
<SCRIPT language=JavaScript>

 function doLiveHelp () {
  var lhWin = window.open('','LiveHelp','toolbar=no,location=no,directories=no,menubar=no,status=no,scrollbars=no,resizable=yes,replace=no');
  if (lhWin != null)
  {
   document.loginForm.submit();
   lhWin.focus();
  }
  else
  {
   // in reality, this is never called.  Almost all popup blockers work with this code.
   alert('Unable to launch Live Help Window, please disable all popup blockers and retry');
  }
 }
</SCRIPT>
<BODY>
     <FORM name=loginForm action=http://service.velaro.com/visitor/requestchat.aspx method=GET Target="LiveHelp">           
            <INPUT type=hidden value=inqueue name=showwhen>
           
            <!-- Change the value= to your account's SITEID. -->
     <INPUT type=hidden value=XXXX name=siteid>

     <!-- If you want to route to a specific department, add this line of code and use the proper DEPTID from your account.
          <INPUT type=hidden value=XXXX name=deptid>
            -->

            <INPUT type=hidden name=additionalInfo>

     <!-- Custom form fields, change and format at will. -->
            Name: <INPUT maxLength=30 name=forceName><br>
            Company: <INPUT  maxLength=500 name=Company><br>
     Email: <INPUT class=CF1LoginInputFieldStyle maxLength=500 name=email><br>
            Please enter a brief summary of your question:<br>
     <TEXTAREA name=question rows=5 cols=40 maxLength=250 ></TEXTAREA><br>

            <INPUT type=Button value=Continue onClick="doLiveHelp();">
      </FORM>
</BODY>
</HTML>


If you want to just put the survey into an existing web page along with other content, then copy and paste this part only.

<SCRIPT language=JavaScript>

 function doLiveHelp () {
  var lhWin = window.open('','LiveHelp','toolbar=no,location=no,directories=no,menubar=no,status=no,scrollbars=no,resizable=yes,replace=no');
  if (lhWin != null)
  {
   document.loginForm.submit();
   lhWin.focus();
  }
  else
  {
   // in reality, this is never called.  Almost all popup blockers work with this code.
   alert('Unable to launch Live Help Window, please disable all popup blockers and retry');
  }
 }
</SCRIPT>
<BODY>
     <FORM name=loginForm action=http://service.velaro.com/visitor/requestchat.aspx method=GET Target="LiveHelp">           
            <INPUT type=hidden value=inqueue name=showwhen>
           
            <!-- Change the value= to your account's SITEID. -->
     <INPUT type=hidden value=XXXX name=siteid>

     <!-- If you want to route to a specific department, add this line of code and use the proper DEPTID from your account.
          <INPUT type=hidden value=XXXX name=deptid>
            -->

            <INPUT type=hidden name=additionalInfo>

     <!-- Custom form fields, change and format at will. -->
            Name: <INPUT maxLength=30 name=forceName><br>
            Company: <INPUT  maxLength=500 name=Company><br>
     Email: <INPUT class=CF1LoginInputFieldStyle maxLength=500 name=email><br>
            Please enter a brief summary of your question:<br>
     <TEXTAREA name=question rows=5 cols=40 maxLength=250 ></TEXTAREA><br>

            <INPUT type=Button value=Continue onClick="doLiveHelp();">
      </FORM>

In both cases you must change the SITE ID number to reflect your specific account.

You can find your SITE ID by logging into the control panel at http://login.velaro.com . Once logged in your Account name and Site ID will be in the upper right corner of the screen next to the words “current site”.
This is your account name and site ID. The number in the parenthesis is your site ID number.

If this is to be for a specific department you must also specify the department ID number.

To get your specific department ID number, in the control panel at http://login.velaro.com , go to Deploy -> Live Help Buttons.
That will show you the basic script for your chat button. Click on “directed to” and then select the proper department.
Now the script will change to reflect a department. Look for this text in that script

siteid=XXXX&showwhen=inqueue&deptid=XXXX

Where “X” stands for a number. The number next to “deptid=” is the department number for the specific department you just selected. That is the department  number to change in the above script.

Change and format the questions as you like..
Publish to your website.


Add Your Comments


Name: *
Email Address:
Web Address:
Verification Code:
*
 

Details
Last Modified:Wednesday, January 30, 2008
Last Modified By: David
Type: HOWTO
Article not rated yet.
Article has been viewed 539 times.
Options