VirtueMart Forum

VirtueMart 2 + 3 + 4 => General Questions => Topic started by: AzMandius on February 19, 2020, 08:32:58 AM

Title: The standard Joomla 404 page is not being displayed
Post by: AzMandius on February 19, 2020, 08:32:58 AM
Hello,

Joomla! 3.6.4
PHP 5.6.40
VirtueMart 3.0.16

The issue is that the standard Joomla 404 page is not being displayed.

I have the "Enable VirtueMart 404 error handling" box unchecked, yet whenever i try to access an nonexistent product - i am brought to shop or product category front page, instead of Joomla 404 page.

This is not a problem for me personally, i like the user being redirected to shop front page instead of useles 404 error page, but the Google Search Console is complaining and saying that incorrect 404 page display could lead to product pages not being properly indexed by search engine.

Is there anything that could be done to enable the standard Joomla 404 error handling for VirtueMart pages no matter what? Some portion of code that i should check?

Thanks a lot!
Title: Re: The standard Joomla 404 page is not being displayed
Post by: GJC Web Design on February 19, 2020, 12:04:50 PM
It is true .. if u use the VM 404 handling you will potentially end up with indexed nonsense urls that point at the VM category

I prefer to switch it off and make a "proper" 404 article page that has a message, search and navigation

see:  https://docs.joomla.org/Archived:Creating_a_Custom_404_Error/en
Title: Re: The standard Joomla 404 page is not being displayed
Post by: AzMandius on February 19, 2020, 12:32:04 PM
Thanks for reply, done that, it works for regular Joomla items, but frankly it does not work for any VirtueMart related url, that is the reason i have created this thread.
Title: Re: The standard Joomla 404 page is not being displayed
Post by: Studio 42 on February 19, 2020, 14:29:43 PM
Have you modify the virtuemart config to not use own 404 handler ?
Title: Re: The standard Joomla 404 page is not being displayed
Post by: GJC Web Design on February 19, 2020, 15:13:43 PM
ah!!!   VirtueMart 3.0.16  - wildly out of date!!!

how can you report bugs on software dating from 04/12/2016 ?
Title: Re: The standard Joomla 404 page is not being displayed
Post by: AzMandius on February 19, 2020, 17:23:19 PM
Quote from: Studio 42 on February 19, 2020, 14:29:43 PM
Have you modify the virtuemart config to not use own 404 handler ?
You mean this?
QuoteI have the "Enable VirtueMart 404 error handling" box unchecked, yet whenever i try to access an nonexistent product - i am brought to shop or product category front page, instead of Joomla 404 page.
Title: Re: The standard Joomla 404 page is not being displayed
Post by: Studio 42 on February 20, 2020, 13:21:26 PM
AzMandius,
Update all your website. All is obsolete ! Vm, Joomla, PHP
And perhaps the problem is solved since(2 years)
Title: Re: The standard Joomla 404 page is not being displayed
Post by: AzMandius on February 20, 2020, 14:19:20 PM
Quote from: Studio 42 on February 20, 2020, 13:21:26 PM
perhaps the problem is solved since(2 years)
or not... who knows... that's not a solution though, but thanks anyway for trying

i am fully aware of outdated code, and there's could be a particular reason for not applying the updates so far, but who cares ;D "update your code" it's always the simplest "solution" to offer ;D
Title: Re: The standard Joomla 404 page is not being displayed
Post by: GJC Web Design on February 20, 2020, 15:10:23 PM
Quotebut who cares ;D "update your code" it's always the simplest "solution" to offer ;D


Sorry -- but a strange attitude.. updates, among other things also contain many bug fixes ...
No one is reporting your "problem" except you  ... I can tell you the VM 404 switch works on all recent (3.6.x releases) so there is a very good chance this has been fixed along with security vulnerabilities and new features.. etc

Will you wait till the inevitable hack occurs before updating? :(
Title: Re: The standard Joomla 404 page is not being displayed
Post by: AzMandius on February 20, 2020, 15:59:12 PM
It could be that template is the reason, as I am using a custom template. I'll have to check in that direction. Thanks.
Title: Re: The standard Joomla 404 page is not being displayed
Post by: GJC Web Design on February 20, 2020, 17:44:36 PM
very unlikely ... this VM 404 stuff is handled at the core of VM

e.g.
components\com_virtuemart\virtuemart.php

components\com_virtuemart\views\category\view.html.php

components\com_virtuemart\views\productdetails\view.html.php

Title: Re: The standard Joomla 404 page is not being displayed
Post by: Studio 42 on February 20, 2020, 20:04:59 PM
You can try to update to VM 3.0.18 or another release and chekc if it wrk. If the problem is the template
Title: Re: The standard Joomla 404 page is not being displayed
Post by: AzMandius on February 24, 2020, 10:38:21 AM
Thank you for any help,
Regards