Z for short

"To write more, write more." This is my writing notepad.

Add a Flag Counter to your blog

leave a comment »

Flag CounterInstead of just showing the number of hits on your blog, jazz it up with a Flag Counter. The one shown here is from Flagcounter.com.

The code for the Flag Counter is added to a text widget in the sidebar or header or wherever your blog allows it.

To add a Flag Counter to the sidebar in WordPress:

1. Go to Flagcounter.com.

2. Choose options for the counter: number of flags to show, number of flag columns and label (default is “Visitors”). Check the Show Country Codes and Show Pageview Count boxes if you want the 2-letter country code to appear next to each flag, and the number of views to appear under the flags. You can also adjust the colors.

3. Click the Get Your Flag Counter button and register your counter if you like, to be able to manage your counter account later. Click Continue (Skip if you don’t want to register).

4. Copy the code under Code for websites. It looks something like this:

<a href=”http://s06.flagcounter.com/more/wkoE”><img src=”http://s06.flagcounter.com/count/wkoE/bg=FFFFFF/txt=000000/
border=CCCCCC/columns=2/maxflags=12/viewers=0/labels=1/pageviews=1/”
alt=”free counters” border=”0″></a>

5. Paste the code into a text widget in WordPress as usual. If you have forgotten how, here’s the procedure:

– Go to the Dashboard of your blog and choose Widgets under Appearance.
– Under Available Widgets, drag the Text widget to the desired position in the Sidebar to the right.
– Click Save.
– The counter appears in the blog.

You can edit the code later to modify the appearance of the counter:

<a href=”http://s06.flagcounter.com/more/wkoE”><img src=”http://s06.flagcounter.com/count/wkoE/bg=FFFFFF/txt=000000/
border=CCCCCC/columns=2/maxflags=12/viewers=0/labels=1/pageviews=1/”
alt=”free counters” border=”0″></a>

bg: FFFFFF, 000000 and CCCCCC are the colors for the background, text and border. Specify your own colors if you like.
columns: The number of columns in the counter. This can be any number between 1 and 9.
maxflags: The max number of flags shown. This can be any number between 1 and 248.
viewers: The text label above the flags. The default value of 0 shows Visitors, as in the image above, while 3 removes the label entirely. Type in any other text you like to show. If you for instance want the label to readVisitor Flags!, type the following: Visitor+Flags! – the + sign will be converted to a space.
labels: The 2-letter country code next to each flag. 0=off, 1=on.
pageviews: The pageview counter below the flags. 0=off, 1=on.

Read more at Flagcounter.com.

Advertisements

Written by Solveig Hansen

April 11, 2011 at 9:13 pm

Share your thoughts:

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: