How to add a widget to your blog or portal

How to add a widget to your blog or portal

Ever came accross a blog displaying some cool add-on in the sidebar? Like displaying the local weather or a counter? These small items are called widgets. The web already offers a large number of widgets, so you'll definitely find something you like. And there's nothing easier to add HTML-based widgets to your blog, or even to all blogs within your portal. When choosing a widget, please note that you should stick to the width of your sidebar, which is usually between 180 and 200 pixels. In case you can choose a width for the widget, try those values since they should match best.

So here's a short how-to for your portal and a blog, once you've received your widget code:

1. Adding a widget to your blog
You need to be logged in and navigate to your blog administration pages. There, you navigate to "Weblog -> More options -> Sidebar". On that page, simply paste the HTML code for the widget into the text are labeled "Source code". Save it and you're done.

2. Adding a widget to your portal
Again, you need to be logged in and navigate to your administration pages, this time as a portal administrator. Next, go to "Layout -> More options -> Buttons". You'll see the editor where you can enter sidebar information for all your members. There, click the little "HTML" icon in the editor's menu bar and paste your widget code into it. Then, click "Update", choose the visibility of that widget, and click "Save".

Tipp: In case you want to have your widget be centered horizontally within your sidebar, you can easily do this as follows: before the beginning of your widget code, put this code:

<div align="center">

and after the end of your code put

</div>

 That's it. Enjoy your widgets!

You need to log in to 21PublishBlog in order to comment on this entry. Back to entries
PhoenixGraphix
on June 18, 2008 at 3:13 PM
Wow, talk about some simple HTML... Now tell me, how many people that you know about have put widgets on their blogs?
Why get widgets from an outside source when you can just write the ECMAscript for them yourself? And if you aren't very computer-savvy in the first place, how do you think they are going to get the code for the widget in the first place?
-Phoenix
Consumer Complaints
on August 15, 2008 at 3:04 PM
Here is our consumer complaint widget code. You can see it working at http://iripoff.com/widget/get-widget
Megalos Gouru
on February 10, 2009 at 4:15 AM
Web Stats( http://webseomasters.com/ ) is offering a widget that provides important
information about who is visiting your blog or website. An entry is posted to the widget
every time a person arrives at your website and again when the person leaves. Web Stats
entries list referring web site where your visitors came from, what was their post of
interest, and their geographical location. To visualize the gadget, also posts a little
flag near every entry to indicate what country each visitor is from.
The offered widgets are all free and you register to get them for your blog or website.
They are also extremely lightweight and won’t slow your site down.
If you’re a Blogger or Typepad user you can install any of the widgets with one click. If
you use a different blogging platform or website, you can simply cut and paste the
provided script into your blog template or website HTML. Live Web stats will appear in
the position you paste the script.