Print route error

Phoca Maps - displaying maps in Joomla! CMS
gelauff
Phoca Member
Phoca Member
Posts: 11
Joined: 19 Jan 2022, 16:50

Print route error

Post by gelauff »

Hi,
Using Phoca Maps 4.0.1 on Joomla 4.3.4.
The route print link throws a 404 error on the print page: syntax error, unexpected identifier "CMS", expecting "{"
Anybody has an idea, maybe even the solution?
Thanks in advance

Tags:
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48386
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Print route error

Post by Jan »

Hi, can you enable debug mode in your Joomla and paste here whole error message?

Thank you, Jan
If you find Phoca extensions useful, please support the project
gelauff
Phoca Member
Phoca Member
Posts: 11
Joined: 19 Jan 2022, 16:50

Re: Print route error

Post by gelauff »

Hi Jan,
This is the error message on the print page window.
Remember, it throws a 404 page, so no route details.

syntax error, unexpected identifier "CMS", expecting "{"

Call stack
# Function Location
1 () JROOT/templates/2023/component.php:13
2 Joomla\CMS\Document\HtmlDocument->_loadTemplate() JROOT/libraries/src/Document/HtmlDocument.php:796
3 Joomla\CMS\Document\HtmlDocument->_fetchTemplate() JROOT/libraries/src/Document/HtmlDocument.php:613
4 Joomla\CMS\Document\HtmlDocument->parse() JROOT/libraries/src/Application/CMSApplication.php:1012
5 Joomla\CMS\Application\CMSApplication->render() JROOT/libraries/src/Application/SiteApplication.php:724
6 Joomla\CMS\Application\SiteApplication->render() JROOT/libraries/src/Application/CMSApplication.php:298
7 Joomla\CMS\Application\CMSApplication->execute() JROOT/includes/app.php:61
8 require_once() JROOT/index.php:32
gelauff
Phoca Member
Phoca Member
Posts: 11
Joined: 19 Jan 2022, 16:50

2nd Re: Print route error

Post by gelauff »

Maybe not related, but when I enable Error Reporting I get this on the map page :

Deprecated: ucfirst(): Passing null to parameter #1 ($string) of type string is deprecated in /home/ali38000/domains/ali-rhonealpes.org/public_html/components/com_phocamaps/phocamaps.php on line 30
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48386
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Print route error

Post by Jan »

Hi, thank you for the info, yes, the deprecated is not related. If you disable SEF, does it work for you?

Jan
If you find Phoca extensions useful, please support the project
gelauff
Phoca Member
Phoca Member
Posts: 11
Joined: 19 Jan 2022, 16:50

Re: Print route error

Post by gelauff »

Hi Jan,
No, it doesn't work with SEF enabled either.
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48386
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Print route error

Post by Jan »

Hard to say, what can be wrong there, can I see the site where this occurs?

Jan
If you find Phoca extensions useful, please support the project
gelauff
Phoca Member
Phoca Member
Posts: 11
Joined: 19 Jan 2022, 16:50

Re: Print route error

Post by gelauff »

I switched off Print route for now.
Would you like admin access?
It would avoid Print to be enabled longer than you need it.
If you're okay with that, please tell me how to send you the login details.
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48386
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Print route error

Post by Jan »

Hi, make one post again so your post count in this forum is 10, then you will be able to send me PMs here.

Jan
If you find Phoca extensions useful, please support the project
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48386
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Print route error

Post by Jan »

Hi, you have just syntax error in your template:

Image

use Joomla\ CMS\ Factory;
use Joomla\ CMS\ HTML\ HTMLHelper;

Should be:

use Joomla\CMS\Factory;
use Joomla\CMS\HTML\HTMLHelper;

Fixed it, works OK now:

Image

Jan
If you find Phoca extensions useful, please support the project
Post Reply