Update to Joomla 3.8.2 and Hikashop 3.2.1 Breaks a LOT of stuff

  • Posts: 62728
  • Thank you received: 8991
  • MODERATOR
6 months 3 weeks ago #284849

Hi,

Then please provide a backend and a FTP access to the website along with a link to this thread via our contact form:
www.hikashop.com/support/contact-us.html

Please Log in or Create an account to join the conversation.

  • Posts: 446
  • Thank you received: 11
  • Hikashop Essential
6 months 3 weeks ago #284883

nicolas wrote: Hi,

Then please provide a backend and a FTP access to the website along with a link to this thread via our contact form:
www.hikashop.com/support/contact-us.html


Sending over now...thank you

Please Log in or Create an account to join the conversation.

  • Posts: 62728
  • Thank you received: 8991
  • MODERATOR
6 months 3 weeks ago #284941

Hi,

I've had a look for several hours but couldn't find a suitable solution to prevent your issue.
The issue you have is this:
When you click on something on your website your browser sends two kind of data:
- the data in the GET (in the URL)
- the data in the POST (the data sent hidden, like forms data)
Upon arrival on the server, both of these are merged into the REQUEST.
Normally, to get data coming in (what page to display, what data was sent by the user, etc), a PHP script will look in these variables.
In order to get that data HikaShop go through the Joomla JInput system.
This system filters the data for HikaShop so that the data is securised. All Joomla extensions are supposed to go through JInput and not use directly GET/REQUEST/POST.

The problem comes from the line:
$ref =& JFactory::getApplication()->input;
in the file administrator/components/com_hikashop/helpers/helper.php
This is where HikaShop get the JInput system from Joomla to be able to use it everywhere.
When I display it on your staging website with a var_dump(JFactory::getApplication()->input); all I get is the data in the GET (in the URL) and not the data in the POST, where I'm supposed to get both merged together in the REQUEST.
If I change that line to:
$ref =& JFactory::getApplication()->input->request;
then the data is there and I can use it.
However, besides GET and POST, browsers also send COOKIES and FILES data (for cookies and file uploads) and the FILES are not merged in REQUEST.
So if I do that change there, that means that the upload of files won't work properly in HikaShop. You can try to see if that change works for you, but we won't be able to include it on our end.

The real issue is that JFactory::getApplication()->input is actually supposed to have the data of REQUEST and not the data of GET only. And I don't know why it doesn't have that data on your staging website.

Please Log in or Create an account to join the conversation.

  • Posts: 446
  • Thank you received: 11
  • Hikashop Essential
6 months 3 weeks ago #284989

nicolas wrote: Hi,

I've had a look for several hours but couldn't find a suitable solution to prevent your issue.
The issue you have is this:
When you click on something on your website your browser sends two kind of data:
- the data in the GET (in the URL)
- the data in the POST (the data sent hidden, like forms data)
Upon arrival on the server, both of these are merged into the REQUEST.
Normally, to get data coming in (what page to display, what data was sent by the user, etc), a PHP script will look in these variables.
In order to get that data HikaShop go through the Joomla JInput system.
This system filters the data for HikaShop so that the data is securised. All Joomla extensions are supposed to go through JInput and not use directly GET/REQUEST/POST.

The problem comes from the line:
$ref =& JFactory::getApplication()->input;
in the file administrator/components/com_hikashop/helpers/helper.php
This is where HikaShop get the JInput system from Joomla to be able to use it everywhere.
When I display it on your staging website with a var_dump(JFactory::getApplication()->input); all I get is the data in the GET (in the URL) and not the data in the POST, where I'm supposed to get both merged together in the REQUEST.
If I change that line to:
$ref =& JFactory::getApplication()->input->request;
then the data is there and I can use it.
However, besides GET and POST, browsers also send COOKIES and FILES data (for cookies and file uploads) and the FILES are not merged in REQUEST.
So if I do that change there, that means that the upload of files won't work properly in HikaShop. You can try to see if that change works for you, but we won't be able to include it on our end.

The real issue is that JFactory::getApplication()->input is actually supposed to have the data of REQUEST and not the data of GET only. And I don't know why it doesn't have that data on your staging website.


Thanks Nicolas...sorry about the delay in getting back to you. I've been having some retina issues and wasn't able to read anything for 2 days after a small procedure.

I'll shoot this info over to the host to see if they have any information about this issue on their staging areas.

If not...any other suggestions? Maybe ask in the Joomla groups?

Please Log in or Create an account to join the conversation.

  • Posts: 62728
  • Thank you received: 8991
  • MODERATOR
6 months 3 weeks ago #284997

Hi,

The fact that JFactory::getApplication()->input doesn't contain the same thing than JFactory::getApplication()->input->request and that this only happens on your website (and not on other websites using HikaShop) is indeed strange.
I suppose that it must be linked to another extension doing strange things with JFactory::getApplication()->input
Posting on Joomla groups could be an idea yes.
Also, what you can do is try to disable the plugins, modules, components, templates one by one and see each time if you have the problem. Hopefully, you can mek it work with only disabling one extension, which will mean that the issue is something linked to what that extension does and we can move forward from there.

Please Log in or Create an account to join the conversation.

  • Posts: 446
  • Thank you received: 11
  • Hikashop Essential
6 months 3 weeks ago #285006

nicolas wrote: Hi,

The fact that JFactory::getApplication()->input doesn't contain the same thing than JFactory::getApplication()->input->request and that this only happens on your website (and not on other websites using HikaShop) is indeed strange.
I suppose that it must be linked to another extension doing strange things with JFactory::getApplication()->input
Posting on Joomla groups could be an idea yes.
Also, what you can do is try to disable the plugins, modules, components, templates one by one and see each time if you have the problem. Hopefully, you can mek it work with only disabling one extension, which will mean that the issue is something linked to what that extension does and we can move forward from there.


OK will do...I'd agree with you (even with my limited knowledge on the issue)...but I shut off everything I could find and it was still doing it.

Hopefully someone will have an answer for it.

Please Log in or Create an account to join the conversation.

  • Posts: 446
  • Thank you received: 11
  • Hikashop Essential
3 months 3 weeks ago #290202

Nicolas, Jerome, whoever...

I'm still stuck on this. I've reached out to people I figure can fix it, and they all want an upfront fee of OVER $2000 USD to even look at it (except one guy...I haven't heard yet how much he would want). I've already spent $700 USD to find out from a tech group that unfortunately doesn't know anything about HikaShop based on Nicolas' statement that this isn't a HikaShop problem...only to find out that Joomla & all my plugins ARE FINE AND THE PROBLEM IS WITHIN HIKASHOP!!!

I'm getting pretty aggravated by the constant issues of when a patch or new release comes out, it constantly breaks things. Now I'm out of MONEY because of it and it's STILL not fixed! This one has been the worst. Issues ALL over the place! After my USPS shipping issue, someone in the community here reached out & said the newest version fixed it, which it did for me...but now when trying to do everything else, I'm back to having these GET & POST issues you found Nicolas 3 months 2 days ago!

I'm to the point of wanting a refund for the years of service I've pre-paid for HikaShop and just move to a new platform that doesn't have so many issues. Please...someone, help me with this. I need my site fixed because HikaShop keeps breaking and it has nothing to do with the rest of my site. The issue is within HikaShop!

Please Log in or Create an account to join the conversation.

  • Posts: 62728
  • Thank you received: 8991
  • MODERATOR
3 months 3 weeks ago #290245

Hi,

I don't understand what you mean... Two messages ago I provided a potential solution you can try:

The problem comes from the line:
$ref =& JFactory::getApplication()->input;
in the file administrator/components/com_hikashop/helpers/helper.php
If I change that line to:
$ref =& JFactory::getApplication()->input->request;
then the data is there and I can use it.

This should help but you never gave any feedback about it. And based on the information of that message, a normal PHP developer should be able to write a patch for your website so that it can even allow the files and cookies to work properly too.
It should only require a few hours of development/testing I guess.

While we're happy to fix issues in HikaShop for free when they are reported, no one else reported a similar issue since HikaShop 3.2.1 and there are thousands of merchants using more recent versions of HikaShop. So it's not possible that the issue is inside HikaShop. Others would have had the same issue.
So it can only be another extension impacting the use of JInput on your website.
We can't spent several hours developing a patch for your website for something which isn't caused by HikaShop. And I've already spent several hours debuging the issue on your website to understand the situation.
If you want to pay us to develop a patch for that situation for your website, we can but we can't do it for free.
In that case, please use our contact form to request a quote and we can work on it for you.
www.hikashop.com/support/contact-us.html
However, I would first recommend to do the change I proposed before and see how that works for you. That might actually be enough.

Please Log in or Create an account to join the conversation.

  • Posts: 446
  • Thank you received: 11
  • Hikashop Essential
3 months 2 weeks ago #290290

nicolas wrote: Hi,

I don't understand what you mean... Two messages ago I provided a potential solution you can try:

The problem comes from the line:
$ref =& JFactory::getApplication()->input;
in the file administrator/components/com_hikashop/helpers/helper.php
If I change that line to:
$ref =& JFactory::getApplication()->input->request;
then the data is there and I can use it.

This should help but you never gave any feedback about it. And based on the information of that message, a normal PHP developer should be able to write a patch for your website so that it can even allow the files and cookies to work properly too.
It should only require a few hours of development/testing I guess.

While we're happy to fix issues in HikaShop for free when they are reported, no one else reported a similar issue since HikaShop 3.2.1 and there are thousands of merchants using more recent versions of HikaShop. So it's not possible that the issue is inside HikaShop. Others would have had the same issue.
So it can only be another extension impacting the use of JInput on your website.
We can't spent several hours developing a patch for your website for something which isn't caused by HikaShop. And I've already spent several hours debuging the issue on your website to understand the situation.
If you want to pay us to develop a patch for that situation for your website, we can but we can't do it for free.
In that case, please use our contact form to request a quote and we can work on it for you.
www.hikashop.com/support/contact-us.html
However, I would first recommend to do the change I proposed before and see how that works for you. That might actually be enough.


Hi Nicolas,

I did change that line in the helper.php, and I cannot even get into the cart, let alone now products show up in the category (or for my site the manufactures) selection...so this doesn't work. I apologize, I could have sworn I posted this as a reply...but apparently it did not post.

Last Edit: 3 months 2 weeks ago by nicolas. Reason: fixing quotes

Please Log in or Create an account to join the conversation.

  • Posts: 62728
  • Thank you received: 8991
  • MODERATOR
3 months 2 weeks ago #290336

Hi,

Mmm. I wanted to have a look again at the situation but the staging2 website you had provided doesn't work anymore, and on the staging1, the backend access doesn't work.

One other solution I was thinking about was to change all the:
hikaInput::get()->
to:
$input->request->
and add on the line before each:
$input = JFactory::getApplication()->input;
in the file components/com_hikashop/controlllers/checkout_legacy.php in order to bypass HikaShop's JInput override to directly use Joomla's. However, if the JInput of Joomla is broken by another extension it won't help.

Another solution I'm thinking about is to change the code:
if(HIKASHOP_J30) {
class hikaInput {
to:
if(false) {
class hikaInput {
in the file administrator/components/com_hikashop/helpers/helper.php so that it will switch to the old system of input filtering of Joomla instead of the new one.

So please try these and see how that goes.

Please Log in or Create an account to join the conversation.

  • Posts: 446
  • Thank you received: 11
  • Hikashop Essential
3 months 2 weeks ago #290365

nicolas wrote: Hi,

Mmm. I wanted to have a look again at the situation but the staging2 website you had provided doesn't work anymore, and on the staging1, the backend access doesn't work.

One other solution I was thinking about was to change all the:
hikaInput::get()->
to:
$input->request->
and add on the line before each:
$input = JFactory::getApplication()->input;
in the file components/com_hikashop/controlllers/checkout_legacy.php in order to bypass HikaShop's JInput override to directly use Joomla's. However, if the JInput of Joomla is broken by another extension it won't help.

Another solution I'm thinking about is to change the code:
if(HIKASHOP_J30) {
class hikaInput {
to:
if(false) {
class hikaInput {
in the file administrator/components/com_hikashop/helpers/helper.php so that it will switch to the old system of input filtering of Joomla instead of the new one.

So please try these and see how that goes.


Nicolas...let me try those in a day or so when I have a moment and I'll report back.

Each time I upload a new staging site, the number changes. Right now it's staging1. I re-entered the password & user permissions for the account if you still want to look. The password SHOULD still be the same...but I'll send it over just in case.

Please Log in or Create an account to join the conversation.

  • Posts: 62728
  • Thank you received: 8991
  • MODERATOR
3 months 2 weeks ago #290380

Hi,

Please try the changes and report back. If that doesn't help, make sure that the staging info we have is correct so that we can look into the issue.

Please Log in or Create an account to join the conversation.

  • Posts: 446
  • Thank you received: 11
  • Hikashop Essential
3 months 1 week ago #290919

nicolas wrote: Hi,

Please try the changes and report back. If that doesn't help, make sure that the staging info we have is correct so that we can look into the issue.


Ok...so, I was coming on here to say that I've tried EVERYTHING listed, and nothing was working. I destroyed the staging site, left it empty for a day, just went and created a new staging site using the same method I've done every time. I went and updated all the necessary updates as needed on the staging site...

And everything works perfectly. This is killing me...I swear, this is going to give me a heart attach or a stroke...or both.

So, I just tested everything I could shopping wise, and all the links, anything I could imagine and it all works. So as to take advantage of this good fortune, I just backed up my live site, and am pushing the staging site live. We shall see what happens.

Please Log in or Create an account to join the conversation.

  • Posts: 446
  • Thank you received: 11
  • Hikashop Essential
3 months 1 week ago #290920

And...it broke something after it was all pushed live. I've never seen this before...any ideas? I was able to click Shopping on the menu, then the manufacture, then the sub categories, but when I got to product, I got this error.

Attachments:
Last Edit: 3 months 1 week ago by Dragon41673.

Please Log in or Create an account to join the conversation.

  • Posts: 22525
  • Thank you received: 3509
  • MODERATOR
3 months 1 week ago #290954

Hello,

You should perform a "check database" via the toolbar in your HikaShop configuration screen.

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

Please Log in or Create an account to join the conversation.

  • Posts: 446
  • Thank you received: 11
  • Hikashop Essential
3 months 1 week ago #291002

Jerome wrote: Hello,

You should perform a "check database" via the toolbar in your HikaShop configuration screen.

Regards,


Ok...seriously, I'm pounding my head on my desk. I just did the EXACT same process today on yet ANOTHER fresh staging ground...and there are no errors. Everything is working properly. I'm on Joomla 3.8.6, and HikaShop Essentials 3.4.0.

I'm beginning to realize why some people wanted over $2,000 USD to fix...it makes me want to give up. Literally.

I'll keep screwing around and see if I can break it and report back if I run into something.

Please Log in or Create an account to join the conversation.

  • Posts: 446
  • Thank you received: 11
  • Hikashop Essential
3 months 1 week ago #291003

Ok...all links seem to work. Order went through fine on the live site. Database had no errors. Nothing...it updated like it never had a problem like it should have 4 months and 3 days ago based on the first post of this thread.

I'll keep an eye on it and report back if there's an issue.

Thanks for putting up with the insanity, sorry it was so frustrating.

Please Log in or Create an account to join the conversation.

Time to create page: 0.139 seconds
Powered by Kunena Forum