Phoca Download Editor Button in frontend: Error 500 and more

Phoca plugins - support for all Phoca plugins except Phoca Gallery plugins
Maranomedia
Phoca Member
Phoca Member
Posts: 11
Joined: 30 Oct 2013, 17:18

Phoca Download Editor Button in frontend: Error 500 and more

Post by Maranomedia »

Joomla: 2.5.x
PHP: 5.3+
Phoca DL v. 2.1.9
Plugin v 2.1.4.
Editor: JCE

Unfortunatly the Phoca Download Editor button has several bugs when I use it in the frontend:

1) is a minor one that may be fixed through different modification: complete loss of css styling, the frontend view is completely unformatted. It looks confusing and broken (visually). I solved that (partly) trough modifications of the file components/om_phocadownload/views/phocadownloadlinkfile/view.html.php and components/om_phocadownload/views/phocadownloadlinkfile/tmpl/default.php

2) is a major bug and for one om my projects a no go, because we have more than 2.000 documents: The pagination in the frontend is not working, all I get when I try to view a diffent page is an error 500. How can I solve this? It doesn´t matter if SEF is on or off, wether I use mod_rewrite, it does not work.

Index Page works ... like

index.php?option=com_phocadownload&view=phocadownloadlinkfile&tmpl=component&e_name=jform_articletext&type=0

but when I click on page 3 for instance, the link is

component/phocadownload/?tmpl=component&e_name=jform_articletext&type=0&start=60

and error 500 is displayes ....

I really appreciate any hint to solve that problems, I´m getting mad on it ... thanx in advance! :?:
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48403
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Phoca Download Editor Button in frontend: Error 500 and

Post by Jan »

Hi,

1) do you get the problem when you will use standard joomla editor?
2) do you get some error message (500 means mostly a php error, are you able to see your errorLog or are you able to enable php error reporting to see the errror? - https://www.phoca.cz/documents/16-joomla ... rs-on-site )

Jan
If you find Phoca extensions useful, please support the project
Maranomedia
Phoca Member
Phoca Member
Posts: 11
Joined: 30 Oct 2013, 17:18

Re: Phoca Download Editor Button in frontend: Error 500 and

Post by Maranomedia »

Thanks for your reply, Jan. It also happens with Tiny MCE or other editors. It also makes no difference, if webserver or localhost, if mod rewrite on or of, if sef on or not. I will check the error reporting and post it here. I thought it would be a global problem for the button, when activated in frontend..


Thanks so far - Beste Grüße - Marco
Maranomedia
Phoca Member
Phoca Member
Posts: 11
Joined: 30 Oct 2013, 17:18

Re: Phoca Download Editor Button in frontend: Error 500 and

Post by Maranomedia »

It took some time to check taht issue, but I can say, that this problem is a general one.

In frontend, when trying to integrate a PD-File though the editor button, the pagination never works. I made several tests and it never worked. This must me a problem from the quick-andy-dirty conversion to make the button work in frontend view.

Here are the debugger results, I really hope you´ll find a solution to make this general PC-plugin-problem history ....

View nicht gefunden [Name, Typ, Präfix]: phocadownload, html, phocadownloadView
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48403
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Phoca Download Editor Button in frontend: Error 500 and

Post by Jan »

Hi, you only get the view not found, not any error as I see - the view not found can be cause by many problems:

- wrong sef
- not correctly installed frontend of the component
- not created a menu link to component
- some missing file in Joomla! installation which should convert urls, etc :idea:

Jan
If you find Phoca extensions useful, please support the project
Maranomedia
Phoca Member
Phoca Member
Posts: 11
Joined: 30 Oct 2013, 17:18

Re: Phoca Download Editor Button in frontend: Error 500 and

Post by Maranomedia »

Hi again,

I can verify that the same problem happens with Joomla 3 ( PD 3.0.5, Button Plugin 3.0.1).

I tested it on about 20 servers/sites (J2.5.x/J3.x) and it´s happening EVERY time.

Every time, I use "Link to File" the whole CSS gets broken and pagination´s not working due to an "View not found error"

View nicht gefunden [Name, Typ, Präfix]: phocadownload, html, phocadownloadView.

So, something´s missing in the Phoca Download (Component) installation in general, it´s no problem with wrong sef, missing menu links or missing files of the joomla installation. It must be a problem inside the

components/com_phocadownload/views structure ...

It would be great if this error could be fixed! I tried a lot already, but without success.

Best regards - Marco

P.S.: Everything´s fine in the backend with the plugin, this is a frontend only bug.
Maranomedia
Phoca Member
Phoca Member
Posts: 11
Joined: 30 Oct 2013, 17:18

Re: Phoca Download Editor Button in frontend: Error 500 and

Post by Maranomedia »

It seems I have found a temporary solution:

In the file plugins/editor-xtd/phocadownload/phocadownload.php

Line 35 (Joomls 2.5)

I change the URL from

$link = 'index.php?option=com_phocadownload&view=phocadownloadlinks&tmpl=component&e_name='.$name;

to

$link = 'administrator/index.php?option=com_phocadownload&view=phocadownloadlinks&tmpl=component&e_name='.$name;

Then the whole thing works with CSS and pagination (in frontend). Side effect: Doesn´t work in the backend now (administrator/administrator path ...)

Regards,

Marco

P.S.: Quick and dirty solution for use both in frontend and backend: Redirect in .htaccess. But still looking for a more elegant solution ....
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48403
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Phoca Download Editor Button in frontend: Error 500 and

Post by Jan »

Hi, thank you for the info, I will take a look at it for the next version.

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

Re: Phoca Download Editor Button in frontend: Error 500 and

Post by Jan »

Hi, this seems to be SEF problem, for now I added specific pagination class to remove this problem.

So this should be ok now with Phoca Download version 3.0.6

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