- This topic has 43 replies, 3 voices, and was last updated 3 years, 5 months ago by
roadlink.
-
AuthorPosts
-
October 5, 2022 at 10:48 am #2364427
Tom
Lead DeveloperLead DeveloperHi there,
We haven’t been able to tackle this yet, sorry!
Reviewing this thread now, but I’m unsure what’s outstanding vs what was fixed. Do you have an updated list of things that are broken on our end so I can investigate for GPP 2.3?
Thanks!
October 5, 2022 at 12:20 pm #2364501roadlink
Hi Tom,
Sure. Sticky add to cart is completely off in composite products.
Thus we use custom codes to make it work.
I just added the codes in below. Between 76-100 I believe.October 22, 2022 at 10:48 am #2382408roadlink
Hi Tom,
We moved to pressable.com as hosting.
And changed some part of this plugin. Not GP part actually.But now add to cart button doesn’t work at all.
I mean you click it but it doesn’t add to cart.Any advice would be great.
I just shared codes again.October 23, 2022 at 7:10 pm #2383490Tom
Lead DeveloperLead DeveloperIs there a page where I can test the add to cart button to see the issue? I’m not seeing anything obviously wrong with the code.
October 28, 2022 at 9:13 am #2391902roadlink
Hi Tom,
Developer added few more line to JS and solved it.jQuery(function () {
jQuery(“.custom-add-to-cart”).click(() => {
jQuery(‘button[name=”add-to-cart”]’).click()
});I just shared staging site’s info in below.
November 2, 2022 at 7:02 pm #2399199Tom
Lead DeveloperLead DeveloperVery strange, that code should definitely not be necessary. Did they give an explanation for why that code worked?
November 2, 2022 at 10:18 pm #2399314roadlink
nope.
And unfortunately this is different developer.
We don’t work with the other one anymore.November 4, 2022 at 7:12 pm #2402219Tom
Lead DeveloperLead DeveloperSo they’re not sure why they decided to write that code?
I’m having a tough time seeing what exactly we need to fix in the plugin. For example, what problem was being solved? If we know the problem, we can replicate it and see if it’s something we can improve within the plugin itself so strange code like the above isn’t necessary.
November 5, 2022 at 6:06 am #2402548roadlink
Hi Tom,
Sorry to keep you busy.Plugin was having solve few issues in old hosting with old plugins.
We have renewed hosting and get rid of some plugins which are encrypted with iconcube.So we ask new developer to get rid of the old unnecessary codes and make it work.
They did it but it didn’t work for add to card button.
Simply button was doing nothing.Latest code solved this issue.
I am putting old plugin and new plugin just for reference.Again, I somehow solved my case. But I am kindly check if you can make GP compatible with composite products.
Thanks
November 5, 2022 at 6:49 am #2402579roadlink
I just compared the codes and saw that they changed 1 line.
Maybe they have that this line and broke it, then need to add these lines?OLD
‘<form action=”%1$s” class=”cart%2$s” method=”post” enctype=”multipart/form-data”>%3$s<button type=”submit” class=”button alt”>%4$s</button></form>’,NEW
‘<form action=”%1$s” class=”cart%2$s” method=”post” enctype=”multipart/form-data”>%3$s<button type=”button” class=”button alt custom-add-to-cart“>%4$s</button></form>’,November 8, 2022 at 8:28 pm #2407345Tom
Lead DeveloperLead DeveloperI’m not sure what difference that would make, really. However, I’m definitely missing context.
I’ll try to test out the composite plugin, but I’m still not 100% sure what kind of incompatibility I should be looking for. Is there anything specific you’d like me to test/debug?
November 9, 2022 at 2:03 am #2407678roadlink
Hi Tom,
Above changes solved the problem and no need to add below lines. So, we come back to original discussion.
jQuery(function () { jQuery(“.custom-add-to-cart”).click(() => { jQuery(‘button[name=”add-to-cart”]’).click() });Let me explain what the issues are.
When we open a composite products sticky add to cart bar can’t be shown.
Composite products plugin takes regular add to cart button and put it at end of the page.
I believe that may be one of the reasons for this problem.I believe they are manipulating something about add to cart button.
What we did via this plugin is simply copy “add to cart” button which created by composite products plugin and show it in sticky bar.
We add a control.
If this is composite product
Copy composite products plugin’s add to cart button and put it sticky bar.Just fyi.
Composite products plugin removes regular add to cart button and put their add to cart button to end of the page.
It is different than what users get used to. We have report this to team and put it back :), but till now no progress.November 14, 2022 at 8:08 pm #2415808Tom
Lead DeveloperLead DeveloperI think the
generate_wc_sticky_add_to_cart_actionfilter is the way to integrate this, but it really depends on what they’re changing about the normal add to cart button.Are you still using that filter anywhere on the site?
November 17, 2022 at 12:31 pm #2420339roadlink
Hi Tom,
I didn’t add it as far as I remember 🙂 -
AuthorPosts
- You must be logged in to reply to this topic.