Build Your Own Arcade Controls Forum

Main => Everything Else => Topic started by: hulkster on May 15, 2009, 10:11:51 am

Title: blogspot xml coding question...
Post by: hulkster on May 15, 2009, 10:11:51 am
for those of you with blogs, does anyone know how to make ones posts "abbreviated" or "previewed".  like if you look at sites kotaku.com and gizmodo.com, you have to click the link on the article to read the full thing.  i know i can just create short descriptions as my "post" and then make a link to a full page, but on blogspot, you cant really do that.  i know some blogs that ive read allow you to click "read more" and it kinda extends the article. 

my main goal here is to not have long articles all the way down the front page.  id like to have little articles with links to the full thing.  any suggestions?
Title: Re: blogspot question...
Post by: hulkster on May 15, 2009, 10:31:34 am
okay i just found out what i needed to search for in google and that's "read more".  so i did that and it returned a bunch of results, which is great (like this one http://help.blogger.com/bin/answer.py?hl=en&answer=42215)

HOWEVER, the problem with this hack is that now whenever i post i am required to use the blogger posting page to do it, plus i have to post in html format.  what im wanting is the above hack to work with Windows Live Writer or some other blogging software. 

and if anyone cares....here is what I have in my xml template file in blogger (the section that needs to be edited anyway):

<b:if cond='data:blog.pageType == &quot;item&quot;'>
<style>#fullpost{display:inline;}</style>
<p><data:post.body/></p>
<b:else/>
<style>#fullpost{display:none;}</style>
<p><data:post.body/></p>

and according to the link i provided above, it should be edited to look like this:

<b:if cond='data:blog.pageType == &quot;item&quot;'>
<style>#fullpost{display:inline;}

<b:if cond='data:blog.pageType == "item"'>
   span.fullpost {display:inline;}
<b:else/>
   span.fullpost {display:none;}
</b:if>


</style>
<p><data:post.body/></p>
<b:else/>
<style>#fullpost{display:none;}</style>
<p><data:post.body/></p>

and then the documentation says put the next batch of code "Add the following code to your template, somewhere after the <$BlogItemBody$> or <data:post.body/> tag:"  so thats what i did:


<b:if cond='data:blog.pageType == &quot;item&quot;'>
<style>#fullpost{display:inline;}

<b:if cond='data:blog.pageType == "item"'>
   span.fullpost {display:inline;}
<b:else/>
   span.fullpost {display:none;}
</b:if>


</style>
<p><data:post.body/></p>
<b:else/>
<style>#fullpost{display:none;}</style>
<p><data:post.body/></p>
<b:if cond='data:blog.pageType != "item"'><br />
   <a expr:href='data:post.url'>Read more!</a>
</b:if>


so im obviously doing something wrong as its not working.  help!
Title: Re: blogspot xml coding question...
Post by: hulkster on May 15, 2009, 11:42:36 am
and here is the template i'm trying to manipulate http://btemplates.com/2009/04/21/template-blue/

its already got the "Read More..." things built in to it, but i cant figure out how to get them to work since i dont know xml or anything.
Title: Re: blogspot xml coding question...
Post by: hulkster on May 15, 2009, 01:58:47 pm
anyone?