Perch Shop Search Error

  • I've managed to get Perch shop search working using code I the following found in the forum.

    PHP
    1. <?php perch_search_form(); ?>
    2. <?php $query = perch_get('q'); perch_content_search($query, array( 'count'=>12, 'apps' => ['PerchShop'], )); ?>

    There is a PHP error notice above the search results:

    Code
    1. 'Notice: Undefined index: description in /pathto/site-folder/kpanel/addons/apps/perch_shop/lib/PerchShop_SearchHandler.class.php on line 69' 

    I've not been near this file, and have actually replaced the whole lib directory with a fresh download just in case but the error persists.


    Can anyone help identify what is causing the problem please?

  • I believe everything is standard apart from the blocks editor I have added to the end.

  • Hello Byron, I think it's all related to some malformed variants. I encountered another issue where search was matching the first variant as well as the product itself.


    I deleted the first variant from the variants tab and generated new variants - this has fixed this issue.