I am using the jCarousel Views module; I want to hide the view when the number of items are not greater than 3. How do I do it?
1 Answer
You can use JCarousel views as block display and then set a visibility condition by executing custom php condition test code (This will require to enable PHP Filter module)
$result = views_get_view_result('view-name', 'display_id');
Then you can analyze the $result
and count the number of results.
Most probably you need to do ....
if(count($result)<3)
return FALSE; //Would not let to show that block
else
return TRUE; // Would let to show