We are transitioning over to a new forum platform. Please post new issues there. Existing threads will be dealt with here unless you choose to move them over. Visit the new forum

Forum

Thread tagged as: Problem, Runway, Blog

Search functionality within categories & blog post blocks

I'm having trouble getting Perch search to spread it wings over the full spectrum of content on a Runway site I'm building; does search extend to custom fields within category templates and blog posts that are comprised of blocks?

The site contains a collection of products displayed on product sub-category pages, which are in turn grouped and displayed on the parent / top level product category pages, but none of the category content, titles etc are returned in the search results. Is there some way to include all category fields in the search results?

Also no results are returned from blog unless the keyword is in the post title - I've dropped keywords into both the excerpts and the main post content (comprised of blocks) but nothing. Any ideas?

Brief diagnostics below... Thankin y'all!

Perch Runway: 2.8.31, PHP: 5.6.10, MySQL: mysqlnd 5.0.11-dev - 20120503 - $Id: 3c688b6bbc30d36af3ac34fdd4b7b5b787fe5555 $, with PDO
Server OS: Darwin, apache2handler
Installed apps: content (2.8.31), assets (2.8.31), categories (2.8.31), perch_blog (5.0), perch_forms (1.8.3), collection_1 (2.8.31)
App runtimes: <?php $apps_list = array( 'content', 'categories', 'perch_blog', 'perch_forms', );
PERCH_LOGINPATH: /perch
PERCH_PATH: /Users/adam/Sites/kellswholemeal.ie/dev/perch
PERCH_CORE: /Users/adam/Sites/kellswholemeal.ie/dev/perch/core
PERCH_RESFILEPATH: /Users/adam/Sites/kellswholemeal.ie/dev/perch/resources
Image manipulation: GD
PHP limits: Max upload 32M, Max POST 32M, Memory: 128M, Total max file upload: 32M
F1: 2edba60ed1f613d6dd804feb202456a2
Resource folder writeable: Yes
HTTP_HOST: kellswholemeal.dev
DOCUMENT_ROOT: /Users/adam/Sites/kellswholemeal.ie/dev
REQUEST_URI: /perch/core/settings/diagnostics/
SCRIPT_NAME: /perch/core/settings/diagnostics/index.php
Adam Green

Adam Green 0 points

  • 3 years ago
Drew McLellan

Drew McLellan 2638 points
Perch Support

Categories doesn't have its own search handler - the requirement to treat categories as content you might search for hasn't arisen thus far.

Are you using the main blog post field at all, or is it all blocks?

Thanks Drew. Can I log adding a search handler to categories as a feature request? The power of Runway for me thus far has been the flexibility to build larger sites which categorise content within collections (articles, products and so forth) - I'm surprised this has arisen before!

Yes the main blog post field (id of postDescHTML) has been replaced by blocks in the post.html template. Would it help if I changed the ids of textarea & text fields within the blocks to postDescHTML? I'm guessing do so will lose all the content?

Drew McLellan

Drew McLellan 2638 points
Perch Support

At the moment, Blog is only searching the title, excerpt and main postDescHTML field. Blocks content doesn't get stored in those, so at the moment it's not being searched.

I'll log a bug and we'll see if we can get that addressed.

Thanks Drew, that would be great! I'm getting search results for content within blocks on normal pages, i.e. the main content app, so hopefully it's not too big a deal to extend this to blog ;)

I'm not getting any results from the excerpt either, only from the title (& tags). Are you sure the excerpt is being searched?

Drew McLellan

Drew McLellan 2638 points
Perch Support

Sorry, I meant tags rather than excerpt.