help to better help you:

Please: add always Joomla / JEM version and details to your posts, so we can try to reproduce your issue!

Anybody help me?

Anybody help me?

6 years 2 months ago
#25319
I wish to hide the events' table if there is no event and show only the category description.

So in my template override I want to create code such as
if(!empty(XXX)) // show table
else // show somethin else

So I need the name of that variable replacing XXX.
Thanks!

Please Log in or Create an account to join the conversation.

Re: Anybody help me?

6 years 2 months ago - 6 years 2 months ago
#25322
By default, if there are no events, the table is shown with one entry <Currently no events>.
But as I understood you want to hide the complete table?
Go to Joomlaroot\components\com_jem\common\views\tmpl\default_events_table.php at line 101 there you find the variable ($this->noevents == 1). Change that to the opposite (I think == 0 should be good) and then put this line before the form of the eventtable (line 77) in the file Joomlaroot\components\com_jem\views\category\tmpl\default.php and the belonging "endif" after the form.

PS: Next time it would be good if you call the thread like your question: "Hiding event table if empty". It helps other users that want to do the same.
Last edit: 6 years 2 months ago by Egnarts.

Please Log in or Create an account to join the conversation.

Time to create page: 0.483 seconds