Hi,
many thanks again! I have now installed the module, but get the message "Class" JRequest "not found" in the backend.
I am using Joomla 4.0.2.
What can I do?
Phoca Download File - Class "JRequest" not found
-
- Phoca Member
- Posts: 12
- Joined: 12 Sep 2021, 13:29
-
- Phoca Hero
- Posts: 2818
- Joined: 28 Nov 2010, 17:20
Re: Phoca Download File - Class "JRequest" not found
Hi,
Which module do you mean? Because for Joomla 4 for testing purposes, Download belongs to PD components:
https://www.phoca.cz/download/category/ ... -component.
See also: viewtopic.php?f=7&p=167306#p167306
BTW: JRequest is deprecated.
Kind regards
Christine
Which module do you mean? Because for Joomla 4 for testing purposes, Download belongs to PD components:
https://www.phoca.cz/download/category/ ... -component.
See also: viewtopic.php?f=7&p=167306#p167306
BTW: JRequest is deprecated.
Kind regards
Christine
-
- Phoca Member
- Posts: 12
- Joined: 12 Sep 2021, 13:29
Re: Phoca Download File - Class "JRequest" not found
Hi,
I mean mod_phocadownload_file_v3.2.2 I got this from Jan, wanted to integrate it, but when I open the settings for this module I get the error message.
I am using the 4.0.0 Alpha6.
thanks
Kind regards
Ronny
I mean mod_phocadownload_file_v3.2.2 I got this from Jan, wanted to integrate it, but when I open the settings for this module I get the error message.
I am using the 4.0.0 Alpha6.
thanks
Kind regards
Ronny
-
- Phoca Member
- Posts: 12
- Joined: 12 Sep 2021, 13:29
Re: Phoca Download File - Class "JRequest" not found
Hi,
I found the problem.
The following lines are the problem.
mod_phocadownload_file_v3.2.2\models\fields\phocadownloadcategorymodule.php
Line 47
// TODO - check for other views than category edit
$view = JRequest::getVar( 'view' );
$catId = -1;
if ($view == 'phocadownloadcat') {
$id = $this->form->getValue('id'); // id of current category
if ((int)$id > 0) {
$catId = $id;
}
}
I excluded it, so there was no more error message.
But I can't choose a category either.
Maybe I'll get behind it and can solve the problem.
I found the problem.
The following lines are the problem.
mod_phocadownload_file_v3.2.2\models\fields\phocadownloadcategorymodule.php
Line 47
// TODO - check for other views than category edit
$view = JRequest::getVar( 'view' );
$catId = -1;
if ($view == 'phocadownloadcat') {
$id = $this->form->getValue('id'); // id of current category
if ((int)$id > 0) {
$catId = $id;
}
}
I excluded it, so there was no more error message.
But I can't choose a category either.
Maybe I'll get behind it and can solve the problem.
- Jan
- Phoca Hero
- Posts: 48386
- Joined: 10 Nov 2007, 18:23
- Location: Czech Republic
- Contact:
Re: Phoca Download File - Class "JRequest" not found
Hi, the module is not ready for Joomla 4 yet, It needs to be overwritten and updated for Joomla 4.
Jan
Jan
If you find Phoca extensions useful, please support the project
-
- Phoca Member
- Posts: 12
- Joined: 12 Sep 2021, 13:29
Re: Phoca Download File - Class "JRequest" not found
Hi,
I solved the problem and now everything works in Joomla 4 as well.
I'll send it back as version 3.2.3 :-)
Thanks again!
I solved the problem and now everything works in Joomla 4 as well.
I'll send it back as version 3.2.3 :-)
Thanks again!
-
- Phoca Member
- Posts: 12
- Joined: 12 Sep 2021, 13:29
Re: Phoca Download File - Class "JRequest" not found
I have not found a way to send the module back, so here is the solution.
file: models\fields\phocadownloadcategorymodule.php
old
$view = JRequest::getVar( 'view' );
new
$app = JFactory::getApplication();
$view = $app->input->getCMD('view', '');
Thanks again!
file: models\fields\phocadownloadcategorymodule.php
old
$view = JRequest::getVar( 'view' );
new
$app = JFactory::getApplication();
$view = $app->input->getCMD('view', '');
Thanks again!
- Jan
- Phoca Hero
- Posts: 48386
- Joined: 10 Nov 2007, 18:23
- Location: Czech Republic
- Contact:
Re: Phoca Download File - Class "JRequest" not found
Ok, thank you for the info.
Jan
Jan
If you find Phoca extensions useful, please support the project
- Jan
- Phoca Hero
- Posts: 48386
- Joined: 10 Nov 2007, 18:23
- Location: Czech Republic
- Contact:
Re: Phoca Download File - Class "JRequest" not found
Hi, fixed in Joomla 4 version.
Jan
Jan
If you find Phoca extensions useful, please support the project
-
- Phoca Member
- Posts: 12
- Joined: 12 Sep 2021, 13:29
Re: Phoca Download File - Class "JRequest" not found
Hello,
is the module already available for Joomla 4? The download works but when I create a new category, I can't select the category in the module
Best regards
Ronny
is the module already available for Joomla 4? The download works but when I create a new category, I can't select the category in the module
Best regards
Ronny