Error "Call to undefined method Joomla\Filesystem\File::exists()", e-mail attachments for order status

Phoca Cart - complex e-commerce extension
mic.web24
Phoca Member
Phoca Member
Posts: 16
Joined: 18 Dec 2024, 17:27

Error "Call to undefined method Joomla\Filesystem\File::exists()", e-mail attachments for order status

Post by mic.web24 »

Hi,
if there is a PDF as an attachment for an order status, a white page with this error appears after clicking on the ‘Buy now button’:

0
Call to undefined method Joomla\Filesystem\File::exists()

Without attachment it works fine.
Does anyone else have this problem or is there a solution?

PhocaCart 5.0.0RC2

Image

Thank you, regards
Martin.
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 49125
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Error "Call to undefined method Joomla\Filesystem\File::exists()", e-mail attachments for order status

Post by Jan »

Hi, can you enable debug mode and paste here whole error message including trace (to see in which file and row this happens)

Which version of Joomla do you use?

Thank you, Jan
If you find Phoca extensions useful, please support the project
mic.web24
Phoca Member
Phoca Member
Posts: 16
Joined: 18 Dec 2024, 17:27

Re: Error "Call to undefined method Joomla\Filesystem\File::exists()", e-mail attachments for order status

Post by mic.web24 »

Hello Jan,
I hope the picture helps with troubleshooting:

Image

I use Joomla 5.2.5
PhocaCart 5.0.0RC2

Thanks, Martin.
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 49125
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Error "Call to undefined method Joomla\Filesystem\File::exists()", e-mail attachments for order status

Post by Jan »

Hi, thank you for info, will be changed in next version

To make a quick fix, go to:
administrator/components/com_phocacart/libraries/src/Mail/MailHelper.php

and on line cca 22 change

FROM:

Code: Select all

use Joomla\Filesystem\File;
TO:

Code: Select all

use Joomla\CMS\Filesystem\File;
If you find Phoca extensions useful, please support the project
mic.web24
Phoca Member
Phoca Member
Posts: 16
Joined: 18 Dec 2024, 17:27

Re: Error "Call to undefined method Joomla\Filesystem\File::exists()", e-mail attachments for order status

Post by mic.web24 »

Thank you. It works fine now. Greetings Martin.
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 49125
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Error "Call to undefined method Joomla\Filesystem\File::exists()", e-mail attachments for order status

Post by Jan »

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