Showing posts with label templates. Show all posts
Showing posts with label templates. Show all posts

Tuesday, June 12, 2007

TypoXP : XML Template for Blogger

When it comes to free blog templates, I tend to yawn. Doesn't matter if it is a template for Blogger or a WordPress theme. They mostly are rehashed base versions and if you seen one ... you seen them all.


TypoXP template for Blogger screenshot
Every now and then, however, a template does catch my eye. Not so much the look of it, but the ingenuity I can see beneath it all. Such is the case for Ustadz's WordPress theme knock-off of Sunaryo Hadi's TypoXP 2.0. He has created a truely unique Blogger template that is not only astonishing to view, but has many add-on features that are easy to install.


TypoXP Blogger Add-on Features:

  • Expandable post summaries
  • Author Comment Highlight
  • TypoXP Sidebar Title Icon Set
  • Label (Tags) Cloud Widget
  • Archive Calendar Widget
  • Recent Posts Widget
  • Recent Comments Widget
  • Search Widget

Demo & Download Template



Technorati Tags: , , , , , , , , , ,

Friday, June 8, 2007

New Custom Search Engine for Blogspot Hacks, Tips & Templates

I am announcing a custom Blogspot Search Engine designed to provide you with the most relevant results for Blogspot tips, hacks, templates, tutorials and much more. The Search Engine folds the contents of 30+ popular hack and template sites in with natural Google results. The outcome produces one of the easiest methods for finding the answers that you need quickly.

Refinement labels are added to drill down into a variety of topics or site types. Pick the results that you want to see, without all of that fluff in the middle.

Try these example queries which are popular in forums and groups right now:

Help me refine this Search Engine by leaving constructive criticism in the comments below. I will entertain any suggestion.

Are you a Blogspot tip, tutorial or template site? Chances are you may already be included in this Search Engine already. If you feel that you are not, leave your sitename and Url below and I will check into it and add if appropriate.

I will add sites that only partially deal with Blogspot as well. If you have something to offer, holler away below.



Technorati Tags: , , , , , , ,

Sunday, June 3, 2007

Remove NoFollow from Classic FTP Blogger



Blogger Style:



Working with:





Blogger by default, and other blogging software such as WordPress, automatically adds the "nofollow" microformat extension to all links from user generated content. User generated content is defined as comments or external sources such as linkbacks and trackbacks.

I follow, do follow, no nofollowI support the people of the blogging community who have chosen to remove NoFollow for blog comments and linkbacks/trackbacks. If you are reading this right now, you too are probably thinking about joining us yourself. It would be a good move, read on to find out why.

If you are using the New Blogger Layout style on Blogspot, then you will need to use the Remove Nofollow from Blogger Layouts tutorial instead. This tutorial is for Classic FTP Blogger pages only.

Before We Begin


This removal procedure applies to the Classic FTP Blogger only. It is impossible, at this time, to remove NoFollow from Classic Blogger templates that are hosted at Blogspot. This is due to the fact that those templates use the variable <$BlogCommentAuthor$> which encapsulates the anchor link around linking text. Outside of petitioning Blogger to allow us the option for using "NoFollow", there is nothing that can be done.

This article also assumes that you have enabled your Html pages to process PHP script. If you have not done so already, visit the Parsing Html as PHP article before proceeding.

Nofollow Removal Process


The process to remove NoFollow is two-pronged and involves working with your template at Blogger and FTP access to upload a small PHP script.

We will first create an includable PHP script and FTP that to your server. The PHP script will do the actual work of stripping the rel="nofollow" attribute from your links.

In order for your the script to be processed, we will be revising your template to insert a few PHP directives. Also, we will isolate the portion of your code where the <$BlogCommentAuthor$> variable appears in your comments area and capture that variable into one that is recognizable by PHP.

Let's get started.

Creating the PHP Script to Remove NoFollow


I created an includable PHP file named pfblogger_functions.php. Inside of this file is a function named strip_nofollow(). There is another function in the file and more will be added as time progresses. All you need to concern yourself with is just the one function for right now.

Open up the blogger functions script in your browser. Using your favorite Html editor or Notepad, create a new file. Copy and paste the text from your browser screen into the new file, and save it with a name of pfblogger_functions.php

Upload the new PHP file via FTP to your server. I suggest uploading it into your "includes" directory if you have one. If not, then create a new directory on your server with the name of "includes". It keeps things neater this way.

Now that you have your PHP file installed, let's get on to the fun part!

Hacking PHP into your Blogger template


This portion of the tutorial may look a little daunting, but it really isn't. Just take your time and doublecheck your work.

Warning: Before beginning this procedure -- backup your template.

Navigate through your Blogger dashboard to Template > Edit Html

At the very beginning of your template, insert the following code:

<?php 

define('IN_PFBLOGGER', true);

<MainPage>
$site_rootpath = "../";
</MainPage>

<ArchivePage>
$site_rootpath = "../../";
</ArchivePage>

<ItemPage>
$site_rootpath = "../../../";
</ItemPage>

include ( $site_rootpath . "includes/pfblogger_functions.php" );

?>

Everything between the <$php ... $> markers will be run through the PHP interpreter on your server. The define statement at the beginning is for hacking security.

The rest of the code uses Blogger Conditional Tags to establish the actual path to your domain root and stores that in a variable. That variable is used with the path to your include file. If the your path to the function file is different, revise this portion of the code accordingly.

We have now properly included our function file, now let's proceed to the good part.

With your template do the following:
Find:
<$BlogCommentAuthor$>

and replace with:
<?php strip_nofollow( '<$BlogCommentAuthor$>' ) ?>

Find:
<$BlogCommentBody$>

and replace with:
<?php strip_nofollow( "<$BlogCommentBody$>" ) ?>



UPDATE: The code that acted on the comment body worked fine until somebody used a 'double quote' in their comment. This was due to the fact that I enclosed the variable <$BlogCommentBody$> with double quotes and it broke the code. I am working on a fix. If you have installed this hack, then revert this portion of the code back the way it was.

Save Template Changes, but do not replish just yet. We want to test that everything went as planned first.

Navigate to Posting > Create and enter a Test Post. Publish the post and view your blog in your browser.

Enter a comment for the post. Go back to view the post and verify that your Comment Author link is now free of the NoFollow attribute. You can verify this by several means -- one is View > Page Source from your browser menu. If you are using Firefox, there are extensions and other menu options for viewing/identifying links that have Nofollow attributes.

One last step


In order for this change to have any effect, you will have to republish your entire blog. This will rewrite all of the Main, Item and Archive pages with your new code. If your blog is large, a few hundred posts or more, this could take quite a while to process.

If you choose to delay republishing, any new comments made to your posts (existing posts included) will have the NoFollow removed from now on.


Optional NoFollow Recommendations


Now that you are a card carrying member of the Anti-NoFollow community, would you like to hook up with other blogs that share this belief? Then join us over at BUMPzee in the No Nofollow I Follow | DoFollow community.

This NoFollow community is headed up by Andy Beard and is growing everyday. The response has been phenomenol. With hundreds of participating blogs, odds are you will link up with many blogs who share in your particular interests.

Monday, May 28, 2007

Leveraging Conditional Tags in Blogger Templates

Blogger Style:
Working with:
If you have worked with Blogger templates for any length of time, then you are aware of what a Tag is and how it can insert information into your Blog at the exact location where the Tag appears. There are Tags for just about everything you can think of -- but what if you do not want certain types of information to appear on your Post Item page or an Archive page?

There are a second set of Blogger template tags known as Conditional Tags which can allow you to specify what information to display under certain conditions. The Conditional Tags are dependant upon the page type you are viewing -- those types are the Main Page, Archive Page and Item Page. A fourth Conditional Tag is an "OR" combination of the Main/Archive pages.
<MainPage>
... show this on Main page only
</MainPage>

<ArchivePage>
... show this on Archive page only
</ArchivePage>

<ItemPage>
... show this on Item page only
</ItemPage>

<MainOrArchivePage>
... show this on Main or Archive page only
</MainOrArchivePage>

You can use any Conditional Tag more than once in your template. Mix and match them wherever you want to.

Practical Uses for Conditional Tags


Let's say that you want to display a short introduction of what your blog is about on your Main Page before your Posts start to be displayed.
<MainPage>
<h1>The Widget Factory Blog</h1>
<p>Hello and welcome to the Widget Factory,
a world of widget news, reviews and fun!</p>
</MainPage>

The introduction will not appear on any of your Item or Archive pages.

If you are listing your Recent Posts in the sidebar of your blog, then having them on your Main Page is a little redundant. Also, the list is of no real value on your Archive pages. Let's display the list on your Item Pages only.
<ItemPage>
<h3>Latest Entries</h3>
<ul>
<BloggerPreviousItems>
<li><a href="<$BlogItemPermalinkURL$>">
<$BlogPreviousItemTitle$></a></li>
</BloggerPreviousItems>
</ul>
</ItemPage>

Conditional Tags work in the <head> section as well. For example, take this following code snippet which alters the your Page Title.

Normally an Item Page will have a Title in the form of "Site Name - Post Title" which comes from the Template Tag <$BlogPageTitle$>. We can workaround this by using Conditional Tags.
In the <head> section, find this:
<title><$BlogPageTitle$></title>

Replace with this:
<MainOrArchivePage>
<title>Your Sitename - Site Description</title>
</MainOrArchivePage>

<ItemPage>
<title>
<$BlogItemTitle$> - Your Sitename</title>
</title>
</ItemPage>

As you can see, there are many uses for Conditional Tags. Try using this method for displaying your Blogroll on your Main Page only or putting a short description of your blog in the Item Pages only. You are only limited by your imagination.

Thursday, May 17, 2007

Removing NoFollow from Blogger styled layouts

I follow, do follow, no nofollowBlogger by default, and other blogging software such as WordPress, automatically adds the "nofollow" microformat extension to all links from user generated content. User generated content is defined as comments or external sources such as linkbacks and trackbacks.

I support the people of the blogging community who have chosen to remove NoFollow for blog comments and linkbacks/trackbacks. If you are reading this right now, you too are probably thinking about joining us yourself. It would be a good move, read on to find out why.

Before we begin


First, this removal procedure applies to the New Blogger styled layout. It is impossible, at this time, to remove NoFollow from Classic styled Blogger templates. This is due to the fact that those templates use the variable {$CommentAuthorName$} which encapsulates the anchor link around linking text. I am working on getting around this, because I have another blog using this style.

There are a number of tip sites out there explaining how to accomplish the removal of NoFollow -- and every one of them did not get it completely right. I have not found one yet who has addressed the issue of backlinks which also have the NoFollow extension added to it.

I have seen numerous comments left by readers of the tutorials stating that they could not find the NoFollow referenced in their layout template. Two reasons for this. They either are using the Classic template or more probably it is the same problem I encountered when I first went looking for it. I will explain why below, and it will be very clear as to why they missed it too.

Properly removing NoFollow from the template


Warning: Before beginning this procedure -- backup your template
.

Login to your dashboard and click on the Layout Link. If you are already managing your blog, then click on the Template Tab. Confused, don't be -- there really is a reason for that.

Click on the Edit Html Sub-tab for Templates.

Here is the important part. On the upper right of the template edit area, there is a checkbox labeled Expand Widgets. Make sure it is checked.


[ Click for larger version ]


Every tutorial I have read failed to mention the checkbox. The items we will be deleting are inside of sections, which in turn are inside of a widget. If the widget is collapsed, then we will not be able to see anything inside of the widget.

Now do a search for nofollow in your expanded template. You can either use your browser menu by clicking on Edit>Find in page or via the keyboard Ctrl-F. When the dialog box comes up, type in nofollow, and enter.

You should come across a line of code that looks something like this:
          <dt class='comment-author' expr:id='"comment-" + data:comment.id'>
<a expr:name='"comment-" + data:comment.id'/>
<b:if cond='data:comment.authorUrl'>
<a expr:href='data:comment.authorUrl' rel='nofollow'><data:comment.author/></a>
<b:else/>
<data:comment.author/>
</b:if>
<data:commentPostedByMsg/>
</dt>

Delete the portion of the code that says rel='nofollow' and Save Your Template.

Optionally remove Nofollow from backlinks


By doing another search for nofollow in your expanded template, you will find another one for your backlinks. You can choose to delete this as outlined above -- or not.

If you do delete the reference, do at your own risk. Backlinks are outside of your control and cannot be moderated. You can turn them off altogether via your Settings>Comments Tab. It is up to you.