Difference between revisions of "Widget"

From Mibbit Wiki
Jump to: navigation, search
(Widget parameters)
m (Reverting spam)
Line 36: Line 36:
<a href="http://widget.mibbit.com/
<a href="http://widget.mibbit.com/
&nick=پی سی ایرانیان_کاربر مهمان_%3F%3F%3F
&channel=%23pciranian Chat
&customprompt=به چت روم سایت پی سی ایرانیان خوش آمدید %20%20
%20 Welcome To www.pciranian.com Chat

Revision as of 08:01, 26 August 2009

Wiki Home | FAQ | Features | IRC Commands | IRC Modes | Widget Information | Widget: WebIRC Server Setup | URI Parameters | Wish List | Registration Information | Mibbit Staff

Home | Quick Start Guide | Live Mibbit Help

API | URI Parameters | Auto Connect

If you'd like to have webchat on your own website, then you could use a Java applet (slow, ugly, and not very accessible), or you could use Mibbit!

The first step, is to decide where you want your users to go. You can either create a channel on irc.mibbit.com or if you manage your own irc server, please contact Mibbit and ask for it to be enabled.

The basic URL for the Mibbit Widget is http://widget.mibbit.com/

Some of the parameters you can pass are:

  • nick - If you do not specify this, a random one will be chosen, e.g., mib_6d7s8euf (which may mean you are blocked from networks or channels). You can use your own unique name, plus optional random ciphers like: myChat_%3F%3F ( which results in myChat_56 or similar).
  • channel - The channel(s) that the user will be directed to.
  • server - This defaults to irc.mibbit.com.
  • autoConnect=true - avoids the connect-form. Additionally an op (using the mibbit widget) must set "/autoconnect on" in your channel (add &delay=30 for heavily visited pages).
  • settings - Unique "Prefs" ID (created using the Widget Manager). See also Widget Configuration and Skins.

Full list of defaults: Uri_parameters, example URL:


Please note you must urlencode all parameters. So #foo becomes %23foo etc.

You can use the Widget-Manager to create a link for an iframe or for a popup. If you need to test your widget, see [1].

Widget Configuration

Widget configuration is best done through passing a unique settings ID to the widget. To do this, create an account at the Widget-Manager. Then go into the preferences and change the settings to how you want your widget to appear. At the top of the preferences screen there will be a unique ID for your settings (like 7ca12664887d4b6e7a0fa6552f9e0de6). This should be passed to the widget using the &settings=theID. Example:


Widget parameters

There are many parameters that can be added to the widget by adding them to the URL. For example:

<a href="http://widget.mibbit.com/
target="_blank">start MibChat on irc.synirc.net (new window)</a>

See all: Full parameter list

Enable Autoconnect For Widget

Main Article: Autoconnect

Make sure that if you are doing this, make sure you are using the Mibbit widget, and have operator status or higher (if you use the main client it takes an hour to take effect). This works for any server.

  1. Send the command /autoconnect on (only once) in your channel
  2. Add &autoConnect=true to the widget's URI
  3. If necessary, remove the old &forcePrompt=xxx from the URI

Please note that autoconnect is set per channel. If you use a widget for multiple channels, you need to send the "/autoconnect on" command to each of them.

Linking to Widgets

There are two main ways to link to the Mibbit Widget, and one fringe way.

Linking Through Iframe

Try the Widget URI Creator to generate your own iFrame code.

The basic format simple though:

Make sure your page has a DTD setup, otherwise IE will not work properly. Place this code at the top of your page:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">

Then place this code where you want the chat widget to appear:

<iframe width="600" height="380" scrolling="no" frameborder="0"

Be sure to change the server and channel to your chatroom

See also: Advanced iframe using PHP to pre-fill a nick like "prefix_<randompart>"

Note: widget.mibbit.com had some stability issues. If your channel is located on irc.mibbit.net you can use


on your page.

Linking Through Popup

Copy and place this link in your page to open a popup window for the chat widget

<a href='#synirc/test' 
 onclick='window.open("http://widget.mibbit.com/?server=irc.synirc.net&channel=%23test&settings=7ca12664887d4b6e7a0fa6552f9e0de6","","width=999,height=555")'>Join our "#test" chat on synirc (popup)</a>

Open in a new browser window

a conventional link for your web page (if you don't like popups):

<a href="http://widget.mibbit.com/?server=irc.synirc.net&channel=%23test&settings=7ca12664887d4b6e7a0fa6552f9e0de6" 
Open our "#test" chat on synirc in a new window/tab (depends on your browser settings)</a>

Widget Statistics

For some easy to use statistics about your widget, and to add them to your website, see API