concretecms-community-store / community_store

An open, free and community developed eCommerce system for Concrete CMS
https://concretecms-community-store.github.io/community_store/
MIT License
106 stars 66 forks source link

Spinning wheel while add product to cart #280

Closed cpeyton88 closed 4 years ago

cpeyton88 commented 7 years ago

Hi guys,

i have the problem while clicking on add to cart Button it will show a spinning wheel... Nothing happens. Tried following workarounds: Pretty URLs, tried it with Version 1.2 and 1.2.1 on Concrete5 Version 8, 8.1+ Would be great if anybody can help out here.

Thanks, Chris

Mesuva commented 7 years ago

Do you have any error messages appear in Chrome's developer console when this happens? If you do, post a screenshot of it, as well as look at the network tab and the relevent server request.

Without some sort of error message or a URL to check out it's pretty difficult to know what is going wrong.

On 18 Sep. 2017 8:22 pm, "cpeyton88" notifications@github.com wrote:

Hi guys,

i have the problem while clicking on add to cart Button it will show a spinning wheel... Nothing happens. Tried following workarounds: Pretty URLs, tried it with Version 1.2 and 1.2.1 on Concrete5 Version 8, 8.1+ Would be great if anybody can help out here.

Thanks, Chris

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/concrete5-community-store/community_store/issues/280, or mute the thread https://github.com/notifications/unsubscribe-auth/ABB5MIqMEMHA0Vt2u_tHjseeZiJF9NUvks5sjkt3gaJpZM4Paup8 .

cpeyton88 commented 7 years ago
consoletab

Hi, yes getting POST 404 (NOT FOUND) communityStore.js:110 Looks like it is not finding /cart/add... All is on Standard Settings...

networktab
Mesuva commented 7 years ago

What happens if you visit /index.php/cart/add directly in a browser? Do you get a completely white screen (as expected), or do you get some sort of formatted 404 page?

What about if you just go to /index.php/cart ?

If you get a white screen and the cart page is in the normal position my next guess is that Mod Security is blocking those POST requests. You could ask you host to check their logs for a triggered Mod Security rule (matching the URL) and ask them to whitelist it.

cpeyton88 commented 7 years ago

Thanks to Mesuva for helping out so far. /index.php/cart/add directly in a browser? - Getting 404 Error Page not found /index.php/cart? - Goes back to Home and i can see my startpage /index.php/home/cart - Shows me Your Cart is empty (which is correct) I am running Apache by my self, no mod security rule blocks anything..

cpeyton88 commented 7 years ago

index.php/home/cart/add - shows a completely white blank page...

Mesuva commented 7 years ago

Can you explain the /cart/ in these urls? Are you running your install out of a folder?

Community Store should be dynamically adjusting the cart urls, but it sounds like your cart page is not matching where the script thinks it should be. Is this a local install, or can you share a URL?

cpeyton88 commented 7 years ago

It is in our Intranet so it is not public, cannot share... i checked the Canonical Links, but only under products page concrete5 allows me to add another url, not under /cart, there it is /home/cart instead of /cart... i installed it under packages/communitystore But during installation i comment line 53,54,55 and 76 in installer.php, otherwise i will get this set attribute null error... Can i hardcode the link for /cart?

Mesuva commented 7 years ago

Are you running a multi-language install?

cpeyton88 commented 7 years ago

Under System/Settings Multilingual Setup is available Local US English only Home Page Home...

cpeyton88 commented 7 years ago

looks like it has something todo with multilanguage setup, because under Multilingual Setup there is en-us Home

Mesuva commented 7 years ago

I think this is related to https://github.com/concrete5-community-store/community_store/issues/257

I would try hardcoding the paths to the pages in community_store/controller.php - there is a function returnHeaderJS, you could try changing the paths there for /cart and /checkout

cpeyton88 commented 7 years ago

Many thanks! add to cart is working without any issues now, also Checkout, only Problem what i have now is /checkout/submit, when you complete the order. Is there another path which has to hardcoded?

Mesuva commented 7 years ago

There are a few references to /checkout/ in both packages/community_store/single_pages/checkout.php and packages/community_store/controllers/single_page/checkout.php Just search in those for '/checkout/' and you should find them easily.

MichaelMaar commented 7 years ago

Just a comment... @Mesuva I think we have said this before, but yet again, I'll try. We encountered the same problem under multilingual on 8.2 with our C5DK Blog package. And we decided to change from "single page" system to a slide-in element solution instead (we actually have both now). By using an element in a slide-in we totally overcome the issues of multilingual setup under concrete5 version 8.2+

cpeyton88 commented 7 years ago

Hi guys, still have the problems with checkout/submit - getting 404 page not found when i click on complete order... how is that solution working with the slide-in element? Many thanks...

Mesuva commented 7 years ago

@MichaelMaar I did note your potential solution to this earlier, but I'm not sure that will necessarily work with the complexity of some of these single pages, especially the checkout page.

Have you got an example of this slide-in solution that you can point to, for me to see how it's been achieved?

MichaelMaar commented 7 years ago

@Mesuva I can send you a copy of our Blog Package. What we did was moving all singlepage functionality to elements. By that we were able to have both single pages and the slide in (chosen as a setting on the settings page). We have another kind of big project where we are using some kind of similar functionality as the checkout page. It's a truck ordering page with multiply steps to fill out to order a truck. All that functionality is simply added to a block and by that we are able to, first: get rid of single pages. Second: have the flexibility to drop the functionality where ever we want. I can't give you a copy of that because it's a special project. But I can send you a few screenshuts or even better give you access to our dev site so you can see for your self.

Mesuva commented 7 years ago

Understood. I don't think we'll be able to move the checkout functionality to a block easily, but I'll give it some thought.