Cpup Posted October 11, 2020 Share Posted October 11, 2020 Hi, I'm using the following: {if $VAL_SELF|strpos:'search.html'}<h5>Your search produced {$TOTAL_RESULTS} results...</h5>{/if} <h5>{$category.cat_name}</h5> To get search results. It's great, but doesn't capture 0 items found. I get: Your search produced results... Search results Is there a way of editing {$TOTAL_RESULTS} to include '0'? Link to comment Share on other sites More sharing options...
NiteFox Posted October 11, 2020 Share Posted October 11, 2020 You could use : {if $TOTAL_RESULTS} {$TOTAL_RESULTS} {else} 0 {/if} Link to comment Share on other sites More sharing options...
Cpup Posted October 11, 2020 Author Share Posted October 11, 2020 Thanks @NiteFoxthat worked! Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.