BACK TO 1GREENEYE

The following information can be found in The Complete Unofficial Blogger FAQ. For more help and info go there.

Templates - Complete guide to tags

Tags that work anywhere

<$BlogURL$>
Replaced with: The URL in the blog's Settings.
Usage: A good value for a "home" link, or the "back to current" link in an archive template, e.g.

<a href="<$BlogURL$>">home</a>

Can also be used as a base href, to make relative links work in both the main page and in archive pages in a separate directory.

<$BlogTitle$>
Replaced with: The Title in the blog's Settings.
Usage: The title in the page, e.g.

<h1><$BlogTitle$></h1>

and also in the title tag in the <head> section (which is displayed at the top of the browser window), e.g.

<title><$BlogTitle$></title>

<$BlogDescription$>
Replaced with: The Description in the blog's Settings.
Usage: A subhead in the header, or at the top of a sidebar, e.g.

<h2><$BlogDescription$></h2>

Note that some people will have a blank Description, in which case the published blog will have "<$BlogDescription$>-Value" in place of the description.

<$BlogArchiveFileName$>
Replaced with: The Archive Filename in the blog's Settings.
Usage: Either a link to the archive index page (for blogs with a separate index page), e.g.

<a href="<$BlogArchiveFileName$>">archives</a>

or the script tag that loads the archive links (for blogs that include links with Javascript), e.g.

<script type="text/javascript" src="<$BlogArchiveFileName$>"></script>

Note that Blogger doesn't know about the path to the archives (except when it is ftping), so if the archives aren't in the same directory as the main page, you need a path in front of <$BlogArchiveFileName$>, either http://www.example.com/archives/ or /archives/ starting with a slash and going from the server's root directory.

Tags that only have meaning between <Blogger> and </Blogger> in the main template

<BlogDateHeader>
<$BlogDateHeaderDate$>
</BlogDateHeader>

Replaced with: The date for a set of posts on one day, in the format specified in Date Header Format in the blog's Settings.
Usage: These three tags go together: either you use all three, or none. No other Blogger tag has meaning inside <BlogDateHeader> to </BlogDateHeader>, but you can use any HTML you like. This section only appears once per day, typically before the first post, no matter how many posts there are in that day. Along with producing the actual date header, <BlogDateHeader> can be used (together with <BlogDateFooter>) to group posts from a day together. For example, to put all the posts from one day in a table:

<BlogDateHeader>
<table>
<tr>
<td><$BlogDateHeaderDate$></td>
</tr>
<tr>
<td>
</BlogDateHeader>

Then, the <td>, <tr>, and <table> would be closed in the <BlogDateFooter>. More elegantly, using CSS:

<BlogDateHeader>
<div class="day">
<h3 class="date"><$BlogDateHeaderDate$></h3>
</BlogDateHeader>

<BlogDateFooter>
</BlogDateFooter>

Replaced with: No Blogger tags have meaning inside <BlogDateFooter>, only HTML.
Usage: Either as a separator between days, or to close HTML tags opened in <BlogDateHeader>. Just like <BlogDateHeader>, there will only be one <BlogDateFooter> per day, after all the posts for that day. For example, to close the table-per-day example above, use:

<BlogDateFooter>
</td>
</tr>
</table>
</BlogDateFooter>

or, to close the CSS version:

<BlogDateFooter>
</div>
</BlogDateFooter>

To separate days when you aren't grouping the posts in a table or div, use any HTML that suits you, e.g.:
<BlogDateFooter>
<br><br>
<hr>
<br><br>
</BlogDateFooter>

<$BlogItemBody$>
Replaced with: The text of the posts.
Usage: Because a post can contain any sort of HTML, including lists and tables, if you wrap a tag around <$BlogItemBody$> for formatting, it should be a block-level tag like

<div class="postbody"><$BlogItemBody$></div>

In any case, never, ever, use

<p><$BlogItemBody$></p>

because "Convert Line Breaks" changes a return on a blank line in a post into a <p>, your formatting will end after the first paragraph in a post, baffling your template user.

<$BlogItemAuthor$> or <$BlogItemAuthorNickname$>
Replaced with: The values in the profile for the user making the post.
Usage: Either directly, as text, e.g.

Posted by <$BlogItemAuthor$>

or inside a tag, e.g.

<a href="<$BlogItemAuthorURL"><$BlogItemAuthor$></a>

If you are designing a template for general use, like at BlogSkins.com, use <$BlogItemAuthor$>, because everyone has one of those, but for a template for your own use, use <$BlogItemAuthorNickname$> if you want a cutesy tag, so that you can leave your name in your profile as an actual name. That way when you post in the Blogger Discuss forum, your post will be identified by your name, which makes you seem reasonable, rather than by "Jumbalo's Giant Talking Penis", which will cut down on the number of replies you get.

<$BlogItemAuthorEmail$>
Replaced with: The email address in the profile for the user making the post.
Usage: Together with <$BlogItemAuthor$>, to make a mailto: link, e.g.

<a href="mailto:<$BlogItemAuthorEmail$>"><$BlogItemAuthor$></a>

<$BlogItemAuthorURL$>
Replaced with: The URL in the profile for the user making the post.
Usage: Rarely used, in team blogs, to make a link to the home page for the user making the post, e.g.

<a href="<$BlogItemAuthorURL$>"><$BlogItemAuthor$></a>

<$BlogItemDateTime$>
Replaced with: The date and/or time of the post, in the format specified in Timestamp Format in the Settings for the blog. By default, set to time only, but for a template that lists a date and time for each post, rather than using a <BlogDateHeader>, can be set to include the date as well (not a good idea in a BlogSkin, since it requires extra instructions).
Usage: Either used alone as text, e.g.

at <$BlogItemDateTime$>

or commonly used as the link text in a permalink, e.g.

<a href="<$BlogItemArchiveFileName$>#<$BlogItemNumber$>"><$BlogItemDateTime$></a>

<$BlogItemArchiveFileName$>
Replaced with: The filename for the archive file where the post appears.
Usage: in permalinks.

<$BlogItemNumber$>
Replaced with: The unique number for the post.
Usage: in permalinks, and as the target for the permalink.

Permalinks:
Several of the Blogger tags are used to build permalinks, which are the links for each post that lead to that post's permanent location in the archives. To make permalinks work, you need two sets of tags. Before the <$BlogItemBody$> tag, include

<a name="<$BlogItemNumber$>"></a>
(or <a id="post<$BlogItemNumber$>"></a> if you insist on XHTML)

Then, for the link itself, use

<a href="<$BlogItemArchiveFileName$>#<$BlogItemNumber$>"><$BlogItemDateTime$></a>
(or <a href="<$BlogItemArchiveFileName$>#post<$BlogItemNumber$>"><$BlogItemDateTime$></a> for XHTML)

Since it may not be obvious to everyone what the link is, even if you use "link" as the text rather than the post time, including title="Permanent link to this item in the archives" is a good idea.

Tags that only have meaning between <Blogger> and </Blogger> for Blogger Pro

<PostSubject>
<$BlogItemSubject$>
</PostSubject>

Replaced with: For posts with a title, everything between the <PostSubject> tags is included, with <$BlogItemSubject$> replaced by the title of the post. For posts without a title, nothing is included.
Usage: Format the title with any HTML you like, as long as you don't depend on it, since it won't be included when there is no title (don't open a tag in the title, intending to close it after the post). For example:

<PostSubject>
<h4 class="postTitle"><$BlogItemSubject$></h4>
</PostSubject>

Tags that only have meaning between <Blogger> and </Blogger> in the archive template

<$BlogArchiveLink$>
Replaced with: The filename for each archive page.
Usage: as the href for an archive link.

<$BlogArchiveName$>
Replaced with: The date for each archive page, in the format 03/10/2002 - 03/16/2002
Usage: as the link text for an archive link, e.g.

<a href="<$BlogArchiveLink$>"><$BlogArchiveName$></a>



BACK TO 1GREENEYE