|
Some people just like to design. And sometimes, as I know I have, they like to put their content on different designs, and have it be the same content. As you may know, javascript can solve pretty much any problem if you want it to. here's how to solve this one:
<script language="JavaScript">
function shfrontScript(author,nickname,email,website,date,id,archive) {
document.write("");
}
function shbackScript(author,nickname,email,website,date,id,archive) {
document.write("<br><a href='" + archive + "'>linkit.</a><font color='D9D9D9'>" + date + "</font><BR><BR>")
}
</script>
<script language='Javascript'>
var blogTitle="<$BlogTitle$>"
var blogDiscription="<$BlogDescription$>"
</script>
<Blogger>
<script language='Javascript'>
start = new shfrontScript("<$BlogItemAuthor$>" , "<$BlogItemAuthorNickname$>" , "<$BlogItemAuthorEmail$>" , "<$BlogItemAuthorURL$>" , "<$BlogItemDateTime$>" , "<$BlogItemNumber$>" , "<$BlogItemArchiveFileName$>#<$BlogItemNumber$>")
</script>
<a name="<$BlogItemNumber$>"></a>
<$BlogItemBody$>
<script language='Javascript'>
end = new shbackScript("<$BlogItemAuthor$>" , "<$BlogItemAuthorNickname$>" , "<$BlogItemAuthorEmail$>" , "<$BlogItemAuthorURL$>" , "<$BlogItemDateTime$>" , "<$BlogItemNumber$>" , "<$BlogItemArchiveFileName$>#<$BlogItemNumber$>")
</script>
</Blogger>
<a href='http://www.blogger.com/'>powered by blogger</a>
confused? don't worry, I'lll break most of it down for you.
line 1:
<script language="JavaScript">
This line states the beginning of a javascript section. we have a whole bunch of those in this, so I'll only explain it this once.
line 2:
function shfrontScript(author,nickname,email,website,date,id,archive) {
this line tells the browser that it is the function shfrontscript and it has all this stuff in it...
line 3:
document.write("<br><a href='" + archive + "'>linkit.</a><font color='D9D9D9'>" + date + "</font><BR><BR>")
This is where you would put something that goes in front of the blog entry. I'll explain how you would do this a few lines down.
line 4:
}
End the front script.
line 5:
function shbackScript(author,nickname,email,website,date,id,archive) {
this line tells the browser that it is the function shbackscript and it has all this stuff in it...
line 6:
document.write("<br><a href='" + archive + "'>linkit.</a><font color='D9D9D9'>" + date + "</font><BR><BR>")
Okay, this is where you'd be putting all formatting for the design. basically, you have a bunch of variables you can place anywhere you want:
author
nickname
email
website
date
id
archive
and that you apply using a " + variablename + " in the middle of your code. Your code goes between the document.write(" and the ");, and you cannot use double quotation marks(like "). unless it is to add a variable. If you need more on that, go to webmonkey and look for a tutorial on JavaScript.
line 7: }
and it ends the shbackscript function.
line 8:
</script>
And we end the javascript. All the lines that I just explained go into you're design file. In that design file, you'll have the design, the above eight lines, and then an include of some sort(php, ssi, or something else. Look to blogger on that.) that points to your blogger file, then the end part of the design.
line 9-16:
<script language='Javascript'>
var blogTitle="<$BlogTitle$>"
var blogDiscription="<$BlogDescription$>"
</script>
<Blogger>
<script language='Javascript'>
start = new shfrontScript("<$BlogItemAuthor$>" , "<$BlogItemAuthorNickname$>" , "<$BlogItemAuthorEmail$>" , "<$BlogItemAuthorURL$>" , "<$BlogItemDateTime$>" , "<$BlogItemNumber$>" , "<$BlogItemArchiveFileName$>#<$BlogItemNumber$>")
</script>
<a name="<$BlogItemNumber$>"></a>
<$BlogItemBody$>
<script language='Javascript'>
end = new shbackScript("<$BlogItemAuthor$>" , "<$BlogItemAuthorNickname$>" , "<$BlogItemAuthorEmail$>" , "<$BlogItemAuthorURL$>" , "<$BlogItemDateTime$>" , "<$BlogItemNumber$>" , "<$BlogItemArchiveFileName$>#<$BlogItemNumber$>")
</script>
</Blogger>
<a href='http://www.blogger.com/'>powered by blogger</a>
All this, you copy and paste into your blogger templates.
Enjoy, and have fun with this. I hope I wrote it understandably, and that It was helpful.
|