problem with modifying orders in Chrome

  • Posts: 20
  • Thank you received: 1
  • Hikashop Business
9 years 9 months ago #192009

-- HikaShop version -- : 2.3.5
-- Joomla version -- : 2.5.28
-- PHP version -- : 5.4.37
-- Browser(s) name and version -- : Chrome 40.0.2214.115 m

Found a problem in Chrome while editing an order.
Here are the steps to reproduce it :
- go into the back-end of the site
- access the orders page of Hikashop
- open one to edit it
- start modifying any of the addresses, using the Edit button ( the icon on the same page )
- modify the title for the address and save
- try editing the address again
- the title is displayed wrong in it's combo and if you don't modify it again the wrong value will be saved

This is not happening with other browsers. I've tried Firefox and Internet Explorer.
I hope you can fix it in the next release of Hikashop.

Thank you

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

  • Posts: 13201
  • Thank you received: 2322
9 years 9 months ago #192035

Hi,

I just tried to reproduce the issue on my local on Chrome, but it is working fine.
When doing as you explained step by step I don't have any issues.

So I think that you have a javascript error on your page which could cause the issue, this error can be created by another extension like a system plugin for example.

Please check with your browser console if any error is displayed under the "console" tab.

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

  • Posts: 20
  • Thank you received: 1
  • Hikashop Business
9 years 8 months ago #194789

Hi,

There is no javascript error and the problem appears only in Chrome.
Now I found a similar problem when modifying the status of the order ( also only in Chrome ).
Could be something in my Chrome, but as far as I know there are no changes in it's settings.
I've ended up modifying the file :

joomla_root/media/com_hikashop/js/hikashop.js
I've added some lines of code in the function xRequest ( after the line 163 ):
			var dRand = new Date();
			var nRand = dAlex.getTime();
			url = url+'&'+nRand+'=1';
This was the ajax call is never cached.

In case you find this helpful maybe you will modify the code in the next version of Hikashop so I don't have to do it after each update. :)
I suggest a similar approach on all ajax calls.

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

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
9 years 8 months ago #194791

Hi,

Thanks for the report.
But I don't think that it is a good idea to modify the Oby library because in some cases you might need to have some browser cache.
The best will be to modify in the views the xRequest calls in order to add this timestamp value in the url and to activate some non-cache directives in the different pages, using:

hikashop_nocache();
which add some headers in the HTTP response to specify to the browser that it should cache the page.

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: 20
  • Thank you received: 1
  • Hikashop Business
9 years 8 months ago #195000

Hi,

Thank you for your reply.
Maybe you can implement some solution to force Chrome not to cache the requests in case the value was changed.
Or maybe you can add a parameter that will implement "hikashop_nocache();" in the views.

I understand that you couldn't replicate the problem and it's strange that it happened only to me, so I also understand that you might consider it a waste of time, especially since this could occur only in some very specific situations and can be easily remedied by modifying the values again.

For now this is the fastest solution for me (checking all the places where Ajax is used and modifying the view would take too much time).

Thank you for your work on Hikashop. It's a very nice and useful extension.

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

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
9 years 8 months ago #195009

Hi,

For sure it's better for you to keep your modification in the javascript file for the moment because it fix a issue you got.
After that, it's possible that the configuration of your web server (via via an htaccess) modify the return of the pages to let the browser cache them. But it's not the default behavior.
That's why I think it will be better for HikaShop to add some "no cache" directives for some pages ; to be sure that you won't have issue with ajax calls or other type of web calls.

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.

Time to create page: 0.074 seconds
Powered by Kunena Forum