Custom Theme; PostView.aspx: How to to differentiate between showing full post or the sumary in the list

Topics: Themes
Mar 21, 2010 at 3:23 PM

Hi there,

I have my own, custom BlugEngine.NET theme in place and it works quite nice. Now I try to fine-tune / clean the clutter all over the blog to improve the user-experience. Therefore I like to clean the list of blog entries eg. for a whole category or for the blogs mainpage. I like to remove the edit, tags, categories etc. from the footer of each view and show it only when the user "zooms" to blog entry so only one blog entry gets shown. To implement this I need to to differentiate in PostView.aspx whether it is used/rendered for a whole list of blogentries or just one single entry in full size. Is there a way to do this?

Any help or tip would be great!

Cheers,
Marc

Coordinator
Mar 21, 2010 at 8:43 PM
Edited Mar 21, 2010 at 8:44 PM

You can use the ServingLocation property withing PostView to display different content if it's the full post being shown versus the post being shown in the 'PostList' along with other posts.

In the App_Code\Extensions folder is the BreakPost extension which takes different actions based on ServingLocation. You can see how it's used within BreakPost. The same ServingLocation property can be used within PostView.

Mar 22, 2010 at 8:09 AM

Cool, thanks. I will try that!

Nov 27, 2010 at 11:03 AM

Just got back to this and tried to implement it but my problem is that I can not find any "ServingLocation" property in PostView.aspx. Where can I find ServingLocation from the PostView.aspx or it code-behind file?

Thx, Marc

Nov 27, 2010 at 11:05 AM

No worries - just found it with R# :-)

It's a property called "Location".