SocialEngine4: Integrate LightIRC Chat Client

This is for Experienced users ONLY!

Do you have an irc server running LightIRC and wish to integrate it with SocialEngine4? Now you can!

Download this Widget and upload it to your SE4 Root:

Download Widget

Create new folder “chat” and upload lightIRC files there
Change config.js to config.php
Open config.php and add this on the top:

 <?php

 $SE4_Username = strip_tags($_GET['name']);
 header('Content-type: text/javascript');

 ?>

Change params.nick to:

params.nick                         = "<?php echo $SE4_Username; ?>";

And set params.showNickSelection on false

Save it!

Go to adminpanel and follow this way:

Click on Layout Editor on Layout in the menu above
Click on “New Page”
Give page name, like as ‘chat”
Click on “Edit Page Info”
Look for Page url and add “chat”
Move “I4US PHP Block” to your “Page Block Placement”
Click on “edit” of I4US PHP Block
Give a title, whatever you want
Paste this code in the I4US PHP Block:

 $MyUsername = Engine_Api::_()->user()->getViewer()->getTitle();
  echo '<div id="lightIRC" style="height:100%; text-align:center;">
        <p><a href="http://www.adobe.com/go/getflashplayer"><img src="http://www.adobe.com/images/shared/download_buttons/get_flash_player.gif" alt="Get Adobe Flash player" /></a></p>
        </div>
        <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/swfobject/2.2/swfobject.js"></script>
        <script type="text/javascript" src="chat/config.php?name='.$MyUsername.'"></script>
        <script type="text/javascript">
        swfobject.embedSWF("chat/lightIRC.swf", "lightIRC", "600", "500", "10.0.0", "chat/expressInstall.swf", params);
        </script>';

Click on “Save Changes”
Click on “Save Changes” in the menu
Go to http://yourwebsite.com/pages/chat/ and have a party! :D – Tested on SE 4.5

Looking for quality SocialEngine Hosting? Look no further than Arvixe Web Hosting!

Tags: , , , , , , , , , , , | Posted under SocialEngine | RSS 2.0

Author Spotlight

Andrew Cross

Andrew Cross

Hi, I'm Andrew. A am a 26, ICT Administrator which offers support to company's around the South Wales Area. I have created a few social sites for myself and other company's. So far 2 out of 3 have been successful using the powerful SocialEngine Script. I continue to try and help the community of SocialEngine by giving Support and Technical Help where possible.

Leave a Reply

Your email address will not be published. Required fields are marked *


9 × 3 =

You may use these HTML tags and attributes: <a href="" title="" rel=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>