More than one Single Page type?

Permalink
I am using Chad's excellent ProBlog addon but my client wants to see the filtered results on separate themed pages. At the moment the results render on the single page type.

So if they click on the St Johns tag then all the related blogs appear on a page that has a St Johns graphic. St Davids see a St Davids graphic etc...

Is this even possible?

I am not a hard core programmer so it would need to be a fairly straightforward solution.

thanks

trixiemay
 
RadiantWeb replied on at Permalink Reply
RadiantWeb
1) add "$this->set('category',$category);" after line 40 in /packages/problog/controllers/blogsearch.php

2) add this before line 14 of /packages/problog/single_pages/blogsearch.php

if($category){
     $a = new GlobalArea($category.'_banner');
     $a->display($c);
}


3) go to a blog post, click on the category to go to that page. this ensures that the per-category global area registers. you only need to do this once.

4) now that the global area has registered, you can go to your dashboard -> stacks area and edit the [category]_banner stack and add images/sliders as desired.


This method will only work if you have '/blogsearch' set in your problog settings as the predefined search results page.

Hope this helps.

ChadStrat
RadiantWeb replied on at Permalink Best Answer Reply
RadiantWeb
this would be for categories, for tags add the following after line 44 (or 45 if you have added the category code) of the blogsearch controller:

$this->set('tag',$tag);


and the same as categories, place this code above line 14 of the blogsearch single_page:

if($tag){
     $a = new GlobalArea($tag.'_banner');
     $a->display($c);
}
trixiemay replied on at Permalink Reply
trixiemay
I get this error:

Parse error: syntax error, unexpected '[' in /home/rdpcorg/public_html/concrete5.6.1.2/packages/problog/controllers/blogsearch.php on line 45
trixiemay replied on at Permalink Reply 2 Attachments
trixiemay
I am still having problems.

The code is showing up on the results page. See attachments.

thanks
trixiemay replied on at Permalink Reply
trixiemay
Thanks for the rapid reply.
Great.
RadiantWeb replied on at Permalink Reply
RadiantWeb
you need to add php tags before and after that code. <?php & ?>

ChadStrat