Showing posts with label blogger tutorials. Show all posts
Showing posts with label blogger tutorials. Show all posts

Screen resolution CSS hack for web designers

Most of us might have noticed that our sites may look different in different screen resolutions. Though I have already posted one article on making website layout cross browser compatible , but its also necessary to make your site compatible for different screen resolutions. The visitors of your site will not have same screen resolution your are using. So it's mandatory to make your site compatible for different screen resolutions. For example, In lower screen resolutions like 800x600 px the website layout will be perfect. But when you look at your site at a higher screen resolution like 1024x768 px or even higher , the website header or sidebar may be aligned to either right or left. It's all because the designer might have designed the site for a particular screen resolution. In the screen resolution he was working , the site may look perfect. But when it comes to higher screen resolution , the theme may be misaligned.


what is the best screen resolution settings?


One can't design a website for a particular screen resolution, because visitors will have different screen resolutions. According to me , the best screen resolution on which the designer should be concentrating on should be higher than 1024px. For example if you take techieblogger's last month stats , most of my visitors are using higher screen resolution.

screen resolution compatibility

Some of the web designers use JavaScript to control the screen resolution compatibility. But it will reduce the site loading time.Instead of using JavaScript , I will explain how to make your site higher screen resolution compatible by making changes in CSS codes.


CSS controlling the alignment of the layout


Before explaining the original hack, first let me describe about the css code which controls the layout alignment.

margin: auto;

The simple margin tag in CSS controls the alignment of the site layout in different screen resolutions. I have selected auto to change the layout alignment in accordance with the visitors screen resolution.

Screen resolution compatible CSS - Blogger users

In order to make changes to your CSS code in blogger blogs , follow the below steps.

step 1 : First go to Layout section of your blog.
step2 : Then navigate to EDIT HTML page

Now add the margin: auto; tag in the css codes of the following sections.
  • Header

  • Outer wrapper

  • content wrapper

  • wrapper

  • Footer


If one more sections are missing in your style sheet , then insert that code in the respective div sections used in your blogger template.


Screen resolution compatible CSS - Wordpress Users


To edit the css code in your wordpress blogs, follow the below steps.

first go to appearance option in your wordpress dashboard. Then go to EDITOR page. In that page , add the css code margin: auto; in the following css sections.

  • Header

  • Outer wrapper

  • content wrapper

  • wrapper

  • single entry

  • Footer


how to change screen resolution


For checking your site compatibility with different screen resolutions do any one of the below steps.

how to get a higher screen resolution on windows vista/XP


To change the screen resolution of your PC , do the following steps.Right click on your desktop , then click the option "Properties" there.A new window will open. Now navigate to "settings " tab. There you can see a slider to change the screen resolution. With that slider you can either increase or decrease. After you chose a particular screen resolution , click apply. It will give you a warning message click "ok".

properties window

Now open the browser and visit your site for compatibility.


how to set screen resolution using keyboard hotkey


You can also check the compatibility of your site with different screen resolutions with simple keyboard short keys.
First go to your blog and do the following :
To reduce the screen resolution , press "ctrl" and scroll down the mouse roller.
Or
press " ctrl " button and press "-" button.

To increase the screen resolution, click "ctrl" and "+" button or else press " ctrl " and scroll up the mouse roller.

With the above keyboards hotkeys , you can check the screen resolution compatibility of your site.


Hope this article will be useful for all web designers who want to create wordpress themes or blogger templates which are higher screen resolution compatible. If you have any problem with your website layout alignment, then please email me about the issue.

Show Adsense ads below post title

In this tutorial I will explain how to place Adsense ads below post title in Blogger Blogs with lots of customization tips. You might have noticed that most of the bloggers show Google adsense ads below title to increase their Click through rate and earnings.

According to Google adsense help pages " Where to place adsense ads ?". Placing adsense ads below title and above article content can bring high ctr and performance.

Adsense ads Below post title

This "heat map" illustrates the ideal placing on a sample page layout. The colors fade from dark orange (strongest performance) to light yellow (weakest performance). So it's clear from the heat map that the adsense ads below post title can bring high ctr.

How to add Adsense ads below post title ?

It's really very easy to add adsense ads below post title in blogger. Inorder to add adsense ads below post title ,just follow the below steps.

Before adding the adsense ads to blogger templates , we need to encode our adsense ads code.If you add the adsense code without encoding then you can't see any adsense ads below post title.

Encoding Adsense Ad Code ?

To encode adsense ads, first create an adsense ad and then visit centricle website to encode. In centricle web page , you need to paste your adsense code in the text area and then click " Encode ". Copy the encoded code. Now your adsense code is ready to be added to blogger template.

Adding adsense ad code to blogger template

step 1 : Go to layout section of your blogger template and then navigate to EDIT HTML sub tab. There check the "Expand Widget Templates ".

step2 : Look up the following tag : <p><data:post.body/></p> and paste the encoded adsense ad code above that tag.

Then click save. That's it Now we have added the adsense ad code below the post title in blogger blog successfully.

Customizing Adsense ads

Here are the few customization tips , which you can apply to increase your CTR.You might have seen that most of the bloggers will show more than Three posts in home page / labels page / archives page. But as per adsense TOS we can show only Three ads per page. So due to this we will see some blank spaces between post title and content , when the three adsense ads are already loaded.In order to avoid this error , we can show adsense ads only in Post pages i.e pages containing articles.

Showing adsense Ad only in Post pages

In order to implement this hack in your blogger template. you need to change the encoded adsense ad code to this.


<b:if cond='data:blog.pageType == &quot;item&quot;'>
Encoded Adsense code here
</b:if>


Now paste this code above <p><data:post.body/></p>

Making adsense ads to Float

After adding the adsense ad code to your templates , you can see that by default the adsense ad code will not allow any text to be shown nearby it.


So in order to overcome this error , we need to add some CSS codes to make adsense ad code to float either left or right.

For this we just need to modify the encoded adsense code to be added in step 2.

replace that encoded code with this one :

<div style="float:left;padding:5px;">

encoded adsense ad code here

</div>


Change the text in red to make adsense ad to float either to left or right.

My suggestion


According to me , instead of showing adsense ads in all pages ( home page , archives page and labels page ) , we can show adsense ads only in post pages to increase our ctr. If you are using the " Read More hack for Blogger with automatic Thumbnail creator script " then it's advisable to show adsense ads only in post pages.

Hope you guys will like this hack. If you need any more customization , then give me your suggestions via comments.

backup Blogger Blog Widgets - an easy video tutorial

One of the Major Problem Blogger users have is whenever they try to change their templates , They will loss their widgets even if they have taken backup of their blogger blog template. After changing their Blogger template , they need to add blogger widgets again manually. It's really annoying and time consuming process. So here I have created a video which will give you step by step instructions to backup blogger templates without loosing any of your widgets.

Backup Blogger Widgets

I have written a tutorial on Backup Blogger blog widgets " How to change Blogger Template without deleting widgets ? " .But most of the friends found that difficult to backup blogger widgets. So in order to help them , I have created a video tutorial for them to backup Blogger Template and blogger widgets while changing their blogger templates.

BACKUP BLOGGER WIDGETS VIDEO TUTORIAL



This is my first video tutorial guys , so please give me your suggestions. Due to lesser RAM , the Voice is a bit choppy. If you still have any doubts or difficulty to backup the blogger blog widgets then please feel free to contact me.

Very soon I will write tutorials on
  • How to backup Blogger Posts
and will explain the functionality of numerous blogger posts backup software. If you don't want to miss my future tutorials or hack then please suscribe to my blog.

Create Compatible CSS for Firefox , IE6 , Opera , IE7 , etc

Learn How to create Compatible CSS for Various Browsers like Internet Explorer 6 , IE7 , IE8 , Opera , Firefox , etc..

Web-designers create blogger template for Hours using one particular browser say Firefox , They don't know that the CSS code they use is compatible only for the browser they are working at present. Especially in IE6 , there are many Compatible issues.

for Example : the sidebar may appear below main content wrapper or there would be more gap between each widget , content wrapper and sidebar may overlap ,etc.

So in this Post I will tell you How to create CSS code which is compatible for almost all browsers. For this you need to have two browsers Internet Explorer 6 and Firefox .


I have chose IE6 because it is one of the most common browsers which windows have.

Incompatibility issues in IE6 and Firefox

First let's check is our current Blogger template is compatible with all browsers or not.

For this visit this website : Browser Screen shots
Enter your Blog URL and check the images there to know How your blog looks in various Browsers.

step 2 : If you find any incompatibility issues then you need to modify your CSS code to suit browsers.

Let's us see an Example



Generally the css we use if of this form :

#example {
float : left;
width : 170px;
margin-left : 5px;
}


In this assume that this particular div is incompatible with Internet Explorer version x.

then we need to modify the above css code as

#example {
float : left;
width : 170px;
margin-left : 5px;
}
#example {
float : left;
width : 185px;
margin-left : 3px;
}

in this first css code is for all versions of Internet Explorer and the second css code is for other browsers like firefox , opera , dillo , sea monkey , etc

but it will be confusing for you to edit.. so now we are going to add different CSS rules to IE, we can use the child selector command which IE can't understand. The child selector command involves two elements, one of which is the child of the other. So, html>body refers to the child, body, contained within the parent, html.

After introducing Child selector command , the css code must look like this

#example {
float : left;
width : 170px;
margin-left : 5px;
}
html > body #example {
width : 185px;
margin-left : 3px;
}

in this the green colored code is for IE versions and the red Colored code is for other browsers.

So with simple child selector command we can make our css code compatible for all browsers. Every time when I create a New template , I use to check whether it is compatible with other browsers or not. And I use to change the CSS code to suit that browser.

If you are unable to modify the CSS code then please mail me your template and explain the problem , I will rectify those errors and mail you back.

Add 125 x 125 ad section to Blogger

Learn How to add an extra B:section in your Blog template and also learn to add 125x125 ad banners !

I noticed that most of my readers are asking me How to add 125 x 125 ads section in Blogger templates. We know that to add a widget we need b:section with add page elements function enabled. So in this post I will tell you how to add b:section in your Blogger template and how to add CSS code to suit that b:section.


So with this hack you can add any widget you want. And I will also make a note on Adding 125 x 125 Page Element.

Lets start :

Adding b:section to Blog sidebar :

Step 1 : Sign in to Your Blogger account and got to Layout section of your Blog. Then Navigate to Edit HTML sub tab.



Step 2 : If your template possess two Columns in Right sidebar and if you want to add an Subscription form or 125 x 125 ad section above those two columns then do this step.


 If you have a sidebar like this then add a b:section above the 2 columns to add more widgets


Search this tag or similar


<div id='sidebar-right'> <b:section class='sidebar-right' id='sidebar-right' preferred='yes'>

The id can be different , so please paste the following code just above the sidebar section of your Blog.


<div id='sidebar2'>
<b:section class='sidebar2' id='sidebar2' preferred='yes'>
</b:section></div>


So Now we have added the b:section code needed to add more widgets. Then we need to add css code for that b:section


#sidebar2 {
float : right;
margin-left:4px; width : 415px; background:#ffffff;
font : 11px Verdana;
}
#sidebar2 .widget {
list-style-type : none;
margin : 5px 0 5px 0;
padding : 0;
}

#sidebar2 .widget h2, #sidebar2 h2 {padding-left: 10px;
text-align:center;padding-left: 18px;
font: 12px/34px "Georgia", Verdana;
text-transform: uppercase;
color: #ffffff;
background: url("http://i263.photobucket.com/albums/ii150/mohamedrias/sidebar_title-2.gif") repeat;font-weight:bold;

}

#sidebar2 a {
color: #969696;
font-size : 12px;
text-decoration : none;
}
#sidebar2 a:hover {
color: #969696;
text-decoration : none;
}
#sidebar2 ul {
border : medium none;
margin : 7px;
padding : 0;
}
#sidebar2 ul li {
list-style-type : none;
border-bottom : 1px dotted #87581f;
margin : 0;
background-position : 0% 100%;
padding-left : 8px;
padding-right : 10px;
line-height : 15px;
padding-top : 5px;
padding-bottom : 5px;
}
#sidebar2 ul li a {
text-decoration: none; background: url(http://i263.photobucket.com/albums/ii150/mohamedrias/side_li_bullet.gif) no-repeat; padding:0 0 0 12px;color: #87581f;
}


please edit the text in green to suit your Blogger template.

So we have successfully added the b:section and css codings required.

Now navigate to Layout section of your blog and there you will see a new " Add page Elements " link just above the sidebar.

If you are planning to add 125 x 125 ad section then click add page element link. there select add HTML/ JAVASCRIPT page widget and insert the below code over there.


<div class="sidebar-ads">
<div class="sidebar-banner"><a href="#">
<img border="0" src="http://i263.photobucket.com/albums/ii150/mohamedrias/banner_125x125.jpg "/></a></div>

<div class="sidebar-banner"><a style="text-decoration: none;" href="#"><img border="0" src="http://i263.photobucket.com/albums/ii150/mohamedrias/banner_125x125.jpg" /></a></div>

<div class="sidebar-banner"><a style="text-decoration: none;" href="#"><img border="0" src="http://i263.photobucket.com/albums/ii150/mohamedrias/banner_125x125.jpg" /></a></div>

<div class="clear"></div><p><a href="mailto:your email id" title="Advertise Here">Advertise Here</a></p>
</div>



After adding the code , click save widget. Then navigate to Edit HTML sub tab to add the necessary CSS code needed for this ad section


/* Sidebar - Ads */

.sidebar-ads {
float: left;
width: 410px;margin-left:5px;
margin-bottom: 5px;
}

.sidebar-banner {
padding: 5px;
float: left;
}


#sidebar2 p { background:url(http://i263.photobucket.com/albums/ii150/mohamedrias/adsdotdot-1.gif) no-repeat center left; margin-top:5px;text-align:right;padding-right:10px;}


Edit the test in red to suit your template.


 After adding the CSS code this is how it will look

So we have successfully added the 125 x 125 ad section.


Adding b:section below or above posts ( content)


Most wish to add two column b:section below main container ( posts ) . I will write about this hack soon. (Its a continuation of this hack )

If you guys need any help , please feel free to contact me mohamedrias1103@gmail.com . See you soon with new Blogger hacks.

Submit Blogger Blog Sitemap To Google Webmasters

Today I am going to tell how to add blogger blog to Google. Everyone ask Why we must submit our blog to Google , Since Google automatically indexes our Blog. But by submitting our blog sitemap to Google we can make Google to index our Blog frequently. One more question everyone ask is

"Why should we submit our Blog sitemap to Search Engines ? "

Sitemaps allows a webmaster to inform search engines about URLs on a website that are available for crawling. A Sitemap is an XML file that lists the URLs for a site. It allows webmasters to include additional information about each URL: when it was last updated, how often it changes, and how important it is in relation to other URLs in the site. This allows search engines to crawl the site more intelligently.

So in this Post I am going to tell how to Submit our Blog url and Blog Sitemap to Google. Just follow these step by step instructions:


Step 1 : Submitting Blog url to Google.


To submit our Blog Url to Google visit this page(http://www.google.com/addurl/?continue=/addurl). There you will find a form like this ,


 Submit Blogger/Blogspot blog to Google Sitemaps

Fill the form and click submit.

So we have successfully added our Blog to Google. but it's just not enough. We need to submit our Blog Sitemap to Google.

Step 2 : Now we need to add our Blogger Blog sitemap to Google Webmasters.

Why we need to submit our Blog to Google Webmasters ?

Google Webmaster provide us some useful tools which helps us to know lots of things about our site. I will explain only top 2 tools :

* Google Crawling info

- when Google Indexed our Blog.

- Broken or Invalid Urls which Google unable to crawl

* Top search queries


 Other Important Features of Google Webmasters


- with this tool we can find the top queries that drive traffic to your site and where your site is included in the top search results. This will let you learn how users are finding your site.

I hope with the small introduction you might have learned the importance of Google Webmaster. So let us see how to Add our Blog there.


We can do this in two methods. First I will tell how to do it manually

Login to Google Webmaster with your Google Account .

It will take you to Dashboard page. There you can see a box saying " Click here to add your site" . In that box type your full blog url with http:// and click add site.


You know With Draft Blogger we can automatically submit our blog to Google Webmasters




 Submit Blogger Blog to Google webmasters through Darft Blogger


So draft blogger will automatically add our blog url to Google Webmasters.

step 3 :

After adding your site url , navigate to dashboard again. One the right side of your site , you will find two links ( ADD and Verify ).

Now click " Verify " , it will take you to new page saying


 Copy and paste the meta tag in your blogger template

In this select " Add Meta Tag " and copy and paste the code in your Blogger template. Then save your Blogger template and click verify.

step 4 : Adding Blog Sitemap to Google Webmasters

Now navigate to Dashboard again , there click add sitemap link . It will take you to a new page , There click " Add a sitemap" . Then select " Add General Web Sitemap" . and do as instructed.




that's it. So we have successfully added our Blog sitemaps to Google.

Now we can see indexed stats of our Blog sitemap .


After submitting the sitemap , you will see indexed stats like these


 This is How the indexed stats of our sitemap will shown



If you have any trouble let me know , I will try my best to help you guys.

Show Labels containing specific number of Posts

I have already written " How to show only specific number of posts on Labels Page ". Today I am going to tell How to Show Only Labels with specific number of posts. This hack is very useful for those who have plenty of Labels in their Blog. It's a very simple hack , just follow the below steps to implement this hack in your blog.


Step 1 : Login to your Blogger Account and go to Layout section of your Blog.

If you don't have any Labels widget then add it by clicking ADD Page ELEMENT link in the Page. Then navigate to EDIT HTML subtab and Check EXPAND WIDGETS box.

Step 2 :

Now search for this Line.

<b:widget id='Label1' locked='false' title='Labels' type='Label'>

Now below this line , you will find this code


<b:loop values='data:labels' var='label'>
<li>
<b:if cond='data:blog.url == data:label.url'>
<data:label.name/>
<b:else/>
<a expr:href='data:label.url'><data:label.name/></a>
</b:if>
(<data:label.count/>)
</li>
</b:loop>


Now replace the above code with the following code.

<script type='text/javascript'>
var labelnum = 0;
<b:loop values='data:labels' var='label'>
if (<data:label.count/> &gt; 2) {
document.write(&quot;<li><a expr:href='data:label.url + "?max-results=5"'
rel='nofollow'><span><data:label.name/></span></a>(<data:label.count/>)</li>&quot;);
}
</b:loop>
</script>


It should look like this




Show only Labels with specific number of posts


In the above script edit the text in green to show Labels which contains more than text in Green.

for example : I have chosen number 2 , then Labels which contains more than 2 posts will be shown and other labels will be hidden.

Edit the text in red to show only specific number of posts in Labels Page.

That's it , you have successfully implemented the "Show Labels with specific number of Posts " hack in your blog.

If you have any problem , let me know.

Embed Comment Form below post in Blogger

One of the problem blogger have is that Blogger don't have a embedded comment form like wordpress. After a longtime , now blogger draft has found a trick to include comment form. It's really an easy hack for those who use templates provided by blogger. For those who use customized template need to include a HTML code to make the comment form appear below each post.

Let see how to do this :

Step 1 : First login to draft.blogger.com with your google account . Then in blogger dashboard click settings then comments. There you will find three options like this

As shown above check comment form placement : Embedded below post.

Step 1 is enough for users who use uncustomized blogger template. For them after doing this the comment form will be included below the post. Other users need to do the second step to make the comment form appear below post.

Step 2 :

Now go to Edit HTML section and first take a backup copy of your template. Then check expand widgets and search the folowing code



<p class='comment-footer'> <b:if cond='data:post.allowComments'> <a expr:href='data:post.addCommentUrl' expr:onclick='data:post.addCommentOnclick'><data:postCommentMsg/></a> </b:if> </p>



Now replace the above code with this following code




<p class='comment-footer'> <b:if cond='data:post.embedCommentForm'> <b:include data='post' name='comment-form'/> <b:else/> <b:if cond='data:post.allowComments'> <a expr:href='data:post.addCommentUrl' expr:onclick='data:post.addCommentOnclick'><data:postCommentMsg/></a> </b:if> </b:if> </p>



that's it save your template. Now you can see a beautiful comment form embedded below each post.

Screenshot :



Troubleshooting :

Do this step only if the comment form don't appear after step 2. In some templates even after adding this code the comment form will not appear. Thanks to Blogger Buster for this hack . Now search for <b:include data='post' name='comments' /> and add the following code immediately below it <b:include data='post' name='comment-form'/> .

After adding this code all templates will have comment form embedded below post . It's really one of the best hack which draft blogger has now made it available for all blogger users. Before this most visitors might have felt uneasy to comment , because to write comments we need to navigate from the page or a pop-up window will open . But now writing comments is made very easy.

Anything else we can do with the comment form ?

Yes , we can change the width and height of comment form .

to change the width and height of comment form just change the following code in green .



<b:includable id='comment-form' var='post'>
<div class='comment-form'>
<a name='comment-form'/>
<h3><data:postCommentMsg/></h3>
<p><data:blogCommentMessage/></p>
<iframe allowtransparency='true' expr:src='data:post.commentFormIframeSrc' frameborder='0' height='275' id='comment-editor' scrolling='auto' width='100%'/>
</div>
</b:includable>



Why are you waiting for , write a comment on this post and let me know how much you liked this post .

Show Date before each Post in Blogger

You might have noticed in my template that there is a date widget before each post. Only a very few templates will have this. I hope to have a best and beautiful template we must concentrate in all minute things. So I decided to help my visitors to implement this hack in their template too. In this post I will give you the code what i have in my template , you guys can customize it to suit your template. If you have any doubts ask me in comment section .

Let' s start :


Go to settings then Formatting and change the date header format and other things similar to this you find in the image below



After doing this save your settings . Now navigate to edit HTML section and check exchange widgets , Then add the following CSS code in the CSS section of your template


#fecha {
display:block;
text-align: center;
float:left;height:70px;
font-family: Arial, Helvetica, sans-serif;
width:70px;
margin:0px 5px 0 0;
background:url(http://i263.photobucket.com/albums/ii150/mohamedrias/post-top_bg.png);
}

.fecha_dia {
display:block;
font-size:1.2em;
margin:0;
color:#336699;
font-weight: bold;
padding:0.7em 0 1.1em 0;
text-align: center;
}

.fecha_mes {
display:block;
font-size: 0.9em;
margin:0;
padding-top:5px;
color:#A10000;
font-weight: bold;
text-align:center;
}

.fecha_ano { display:none; visibility:hidden; height:0; }


.post-title, .post-title a {
margin-bottom:20px; padding:2px 0 0 0;
color:#00335B;text-decoration:none;
}
.post-title a hover {color:#00335B;text-decoration:none}
.post h2 {
font-family: Arial, Georgia, Sans-serif;
font-size: 18px;
margin-bottom:20px;
text-align:left;color:#00335B;
text-transform:uppercase;
}

.post-body {
font-family: Verdana, Arial, Georgia, Sans-serif;
font-size: 13px;margin-bottom:20px;margin-left:170px;
line-height: 1.3em;
margin: 3px 0 5px 0;
}


.post_header {
margin:0; padding:0;
height:90px;

}

.post_headerr {
margin-bottom:20px; padding:0;
}


.post-labels {
background:url(http://i263.photobucket.com/albums/ii150/mohamedrias/category-1.gif) no-repeat;
margin:0; padding:0 0 0 20px;
}

.details .post-comment-link {
background:url(http://i263.photobucket.com/albums/ii150/mohamedrias/comments-1.gif) no-repeat;
margin:0; padding:0 0 0 20px;
}


and now search for this following code <div class='post uncustomized-post-template'> or similar and then select the code below that line upto <div class='post-body'>
and replace that code with the following code



<div class='post_header'>
<div id='fecha'>
<script>remplaza_fecha(&#39;<data:post.timestamp/>&#39;);</script>
</div>

<div class='post_headerr'>

<a expr:name='data:post.id'/>
<b:if cond='data:post.title'>
<h2 class='post-title entry-title'>
<b:if cond='data:post.link'>
<a expr:href='data:post.link'><data:post.title/></a>
<b:else/>
<b:if cond='data:post.url'>
<a expr:href='data:post.url'><data:post.title/></a>
<b:else/>
<data:post.title/>
</b:if>
</b:if>
</h2>
</b:if>

<div class='details'>
<span class='post-labels'>
<b:if cond='data:post.labels'>
<data:postLabelsLabel/>
<b:loop values='data:post.labels' var='label'>
<a expr:href='data:label.url' rel='tag'><data:label.name/></a><b:if cond='data:label.isLast != &quot;true&quot;'>,</b:if><b:if cond='data:blog.pageType == &quot;item&quot;'>
<script expr:src='&quot;/feeds/posts/default/-/&quot; + data:label.name + &quot;?alt=json-in-script&amp;callback=related_results_labels&amp;max-results=10&quot;' type='text/javascript'/>
</b:if>
</b:loop>
</b:if>
</span> |
<span class='post-comment-link'>
<b:if cond='data:blog.pageType != &quot;item&quot;'>

<b:if cond='data:post.allowComments'>
<a class='comment-link' expr:href='data:post.addCommentUrl' expr:onclick='data:post.addCommentOnclick'><b:if cond='data:post.numComments == 1'>1 <data:top.commentLabel/><b:else/><data:post.numComments/> <data:top.commentLabelPlural/></b:if></a>
</b:if>
</b:if>
</span>

</div>
</div>
</div> <div class='post-header-line-1'/>


Now you can see date before each post.

Screenshot :


Anything else you can do with this ?

yes, In the CSS code you can see some codes are in red . You can change the codes in red to suit your template .

Write comments about this post and give me your suggestions .

Star Ratings Widget for Blogger

One of the disadvantages for authors who use blogger is that there is no rating/voting widget . Because of that authors don't know how much the visitors liked their posts. After a longtime , now draft.blogger has found a trick . They recently posted that bloggers can now add Ratings widget on their blog through draft blogger .Let us see how to add ratings widget for Blogger,

Step 1 :
In layout section , under body layout click edit . A new pop-up window will open like this , here you need to check the

Show Star Ratings



If you are using template provided by blogger then you can see the widget after doing step 1. If you are using some other custom template then you need to add the following code below <div class='post-footer-line post-footer-line-1'> or similar .

<span class='star-ratings'> <b:if cond='data:top.showStars'> <div expr:g:background-color='data:backgroundColor' expr:g:text-color='data:textColor' expr:g:url='data:post.absoluteUrl' g:height='42' g:type='RatingPanel' g:width='180'/> </b:if> </span>

by adding this code there , the star ratings widget will appear below each post. If you want to add it below the post title , then add the above code immediately below <div class='post-header-line-1'/>let's see how it looks ,




you can also add that code anywhere you want. if you want to add style CSS like padding , color , etc add

<div style='padding-left:50px;
and other CSS part '>
star- ratings code
</div>

Thats it , hope you guys will like this new star ratings widget. See you soon with a new widget .For future updates , subscribe to my blog

Related Posts hack For Blogger includes custom CSS

Related Posts Widget for blogger is what everybody is looking for, In Most of the sites we will find only javascript code and HTML tag for related posts widget. After adding the code to your blog , you can see just a list of related posts without any arrows or style css. So i wanted to embed both in order to make the widget links looks beautiful.


First let's see the usual javascript and HTML Tag.Step 1 : Add the following Javascript code below ]]></b:skin> , thats between ]]></b:skin> and </head> .

<script type='text/javascript'>
//<![CDATA[var relatedTitles = new Array();var relatedTitlesNum = 0;var relatedUrls = new Array();function related_results_labels(json) {for (var i = 0; i < json.feed.entry.length; i++) {var entry = json.feed.entry[i];relatedTitles[relatedTitlesNum] = entry.title.$t;for (var k = 0; k < entry.link.length; k++) {if (entry.link[k].rel == 'alternate') {relatedUrls[relatedTitlesNum] = entry.link[k].href;relatedTitlesNum++;break;}}}}function removeRelatedDuplicates() {var tmp = new Array(0);var tmp2 = new Array(0);for(var i = 0; i < relatedUrls.length; i++) {if(!contains(tmp, relatedUrls[i])) {tmp.length += 1;tmp[tmp.length - 1] = relatedUrls[i];tmp2.length += 1;tmp2[tmp2.length - 1] = relatedTitles[i];}}relatedTitles = tmp2;relatedUrls = tmp;}function contains(a, e) {for(var j = 0; j < a.length; j++) if (a[j]==e) return true;return false;}function printRelatedLabels() {var r = Math.floor((relatedTitles.length - 1) * Math.random());var i = 0;document.write('<ul>');while (i < relatedTitles.length && i < 20) {document.write('<li><a href="' + relatedUrls[r] + '">' + relatedTitles[r] + '</a></li>');if (r < relatedTitles.length - 1) {r++;} else {r = 0;}i++;}document.write('</ul>');}//]]></script>

Step 2 : Check expand widgets and search for <b:loop values='data:post.labels' var='label'> , Now copy and paste the following code in blue between <b:loop values='data:post.labels' var='label'> and </b:loop><b:loop values='data:post.labels' var='label'>

<a expr:href='data:label.url' rel='tag'><data:label.name/></a><b:if cond='data:label.isLast != &quot;true&quot;'>,</b:if><b:if cond='data:blog.pageType == &quot;item&quot;'>
<script expr:src='&quot;/feeds/posts/default/-/&quot; + data:label.name + &quot;?alt=json-in-script&amp;callback=related_results_labels&amp;max-results=5&quot;' type='text/javascript'/></b:if> </b:loop>

customize the text in green to show as many links you want.

Step 3 : Now paste the following script the code just below

<p><data:post.body/></p> .


code :<script type='text/javascript'>removeRelatedDuplicates();printRelatedLabels();</script>


Thats it , now look at the page , it will look like this

You can see there is no styling , I wanted to make it look beautiful . So i made the following changes .Both step 1 and 2 are same , just in step three make some changes .


<div id='related-posts'><h2>Other Recommended Posts on This Category</h2><script type='text/javascript'>removeRelatedDuplicates();printRelatedLabels();</script></div>now its time to add css part for this div section ./*-- (Related posts widget -below posts) --*/#related-posts {float:center; width:450px; height:100%; min-height:100%; padding-top:5px;padding-left:5px;}#related-posts .widget{padding-left:6px; margin-bottom:10px; background-color:#fff}#related-posts .widget h2, #related-posts h2{ font-size: 1.6em; font-weight: bold; color: #0000FF; font-family: Georgia, "Times New Roman", Times, serif; margin-bottom: 0.75em; margin-top: 0em; padding-top: 0em;}#related-posts a{color:#A10000;}#related-posts a:hover{color:#A10000}#related-posts ul{list-style-type:none; margin:0 0 0px 0; padding:0px;text-decoration:bold;font-size:15px;text-color:#000000}#related-posts ul li{background:transparent url(http://img152.imageshack.us/img152/3756/bulletzc2.gif) no-repeat ; display:block; list-style-type:none; margin-bottom: 13px; padding-left: 30px;padding-top:0px;}

Now look at the page again ,

You can even customize the link color , arrow style , font-size , etcI hope you liked this related posts widget , see you soon with another widget or hack.

Related Posts Widget For Blogger with CSS

Related Posts Widget for blogger is what everybody is looking for, In Most of the sites we will find only javascript code and HTML tag for related posts widget. After adding the code to your blog , you can see just a list of related posts without any arrows or style css. So i wanted to embed both in order to make the widget links looks beautiful.




First let's see the usual javascript and HTML Tag. Step 1 : Add the following Javascript code below ]]></b:skin> , thats between ]]></b:skin> and </head> .



<script type="'text/javascript'">
//<![CDATA[
var relatedTitles = new Array();
var relatedTitlesNum = 0;
var relatedUrls = new Array();
function related_results_labels(json) {
for (var i = 0; i < json.feed.entry.length; i++) {
var entry = json.feed.entry[i];
relatedTitles[relatedTitlesNum] = entry.title.$t;
for (var k = 0; k < entry.link.length; k++) {
if (entry.link[k].rel == 'alternate') {
relatedUrls[relatedTitlesNum] = entry.link[k].href;
relatedTitlesNum++;
break;
}
}
}
}
function removeRelatedDuplicates() {
var tmp = new Array(0);
var tmp2 = new Array(0);
for(var i = 0; i < relatedUrls.length; i++) {
if(!contains(tmp, relatedUrls[i])) {
tmp.length += 1;
tmp[tmp.length - 1] = relatedUrls[i];
tmp2.length += 1;
tmp2[tmp2.length - 1] = relatedTitles[i];
}
}
relatedTitles = tmp2;
relatedUrls = tmp;
}
function contains(a, e) {
for(var j = 0; j < a.length; j++) if (a[j]==e) return true;
return false;
}
function printRelatedLabels() {
var r = Math.floor((relatedTitles.length - 1) * Math.random());
var i = 0;
document.write('<ul>');
while (i < relatedTitles.length &amp;&amp; i < 20) {
document.write('<li><a href="' + relatedUrls[r] + '">' + relatedTitles[r] + '</a></li>');
if (r < relatedTitles.length - 1) {
r++;
} else {
r = 0;
}
i++;
}
document.write('</ul>');
}
//]]>
</script>


Step 2 : Check expand widgets and search for <b:loop values='data:post.labels' var='label'> , Now copy and paste the following code in blue between <b:loop values='data:post.labels' var='label'> and </b:loop>



<b:loop values='data:post.labels' var='label'>
<a expr:href='data:label.url' rel='tag'><data:label.name/></a><b:if cond='data:label.isLast != &quot;true&quot;'>,</b:if><b:if cond='data:blog.pageType == &quot;item&quot;'> <script expr:src='&quot;/feeds/posts/default/-/&quot; + data:label.name + &quot;?alt=json-in-script&amp;callback=related_results_labels&amp;max-results=5&quot;' type='text/javascript'/> </b:if> </b:loop>


customize the text in green to show as many links you want.

Step 3 : Now paste the following script the code just below <p><data:post.body/></p> .

code :

<script type='text/javascript'> removeRelatedDuplicates(); printRelatedLabels(); </script>



Thats it , now look at the page , it will look like this



You can see there is no styling , I wanted to make it look beautiful . So i made the following changes . Both step 1 and 2 are same , just in step three make some changes .

<b:if cond='data:blog.pageType == "item"'>
&lt;div id=&quot;related-posts&quot;&gt;
<h2>Other Recommended Posts</h2>


<script type='text/javascript'>
removeRelatedDuplicates(); printRelatedLabels(); </script>

</div></b:if>



now its time to add css part for this div section .



/*-- (Related posts widget -below posts) --*/
#related-posts {
float:center;
width:450px;
height:100%;
min-height:100%;
padding-top:5px;
padding-left:5px;
}

#related-posts .widget{
padding-left:6px;
margin-bottom:10px;
background-color:#fff
}

#related-posts .widget h2, #related-posts h2{
font-size: 1.6em;
font-weight: bold;
color: #0000FF;

font-family: Georgia, "Times New Roman", Times, serif;
margin-bottom: 0.75em;
margin-top: 0em;
padding-top: 0em;

}

#related-posts a{
color:#A10000;
}

#related-posts a:hover{
color:#A10000
}

#related-posts ul{
list-style-type:none;
margin:0 0 0px 0;
padding:0px;
text-decoration:bold;
font-size:15px;
text-color:#000000
}

#related-posts ul li{
background:transparent url(http://img152.imageshack.us/img152/3756/bulletzc2.gif) no-repeat ;
display:block;
list-style-type:none;
margin-bottom: 13px;

padding-left: 30px;
padding-top:0px;}


Now look at the page again ,


You can even customize the link color , arrow style , font-size , etc I hope you liked this related posts widget , see you soon with another widget or hack.

Social Bookmarking widget for blogger

On all Blogger's mind there will be just one question , How to drive traffic to our blog ?
We need to have quality content and backlinks to drive traffic to our blog and occupy first place on google search engines. First one Quality content is in hands of the admin who writes the post. he need to put the main keywords for the article in the post . But for the second one , the author can't just submit each and every post to bookmarking sites . Its very time consuming. But It's a very effective way of driving traffic to our blog. We need a widget for blogger so that visitors/readers can submit our article to bookmarking sites.

This Social bookmarking widget contains Post Link submission to major bookmarking sites like Digg , technorati , Blinklist , Del.icio.us , Furl , Stumble Upon , Reddit , yahoo , Simpy and Spurl .
I hope those are the most famous social bookmarking sites with higher pagerank and traffic .

Just Follow this simple steps to add social bookmarking sites widget to blogger :

Step 1 :

Log in to your Blogger Account and navigate to Layout Section. Then go to Edit HTML Page and check the Expand Widgets box.

Step 2 :

Now search this code : <p><data:post.body/></p>


Step 3 :

Copy and paste the below code immediately below red text.


<p><data:post.body/></p>
<!-- Start of social bookmarks. Check http://bloggeraccessories.blogspot.com/ for updates -->
<span class='post-author' style='font-size: 95%;'><br/>
Add Post To: |
<a expr:href='&quot;http://digg.com/submit?phase=2&amp;url=&quot; + data:post.url + &quot;&amp;title=&quot; + data:post.title' target='_blank'>Digg</a>|
<a expr:href='&quot;http://technorati.com/faves?add=&quot; + data:post.url' target='_blank'>Technorati</a>|
<a expr:href='&quot;http://tipd.com/submit.php?url=&quot; + data:post.url + &quot;&amp;title=&quot; + data:post.title' target='_blank'>Tip&#39;d</a>|
<a expr:href='&quot;http://del.icio.us/post?url=&quot; + data:post.url + &quot;&amp;title=&quot; + data:post.title' target='_blank'>del.icio.us</a>|
<a expr:href='&quot;http://www.stumbleupon.com/submit?url=&quot; + data:post.url + &quot;&amp;title=&quot; + data:post.title' target='_blank'>Stumbleupon</a>|
<a expr:href='&quot;http://reddit.com/submit?url=&quot; + data:post.url + &quot;&amp;title=&quot; + data:post.title' target='_blank'>Reddit</a>|
<a expr:href='&quot;http://www.blinklist.com/index.php?Action=Blink/addblink.php&amp;Url=&quot; + data:post.url + &quot;&amp;Title=&quot; + data:post.title' target='_blank'>BlinkList</a>|
<a expr:href='&quot;http://www.furl.net/storeIt.jsp?t=&quot; + data:post.title + &quot;&amp;u=&quot; + data:post.url' target='_blank'>Furl</a>|
<a expr:href='&quot;http://www.spurl.net/spurl.php?url=&quot; + data:post.url + &quot;&amp;title=&quot; + data:post.title' target='_blank'>Spurl</a>|
<a expr:href='&quot;http://myweb2.search.yahoo.com/myresults/bookmarklet?t=&quot; + data:post.title + &quot;&amp;u=&quot; + data:post.url' target='_blank'>Yahoo</a>|
<a expr:href='&quot;http://www.simpy.com/simpy/LinkAdd.do?href=&quot; + data:post.url + &quot;&amp;title=&quot; + data:post.title' target='_blank'>Simpy</a>|
<br/></span>
<!-- End of social bookmarks -->


that's it Now you can see social Bookmarking sites widget to your blog.

 Social bookmarking sites like Digg , Stumble Upon , technorati , Spurl , del.icio.us , furl , Blinklist , etc Link Submission Widget for Blogger

I hope you like this widget , see you soon with a new hack . please tell us your suggestion about this widget.

Custom Search
Web Analytics