If a category is empty is it possible to display the text 'No downloads available' (or similar).
Version 3.0.6
I seen this post viewtopic.php?f=31&t=27575 however there was no answer.
Currently when a user clicks on an empty category they are taken to that category however there is no text to display if empty.
Thanks.
Empty Category
- Jan
- Phoca Hero
- Posts: 48566
- Joined: 10 Nov 2007, 18:23
- Location: Czech Republic
- Contact:
Re: Empty Category
Hi, for now there is no such text (it was there but it was removed because most of users wanted to not display it here), so you need to set it directly in the output file:
components/com_phocadownload/views/category/tmpl/ ...
Jan
components/com_phocadownload/views/category/tmpl/ ...
Jan
If you find Phoca extensions useful, please support the project
-
- Phoca Newbie
- Posts: 2
- Joined: 29 Jun 2015, 10:10
Re: Empty Category
Thanks Jan,
Which part of the code should I ammend? The reason I need it is because of site offers Job Vacancies, and when there are none i'd like to do one of two things;
- display 'no files available'
- auto unpublish the category
The first one seems easiest. Otherwise visitors get confused as to whether there are vacancies or not.
Which part of the code should I ammend? The reason I need it is because of site offers Job Vacancies, and when there are none i'd like to do one of two things;
- display 'no files available'
- auto unpublish the category
The first one seems easiest. Otherwise visitors get confused as to whether there are vacancies or not.
- Jan
- Phoca Hero
- Posts: 48566
- Joined: 10 Nov 2007, 18:23
- Location: Czech Republic
- Contact:
Re: Empty Category
Hi, see: components\com_phocadownload\views\category\tmpl\default_files.php
You can add to the last line else condition:
FROM:
TO:
Jan
You can add to the last line else condition:
FROM:
Code: Select all
}
Code: Select all
} else {
echo "there is no file";
}
If you find Phoca extensions useful, please support the project