Hi Jan
I'm using this Gallery on a site - everything works as expected, but for one issue:
I can't sort categories in the backend. Whatever I select, nothing happens.
I'm talking about the sort function marked in red on the image (see link below).
[url]https://langnau.imaufbau.ch/images/phoc ... ANGES1.jpg[/url]
All Software is the latest Version and it's on PHP 7.2
Hope you can help
All the best
David
Category Sorting doesn't work
-
- Phoca Enthusiast
- Posts: 55
- Joined: 07 Dec 2007, 15:52
- Contact:
- Jan
- Phoca Hero
- Posts: 48402
- Joined: 10 Nov 2007, 18:23
- Location: Czech Republic
- Contact:
Re: Category Sorting doesn't work
Hi, when you enable javascript console to debug, do you get any javascript error on the site?
https://www.phoca.cz/documents/16-jooml ... -conflicts
EDIT: confirmed.
Please, try to open this file:
administrator\components\com_phocagallery\libraries\phocagallery\render\renderadminviews.php
and at the bottom, uncomment lines in the first function.
FROM:
TO:
and let me know if this works.
Thank you, Jan
https://www.phoca.cz/documents/16-jooml ... -conflicts
EDIT: confirmed.
Please, try to open this file:
administrator\components\com_phocagallery\libraries\phocagallery\render\renderadminviews.php
and at the bottom, uncomment lines in the first function.
FROM:
Code: Select all
public function jsJorderTable($listOrder) {
/*return '<script type="text/javascript">' . "\n"
.'Joomla.orderTable = function() {' . "\n"
.' table = document.getElementById("sortTable");' . "\n"
.' direction = document.getElementById("directionTable");' . "\n"
.' order = table.options[table.selectedIndex].value;' . "\n"
.' if (order != \''. $listOrder.'\') {' . "\n"
.' dirn = \'asc\';' . "\n"
.' } else {' . "\n"
.' dirn = direction.options[direction.selectedIndex].value;' . "\n"
.' }' . "\n"
.' Joomla.tableOrdering(order, dirn, \'\');' . "\n"
.'}' . "\n"
.'</script>' . "\n";
return "";*/
}
Code: Select all
public function jsJorderTable($listOrder) {
return '<script type="text/javascript">' . "\n"
.'Joomla.orderTable = function() {' . "\n"
.' table = document.getElementById("sortTable");' . "\n"
.' direction = document.getElementById("directionTable");' . "\n"
.' order = table.options[table.selectedIndex].value;' . "\n"
.' if (order != \''. $listOrder.'\') {' . "\n"
.' dirn = \'asc\';' . "\n"
.' } else {' . "\n"
.' dirn = direction.options[direction.selectedIndex].value;' . "\n"
.' }' . "\n"
.' Joomla.tableOrdering(order, dirn, \'\');' . "\n"
.'}' . "\n"
.'</script>' . "\n";
return "";
}
Thank you, Jan
If you find Phoca extensions useful, please support the project
-
- Phoca Enthusiast
- Posts: 55
- Joined: 07 Dec 2007, 15:52
- Contact:
Re: Category Sorting doesn't work
Thanks, Jan
Tried that, but all I got was;
An error has occurred.
0 syntax error, unexpected '*'
and a white page
Tried that, but all I got was;
An error has occurred.
0 syntax error, unexpected '*'
and a white page
- Jan
- Phoca Hero
- Posts: 48402
- Joined: 10 Nov 2007, 18:23
- Location: Czech Republic
- Contact:
Re: Category Sorting doesn't work
Hi, this is a php error which means that there is some syntax error. Did you copy the whole function. When you enable php error reporting, you wil get info about the file and row where the syntax error occurs.
Jan
Jan
If you find Phoca extensions useful, please support the project
-
- Phoca Enthusiast
- Posts: 55
- Joined: 07 Dec 2007, 15:52
- Contact:
Re: Category Sorting doesn't work
Hi again Jan
Thanks! I only removed the comment. This time I copied the whole section and replaced it: it works!
As always appreciate your help.
Best regards
David
Thanks! I only removed the comment. This time I copied the whole section and replaced it: it works!
As always appreciate your help.
Best regards
David
- Jan
- Phoca Hero
- Posts: 48402
- Joined: 10 Nov 2007, 18:23
- Location: Czech Republic
- Contact:
Re: Category Sorting doesn't work
Ok, great to hear it.
Jan
Jan
If you find Phoca extensions useful, please support the project
- Jan
- Phoca Hero
- Posts: 48402
- Joined: 10 Nov 2007, 18:23
- Location: Czech Republic
- Contact:
Re: Category Sorting doesn't work
If you find Phoca extensions useful, please support the project
-
- Phoca Enthusiast
- Posts: 55
- Joined: 07 Dec 2007, 15:52
- Contact:
Re: Category Sorting doesn't work
Terrific! Thanks Jan. Much appreciated.
Regards
David
Regards
David
- Jan
- Phoca Hero
- Posts: 48402
- Joined: 10 Nov 2007, 18:23
- Location: Czech Republic
- Contact:
Re: Category Sorting doesn't work
Ok
If you find Phoca extensions useful, please support the project