Pinterest Stumbleupon Whatsapp
Ads by Google

setup irc serverInternet Relay Chat. One of the early forms of communication on the Internet, IRC featured a very basic chat protocol. While Tim has explored creating an individual IRC channel How To Create Your Own IRC Chat Channel How To Create Your Own IRC Chat Channel Read More , we’ll be creating a fake IRC server using phpFreeChat, which allows you to create separate “channels” and various other features reminiscent of IRC (though certainly not as advanced). You’ll need a web server with PHP.

Installing phpFreeChat

  • Grab the latest phpfreechat-x.x-setup.php at Sourceforge (1.2 is the latest version at the time of this writing).
  • Upload it or move it to a local web server directory. We’re going to be using a XAMPP installation, so we’ve moved it to the root directory. You don’t want to put the install file where you want the chat to be.
  • Navigate to the file. Our URL would be http://localhost/phpfreechat-1.2-setup.php. You’ll be greeted with a Pre-Install Check. Hopefully it looks like the picture below. Hit ‘Next’.
  • install chat room

  • You’ll be prompted for an install path. By default it creates a phpfreechat directory in the current directory, but you can change it to whatever you wish. Hit ‘Next’.
  • Path of Installation

  • It’ll ask you to confirm the install. Click ‘Next’. Watch the pretty progress bar. Once it’s finished, click ‘Next’.
  • It’ll have installed itself in the directory of your choice, ours being http://localhost/phpfreechat/. Do as it says and delete the phpfreechat-x.x-setup.php file.

Quick Configuration

Setting up the Admin Account

The equivalent of an IRC channel op, the admin password allows you to gain access to privileges such as kicking, banning, and viewing user IP addresses. Admin status is global across all channels.

  • Open up index.php in the installation directory. Add the following line (before: $chat =…)

    $params[‘admins’] = array(‘username‘ => ‘password‘);

    Replace username with the desired username, and password with the desired password.

  • Remove the following line:

    $params[“isadmin”] = true; // do not use it on production servers ;)

  • Save the file. Head to the chat room, and type /rehash
  • Change your nickname to the username specified in step 1 by typing /nick username
  • Type /identify password where password is the password you specified in step 1 – If all goes well you should be identified.
  • Prompt for Nickname Upon Entry

    By default, the chat assigns you a nickname guest followed by random numbers. To force the user to choose a nickname when they enter:

  • Remove the following line from index.php:

    $params[“nick”] = “guest”.rand(1,1000); // setup the intitial nickname

    Save the file.

  • Rehash the chat with /rehash – make sure you’re logged in as admin, indicated by the shield icon next to your name.
  • Remove Censor and Flood Protection

  • Add the following line to index.php:

    $params[‘skip_proxies’] = array(‘noflood’,’censor’);

    Save and rehash the chat.

    Final Notes

    add chat room to your site

    Important Commands

    • /nick username – Change your username to username
    • /identify password – Gives you admin rights, given the right username and password.
    • /op username – Gives username admin rights.
    • /kick username reason – Kicks a username with a given reason.
    • /join room – Joins room “room”. If it doesn’t exist, it’s created.
    • /help – Your best friend.

    The Basics

    • A list of the rooms you’re currently in is shown as tabs at the top of the chat, click to switch rooms (equivalent of IRC channels). You can create new ones using the aforementioned /join command.
    • You can view the IP address and an option to private message a user by clicking on their name in the list.
    • Explore around. You can find phpFreeChat documentation on their website.

    Do you prefer to use any other IRC-type chat software for your website? If so, recommend it to us in the comments. Or if you have any problems setting this up, leave a question and we will try to help you.

    1. jsebean
      January 17, 2010 at 4:31 pm

      I run a website and use this program and it's awesome! Didn't find out about it here, but still, AWESOME!

    2. mohamed maher
      September 28, 2009 at 9:40 am

      plz help i uploaded the setup file but when i go to the url there is a white page

    3. Dean
      July 22, 2009 at 10:55 pm

      I am trying to link my PHPFreeChat to our Mysql Database to ensure that only registered users can use out chatroom. HELP!

      ALL I want to do is to link to our SMF User database.

      CODE:

      Truckin' Bozo's Chat!

      NOTE:
      If you are inactive for five minutes you will be auomatically logged off. To log back on, in the command line type:

      /connect YOURUSERNAME

      SPONSORS

      The People's Journal

      SS Travel Corporation

      Help Section

      Useful Links

      printChat(); ?>

    4. Dean
      July 22, 2009 at 10:58 pm

      I Tried to put my code in the post. Please refer to the link to see the code.

      truckinbozo.com/source.txt

      Thanks

    5. elgee
      June 8, 2009 at 9:34 pm

      Oh ok, thanks for the clarification :)

      elgee

    6. elgee
      June 8, 2009 at 2:25 pm

      Hi,

      I have a question about this app. By fake IRC server, do you mean, it is similar to an IRC server, but is not one? And would I be able to run an existing IRC bot against this server, in that case?

      Thanks,
      elgee

      • Jason K
        June 8, 2009 at 8:22 pm

        Yes, it is similar to an IRC server but it is not one. So, no, you would not be able to run an existing IRC bot.

    7. bayaas
      June 2, 2009 at 8:43 pm

      yeah ... it's hard to install

    8. Verga
      May 23, 2009 at 4:44 pm

      Im going to use phpfreechat but i find it hard to install :(

    9. Kelly
      May 4, 2009 at 3:14 am

      Why remove flood protection? Doesn't it exist to prevent users from flooding with malicious scripts?

      Does keeping flood protection also prevent the admin from running macros? And on that topic, does this chat program support macros like IRC does?

    10. flynn
      April 24, 2009 at 9:34 pm

      i like this chat , ubuntu?!

    11. Hector
      April 13, 2009 at 3:10 pm

      Hi im having the next problem

      Adding directory: / ..............................................[failed]
      >> Failed: could not make directory / Exiting...

      the directory path does not exist though it stills giving me this error, any solution?

    12. telskuf
      April 6, 2009 at 11:53 am

      Does the directory already exist? It has to be a new directory

    13. David Duong
      April 5, 2009 at 3:40 am

      I have just made a admin params.
      But when i try insert /identify mypassword ( mypassword is my password :D ) Then every time me writed : Identification faliure.

      • Jason K
        April 6, 2009 at 5:58 pm

        What's the exact line for your admin and password from the config? Make sure you're typing whatever is in quotes exactly.

        • Lisa
          August 11, 2009 at 3:51 am

          I get the same failure. I copied and pasted your line of code and just replaced with my own name and password. No matter what I try, I get a failure.

          • Glix
            August 26, 2009 at 12:59 pm

            Use the correct quotes :P
            $params['admins'] = array("username" => "password");

          • ripz0r
            January 3, 2010 at 3:04 am

            it still dosent work

            $params['admins'] = array(”ripz0r” => “password”);

            ////chat/////

            /identify password

            Identification failure

          • ripz0r
            January 3, 2010 at 3:11 am

            $params['admins'] = array('bob' => 'bobpw',
            'boby' => 'bobypw');

            found this one this works now just chanche gl bye and thx

    14. Amit Banerjee
      March 4, 2009 at 5:13 am

      Didn't worked ... After the Install Step It says " failed to create directory " and Exits ..

      • Jason K
        March 4, 2009 at 8:02 pm

        Does the directory already exist? It has to be a new directory.

    15. alfred
      February 26, 2009 at 1:57 pm

      I like that makeuseof.com is getting a little bit more technical :)

    16. adrian boioglu
      February 25, 2009 at 11:10 pm

      i know this is kindof offtopic, but what firefox theme is that?

      • Jason K
        February 26, 2009 at 2:27 am

        Default Firefox theme on XP. I use Hide Menubar to hide the top menu bar.

    Leave a Reply

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