Jump to content

Voucher Box Not Appearing In Ff


Recommended Posts

I just noticed something very weird (please bear with me, I'm new to PS).

I'm using 1.5.3.1 (test shop - nowhere near ready to go live yet) and I've added some cart rules to enable vouchers. Oddly enough, although I can see the voucher box in the cart in IE and Chrome, it doesn't appear when I view the cart in Firefox (v19.0). I cleared the browser cache yet still no box. I'm sure there must be a very simple explanation for this - can anyone help? I'm hoping it will be something so simple that I'll bang my head on the keyboard for having missed it... :P

~ Elaine

Edit:
It has become clear that this problem exists with other shops, and occurs with at least one other browser (Chrome). Although Firebug fixed it for my own personal viewing pleasure, there is something inherently wrong that is making this element occasionally disappear.
 

 
TEMPORARY SOLUTIONS/WORKAROUNDS:
The problem seems to be in the Paypal module, so if you do not use PayPal simply disable the module. For Paypal users, method #1 will work for most people. If not, try #2 etc. Currently there is no perfect solution for everyone. While testing these methods, make sure you clear browser cookies/cache each time to see if the method worked. And remember to make backups of your files!

1.) Themes > (your theme) > shopping_cart.tpl rename the id of the form "#cart_voucher" to "#cart_voucher2".
2. ) Modules > paypal > views > templates > hook > paypal.js delete lines 46-66 (details here). **If you have  Express Checkout enabled (see module config), do some test payments to ensure this does not cause errors during checkout**
3.) Unhook PayPal module from Header of pages (Displayheader). **Do some test payments to ensure this does not cause errors in your checkout**

Edited by artofadornment (see edit history)
  • Like 2
Link to comment
Share on other sites

Your hunch was right, it was just my browser (my browser specifically - turns others *could* see it in FF although I couldn't). Firebug did the trick, I was able to see that the form element has been completely stripped out, and was able to add it back in. Boy do I feel silly... LOL

 

I certainly learned something new today. Thank you so much! :)

Edited by artofadornment (see edit history)
Link to comment
Share on other sites

  • 1 month later...

This isn't really solved. Why does the behavior occur in the first place? This just happened to 2 customers today on my store. Except they could not see the voucher box in chrome, and could in firefox.

 

Does anyone know a more in depth solution?

Link to comment
Share on other sites

This isn't really solved. Why does the behavior occur in the first place? This just happened to 2 customers today on my store. Except they could not see the voucher box in chrome, and could in firefox.

 

Does anyone know a more in depth solution?

 

you use default template or some external solution? Can you provide an url to your store? I will try to find solution

Link to comment
Share on other sites

I agree. It seems impossible to debug because it does not occur for me. In a way, the OP was lucky it happened on his own computer/browser. I see that OP fixed the problem with firebug, but i am unsure exactly what he did.

 

I think perhaps adding a display: block; attribute on <form> elements in the CSS might help. It looks like the only style associated with a form element on my site is coming from Chrome's "user agent stylesheet" which, for me, does have display: block; set.

 

edit: I actually just added that display: block to the default theme's global stylesheet. I am hoping it works. So there might not be any need for further debugging, but i need to wait for another customer to complain to see.

Edited by mattgoody (see edit history)
Link to comment
Share on other sites

I didn't realize that it would be more than just me having this problem, wow! I'm going to remove "solved" until we can find a way to fix this for good. My shop isn't live yet, so the fact that live shops are having this problem means that although Firebug solved it for me personally, it isn't solving it for good.

Link to comment
Share on other sites

Thanks for the interest in solving this problem guys.

 

I was able to chat with a customer who was unable to see the voucher box today: http://prntscr.com/z8fy2

 

I got him to take a screen shot of the chrome js console. It was very disconcerting to see that there was NO <form> element at all: http://prntscr.com/z8gd0

 

as you can see, the <td> element that normally surrounds the form (#cart_voucher) is there, but the form is not.

 

The customer also told me that he IS able to see the voucher box when he used chrome in incognito mode, and also it was working fine in firefox.

 

I am unsure how to proceed because i have no idea what would make prestashop output the html differently for different browsers etc.

 

Edit: Ok. As i was writing this post, i had the customer copy and paste the source code of his order page. i found the following line in the "$(document).ready(function" part of the JS on the top of the source:

 

$('.qty-field.cart_quantity_input, .cart_total_bar, .cart_quantity_delete, #cart_voucher *').remove();

 

This line of JS removed the voucher box. That line is also not present in the source code of the page when i view it from my computer. Howeverm if i type it into the javascript concole in chrome, it removes the voucher box.

 

So, i think i found the problem, but im not sure how to rectify it.

Edited by mattgoody (see edit history)
Link to comment
Share on other sites

This is the entirety of the javascript that my customer has in the source code of the (broken) checkout page, that is not present on my (working) checkout page. This is only in the source code:

 

    var qty = $('.qty-field.cart_quantity_input').val();
    $('.qty-field.cart_quantity_input').after(qty);
    $('.qty-field.cart_quantity_input, .cart_total_bar, .cart_quantity_delete, #cart_voucher *').remove();
    var br = $('.cart > a').prev();
    br.prev().remove();
    br.remove();
    $('.cart.ui-content > a').remove();
    var gift_fieldset = $('#gift_div').prev();
    var gift_title = gift_fieldset.prev();
    $('#gift_div, #gift_mobile_div').remove();
    gift_fieldset.remove();
    gift_title.remove();
    $('#container_express_checkout').hide();
    $('#cgv').live('click', function () {
	    if ($('#cgv:checked').length != 0)
		    $(location).attr('href', 'http://seemorebreaks.com/?fc=module&module=paypal&controller=confirm&get_confirmation=1');
    });
    $('#cgv').click(function () {
	    if ($('#cgv:checked').length != 0)
		    $(location).attr('href', 'http://seemorebreaks.com/?fc=module&module=paypal&controller=confirm&get_confirmation=1');
    });

Link to comment
Share on other sites

mattgoody: my [spam-filter] did some digging and discovered that the mysterious javascript command is coming from the PayPal module, specifically modules > paypal > views > templates > hook > paypal.js lines 46-66, line 52 being the killer.

 

It seems to us that the code is intended for people using PayPal Express Checkout (it executes only if the PayPal authorization is set, and the only place it can be set is line 227 of paypal.php). We're not using PayPal Express Checkout (which is the second option in step 1 of Paypal Module config in the BO) so I'm thinking that we can safely delete that section of code and be fine, but will do some test transactions tomorrow to make sure that doing so doesn't mess anything else up.

 

Our problem is that we can see the box fine in all of our browsers now, *and* our shop isn't live yet (just local host). Unfortunately the real truth will be in the testing with a live shop, with a customer/tester who normally can't see the box.

 

~ Elaine

Edited by artofadornment (see edit history)
  • Like 2
Link to comment
Share on other sites

Update: I removed that whole section of code (line 46-66) as mentioned above and a live PayPal checkout worked fine (tested it with a voucher code just to make sure), so at least it didn't mess anything up with the checkout. However I have no idea if the voucher box will now be viewable to all or not, because I'm able to see it anyway.

Link to comment
Share on other sites

Damn that sounds like it is most likely the correct cause. My customer who could not see the voucher box also didn't have the paypal pay logo on the product pages. So paypal being the cause sounds spot on. I am going to follow up here once i can get my customer to try again after my editing of the code.

Link to comment
Share on other sites

Note that the code I mentioned was in PayPal module 3.4.5, it may not be the same for you (check your version). I just updated to 3.4.8 and will see if the problem code still exists.

 

 

EDIT:

Yep, it's still there in the new version. Which probably means we'll have to remove it every time we update the module, unless they do something to fix it.

 

{if isset($paypal_authorization)}
{literal}

	/* 1.5 One page checkout*/
	var qty = $('.qty-field.cart_quantity_input').val();
	$('.qty-field.cart_quantity_input').after(qty);
	$('.qty-field.cart_quantity_input, .cart_total_bar, .cart_quantity_delete, #cart_voucher *').remove();

	var br = $('.cart > a').prev();
	br.prev().remove();
	br.remove();
	$('.cart.ui-content > a').remove();

	var gift_fieldset = $('#gift_div').prev();
	var gift_title = gift_fieldset.prev();
	$('#gift_div, #gift_mobile_div').remove();
	gift_fieldset.remove();
	gift_title.remove();

{/literal}
{/if}

 

I removed all of it, but you may want to edit it carefully instead if you use PayPal Express Checkout though.

 

~ Elaine

Edited by artofadornment (see edit history)
  • Like 2
Link to comment
Share on other sites

  • 2 weeks later...
  • 2 weeks later...

Note that the code I mentioned was in PayPal module 3.4.5, it may not be the same for you (check your version). I just updated to 3.4.8 and will see if the problem code still exists.

 

 

EDIT:

Yep, it's still there in the new version. Which probably means we'll have to remove it every time we update the module, unless they do something to fix it.

 

{if isset($paypal_authorization)}
{literal}

	/* 1.5 One page checkout*/
	var qty = $('.qty-field.cart_quantity_input').val();
	$('.qty-field.cart_quantity_input').after(qty);
	$('.qty-field.cart_quantity_input, .cart_total_bar, .cart_quantity_delete, #cart_voucher *').remove();

	var br = $('.cart > a').prev();
	br.prev().remove();
	br.remove();
	$('.cart.ui-content > a').remove();

	var gift_fieldset = $('#gift_div').prev();
	var gift_title = gift_fieldset.prev();
	$('#gift_div, #gift_mobile_div').remove();
	gift_fieldset.remove();
	gift_title.remove();

{/literal}
{/if}

 

I removed all of it, but you may want to edit it carefully instead if you use PayPal Express Checkout though.

 

~ Elaine

 

LIFE SAVER! Wasn't working for me and fixed in an instant with this! Thank you so much - saved me hours.

Link to comment
Share on other sites

I was having the vouchers input display missing from my cart as well with the paypal module on.

Prestashop 1.5.4

Paypal Module 3.4.8

 

Removing paypal from the Pages header position seems to make things happy again (Vouchers input displays again), however anyone know if that will cause paypal issues later?

Edited by djmonkeyboy (see edit history)
Link to comment
Share on other sites

I was having the vouchers input display missing from my cart as well with the paypal module on.

Prestashop 1.5.4

Paypal Module 3.4.8

 

Removing paypal from the Pages header position seems to make things happy again (Vouchers input displays again), however anyone know if that will cause paypal issues later?

 

hello if your website is online - the best thing is to paste an url to it, we will try to debug it in browser console

Link to comment
Share on other sites

Sorry for the confusion, my earlier post was letting people know rather than beating up on code, I was able to get the voucher display back by Removing the Paypal module from the Pages header position.

So currently I don't have any issues I can see, but I was curious if anyone knew that removing paypal from Pages header position the cause currently unseen problems later.

Link to comment
Share on other sites

The only way to know for sure is to do a live transaction. Maybe create a "test product" for $0.10 and use free shipping or pickup or something, and run through it yourself with an email address that you don't currently use at Paypal (I have a Gmail account for just such a purpose - that's how I test things).

 

I am somewhat doubtful that PayPal will work properly without being in the header hook however, as the reason most modules have a hook in the header is to pre-load and/or execute code when needed. But try it and see.

Link to comment
Share on other sites

  • 2 weeks later...

Thanks for the extra info. On forge it appears they comment it is Express Checkout related, however I have that toggled off within the Paypal Config options. Also the bug was not browser dependent for me. Additionally it sounds like general confusion on that bug entry as people will want to see the vouchers display if Express Checkout is active or not.

 

There is something subtle going on as I don't see the bug on a fresh install, but one way or another once I start setting up my site on both 1.4.5 and 1.4.5.1 this bug shows up. (No voucher display and delete product buttons do not display on cart page)

 

Taking paypal out of the page header module position seems to "fix" this, but the bug not being present on a fresh install infers it may have something to do with a combination of modules being enabled.

Link to comment
Share on other sites

If you start a inprivate browsing session or equivalent the voucher will appear. Also if you delete all you temp internet files, cache and cookies the voucher will appear. In the link I posted before it states "So you have another page on the same shop processing a payment or you tried ti cancel a payment by clicking the previous page button of your browser instead of clicking on "Cancel and go back to the merchant's website" link." which I think is correct.

 

Then on further investigation I noticed that when the voucher is not available the browser you are using at the time has a block with a paypal cookie ( or whichever payment processing you are using) . I think this is then allowing the code

 

$('.qty-field.cart_quantity_input, .cart_total_bar, .cart_quantity_delete, #cart_voucher *').remove();

 

to be activated.

Edited by hellomobio (see edit history)
Link to comment
Share on other sites

Take at look at http://forge.prestas...browse/PNM-1146

 

This answers the problems to the voucher box not showing in various browsers.

If you start a inprivate browsing session or equivalent the voucher will appear. Also if you delete all you temp internet files, cache and cookies the voucher will appear. In the link I posted before it states "So you have another page on the same shop processing a payment or you tried ti cancel a payment by clicking the previous page button of your browser instead of clicking on "Cancel and go back to the merchant's website" link." which I think is correct.

 

Then on further investigation I noticed that when the voucher is not available the browser you are using at the time has a block with a paypal cookie ( or whichever payment processing you are using) . I think this is then allowing the code

 

$('.qty-field.cart_quantity_input, .cart_total_bar, .cart_quantity_delete, #cart_voucher *').remove();

 

to be activated.

 

WOW! thanks for this, Finally a solution!

Link to comment
Share on other sites

Great!

Forgive me as I'm not too smartz on the code side, would the solution be to strip out the whole /* 1.5 One page checkout*/ code area from /modules/paypal/views/templates/hook/paypal.js

or just the line

$('.qty-field.cart_quantity_input, .cart_total_bar, .cart_quantity_delete, #cart_voucher *').remove();

 

?

Link to comment
Share on other sites

Great!

Forgive me as I'm not too smartz on the code side, would the solution be to strip out the whole /* 1.5 One page checkout*/ code area from /modules/paypal/views/templates/hook/paypal.js

or just the line

$('.qty-field.cart_quantity_input, .cart_total_bar, .cart_quantity_delete, #cart_voucher *').remove();

 

?

 

In my opinion the code is generated when your checkout page thinks a payment process has already been tried and this is in a cookie that is cached. Either clear all your cookies or for example if you have Paypal Checkout activated then click this option and then cancel the express checkout with the url "Cancel and return to <website>". Your voucher field should be visible .

  • Like 1
Link to comment
Share on other sites

Ahh, but if cookie based wouldn't there be a possibly this could be an issue for a return customer?

 

I think only if the return customer hasn't removed the blocked cookie from browser's history. ie hasn't cleared the problem from their last visit.

Link to comment
Share on other sites

Just a thought, it might be a better idea to remove it (if you're not using PayPal Express, that is - if you are you will have to hack that code a bit). Otherwise you'll either have to make a FAQ on the site for customers who don't know to clear their cache in order to see it, and even if you do, you'll still have to answer a lot of emails from customers who want to enter a code and don't see anywhere to put it (and who also didn't think to look at the FAQ). The fewer hoops a customer has to jump through in order to buy, the more likely they'll buy, so IMHO if you can easily ensure that box is always visible to everyone, you probably should.

Link to comment
Share on other sites

Just a thought, it might be a better idea to remove it (if you're not using PayPal Express, that is - if you are you will have to hack that code a bit). Otherwise you'll either have to make a FAQ on the site for customers who don't know to clear their cache in order to see it, and even if you do, you'll still have to answer a lot of emails from customers who want to enter a code and don't see anywhere to put it (and who also didn't think to look at the FAQ). The fewer hoops a customer has to jump through in order to buy, the more likely they'll buy, so IMHO if you can easily ensure that box is always visible to everyone, you probably should.

 

Valid point.

Link to comment
Share on other sites

Despite what the old bug entry says I think it is fair to say this bug should not occur when the paypal module is configured to Not be in express checkout mode. Do we have a new forge bug entry going yet to get this fixed for others in the future?

Link to comment
Share on other sites

hi all.

 

this is freaking me out!

 

i had a free shipping voucher working fine for a while in testing my shop but all of a sudden it started acting oddly. when the one page checkout page loads now in chrome, the voucher section flashes (appears for a second) and then disappears and never returns.

 

i tested it in firefox and in safari (no mie as i am mac user) and in both the voucher appears ok but when it is applied it does NOT provide the free shipping, does not subtract the value of shipping from the total.

 

is "paypal express checkout" one page checkout? is it one and the same?

i really want to use one page checkout

 

for testing purposes, i disabled the paypal module completely and reloaded the page in chrome. firefox and safari and in all 3 the voucher apears BUT when i apply it it does not subtract the value of shipping from the total.

 

i'm lost here!!!

 

could someone go to my shop at http://www.fixgear.info/ and try to see if the "GRATIS MADRID" voucher appears and is able to be applies (subtracts the shipping cost)?

 

thanks,

jez...

Edited by fixgear (see edit history)
Link to comment
Share on other sites

Voucher box displays, however when GRATIS MADRID is applied I cannot see any discount effects.

Perhaps make sure and review your cart rule / voucher settings.

This is when trying as a guest and not signed in.

 

As a side note, I recommend a different main text font. cabinsketch is pretty hard to read when small.

Link to comment
Share on other sites

thanks djmonkeyboy.

 

it is very odd. i have checked everything and the voucher is configured fine.

 

out of curiosity, i changed the voucher action from free shipping to a 10% discount and the discount was applied on the shop.

so, it only seems to not apply the free shipping.

 

any ideas?

 

jez...

 

p.s. yes, i will be changing the font when i go live.

Edited by fixgear (see edit history)
Link to comment
Share on other sites

thanks djmonkeyboy.

 

it is very odd. i have checked everything and the voucher is configured fine.

 

out of curiosity, i changed the voucher action from free shipping to a 10% discount and the discount was applied on the shop.

so, it only seems to not apply the free shipping.

 

any ideas?

 

jez...

 

p.s. yes, i will be changing the font when i go live.

 

 

I would set up a voucher in the cart rules and under the conditions select carrier selection and add the free carrier (that you have made before) removing all other carriers. I assume this is what you want.

Link to comment
Share on other sites

thanks all.

i realized that the voucher indeed was being applied but instead of putting "- amt. of shipping" is simply changed the price next to the courier options to "free". so, it was confusing since at the top where the cart items are and prices, it still showed as charging for shipping but the total was without the shipping so the price in the end was right.

 

anyway, since the free delivery is only in madrid, what i ended up doing was creating a new carrier (a free one) called "GRATIS MADRID" so if the customer lives in madrid, they just choose that carrier for the free shipping.

 

thanks again for the help,

jez...

Link to comment
Share on other sites

i have the same problem the voucher tab is not appearing when i used chrome. When i use Firefox - opera and safari it looks great .

i use the version 1.5.3.1 !!! if i had somewhere a mistake in voucher setup it will not appearing and in the other browsers .!!!!! so somewhere else is the problem and i cant find it. !!!!! if anyone has to say something please help.

Link to comment
Share on other sites

i have the same problem the voucher tab is not appearing when i used chrome. When i use Firefox - opera and safari it looks great .

i use the version 1.5.3.1 !!! if i had somewhere a mistake in voucher setup it will not appearing and in the other browsers .!!!!! so somewhere else is the problem and i cant find it. !!!!! if anyone has to say something please help.

 

See my previous posts

  • Like 1
Link to comment
Share on other sites

See my previous posts

I read the previous post and i take a look to my paypal module and it says on the right to update it. i click on update and it goes to version 3.5.1. after that i make and a clear cash on chrome and it works again and the tab it is on his old position.

Thanks for the info.!!!! and your time

Edited by hairmania (see edit history)
Link to comment
Share on other sites

	var qty = $('.qty-field.cart_quantity_input').val();
	$('.qty-field.cart_quantity_input').after(qty);
	$('.qty-field.cart_quantity_input, .cart_total_bar, .cart_quantity_delete, #cart_voucher *').remove();
	var br = $('.cart > a').prev();
	br.prev().remove();
	br.remove();
	$('.cart.ui-content > a').remove();
	var gift_fieldset = $('#gift_div').prev();
	var gift_title = gift_fieldset.prev();
	$('#gift_div, #gift_mobile_div').remove();
	gift_fieldset.remove();
	gift_title.remove();
	$('#container_express_checkout').hide();
	$('#cgv').live('click', function () {
		if ($('#cgv:checked').length != 0)
			$(location).attr('href', 'http://seemorebreaks.com/?fc=module&module=paypal&controller=confirm&get_confirmation=1');
	});
	$('#cgv').click(function () {
		if ($('#cgv:checked').length != 0)
			$(location).attr('href', 'http://seemorebreaks.com/?fc=module&module=paypal&controller=confirm&get_confirmation=1');
	});

 

It seems that there are 3 possible solutions that have been suggested, some of which I don't think have been tried yet.

 

1.) Unhook PayPal module from Header of pages (Displayheader). Can anyone confirm if doing this messes up a live transaction or not?

 

2.) In the meantime, if you do not use PayPal Express (check your Paypal module config, either you're using Website Payments Standard or Paypal Express) you can safely delete the above code in modules > paypal > views > templates > hook > paypal.js which is lines 46-66, or even just line 56 (this is the line with the "#cart_voucher *').remove();" bit in it.). This definitely works.

 

3.) If you DO use PayPal Express, try deleting just line 56 from the above code, and let us know if that messes up a live transaction or not. It will probably work but it's better to be sure.

 

One thing is clear, updating to a newer PayPal module doesn't get rid of the problem. I tried it, and still had to delete that code to keep the voucher box from vanishing. As to why this is even happening, even though it's PayPal Express specific code that's fouling it up and most of us here aren't even using PayPal Express, is mind boggling.

  • Like 2
Link to comment
Share on other sites

  • 2 weeks later...

I also had this problem in firefox. This issue started for me when I upgraded from prestashop 1.5.2 to 1.5.3.1

I do not remember where I saw a very simple solution to this issue.

I also do not know if this is the right solution. I just know it worked and so far no customer has complained.

 

Thus, the solution is:

Rename the id of the form "# cart_voucher" to "# cart_voucher2" in the file "/ themes / yourtheme / shopping_cart.tpl"

 

Someone check if it works.

Like I said, I do not know if it's the best solution but it worked in 3 shops that I manage.

You can try here: http:/popup2fashion.com

Try the code 028S16DH. It is a voucher for 10% off in use at that store.

The version is 1.5.4.1 with all modules updated.

This shop also uses Paypal express checkout and it works perfectly.

You can see the value of discount on paypal invoice.

Hope it helps.

  • Like 1
Link to comment
Share on other sites

  • 4 weeks later...

i don't understand how to edit the code so this is a huge problem for me. The voucher box shows up just fine on my computer using explorer and chrome. It does not show up on my android phone or Ipad. Yes, they are both enabled in the theme section in the back office. This is a huge problem because I have a big promotion going but then when some people check out, they don't see the voucher box. I use paypal but not express check out. Any help would be very much appreciated because this is costing me money. my site is luckyskunks.com

 

I've read the previous posts but I don't quite understand the solutions mentioned. Could someone please lead me though on EXACTLY what I need to delete, and what I need to add in the code?

Edited by foxygardner (see edit history)
Link to comment
Share on other sites

Thank you so much mbrodigues and vekia for looking at this for me. I really appreciate your time.

 

I wonder if mine is a different type issue then because the box doesn't show up on my android phone or Ipad. I already cleared the cache. Could it be something related to the theme? Both boxes are checked for mobile use in theme section in the back office. Any other ideas?

Link to comment
Share on other sites

  • 3 weeks later...

my site have same problem now

but it occur in Chrome

tested disable paypal module, voucher field appeared.

 

anyone have a good solution about it?

thanks a lot

 

As I said before:

Rename the id of the form "# cart_voucher" to "# cart_voucher2" in the file "/ themes / yourtheme / shopping_cart.tpl"

 

I implemented this solution in at least two stores with prestashop 1.5.4.1.

This may be an alternative solution that so far has worked very well for me.

You can check it in http://www.lisintec.com or http://www.popup2fashion.com.

  • Like 1
Link to comment
Share on other sites

Hello every one,

The same problem here. I'm running 1.5.4.1 and can't see the voucher box in my cart after a update from 1.4.4. Not in chrome, not in FF, not in IE

I tried everything:

1. Unhooked PayPal module from Header of pages (Displayheader).

2. Deleted the code in modules > paypal > views > templates > hook > paypal.js which is lines 46-66.

3. deleting just line 56 (the line with the "#cart_voucher *').remove();" bit in it.)

4. Renamed the id of the form "# cart_voucher" to "# cart_voucher2" in the file "/ themes / yourtheme / shopping_cart.tpl"

 

Can anybody help me with this problem?

Thank you very much

Link to comment
Share on other sites

Hello every one,

The same problem here. I'm running 1.5.4.1 and can't see the voucher box in my cart after a update from 1.4.4. Not in chrome, not in FF, not in IE

I tried everything:

1. Unhooked PayPal module from Header of pages (Displayheader).

2. Deleted the code in modules > paypal > views > templates > hook > paypal.js which is lines 46-66.

3. deleting just line 56 (the line with the "#cart_voucher *').remove();" bit in it.)

4. Renamed the id of the form "# cart_voucher" to "# cart_voucher2" in the file "/ themes / yourtheme / shopping_cart.tpl"

 

Can anybody help me with this problem?

Thank you very much

 

Look at me previous posts. They will help you solve your problems.

Link to comment
Share on other sites

As I said before:

Rename the id of the form "# cart_voucher" to "# cart_voucher2" in the file "/ themes / yourtheme / shopping_cart.tpl"

 

I implemented this solution in at least two stores with prestashop 1.5.4.1.

This may be an alternative solution that so far has worked very well for me.

You can check it in http://www.lisintec.com or http://www.popup2fashion.com.

 

Its works , thank you very much~~~

Link to comment
Share on other sites

This bug is so random it is hard to really fix it correctly, all the fixes here are really more of a work around then a fix.

I just had a test site with this same issue, when you inspected the code the <div> tag was there but the form field was not.

I tried all solutions posted here but none seemed to fix the issue.

 

So I deleted that install and started over, this time the voucher field displays without issues.

 

There are some differences in how I did the upgrade, this time I uninstalled and deleted all non native modules before I started the upgrade.

I also made sure that the Backward compatibility module was installed.

After the upgrade I noticed that Paypal is now version 3.5.7 not the 3.5.5 form the previous install.

I then installed 1.5 versions of all the modules I uninstalled that were available.

I am not sure if the Paypal version had any effect here or if possibly some non native modules were contributing to this error.

 

And there in lies the problem how can you fix something that you can not seem to duplicate from one install to the next.

Link to comment
Share on other sites

  • 1 month later...

If you start a inprivate browsing session or equivalent the voucher will appear. Also if you delete all you temp internet files, cache and cookies the voucher will appear. In the link I posted before it states "So you have another page on the same shop processing a payment or you tried ti cancel a payment by clicking the previous page button of your browser instead of clicking on "Cancel and go back to the merchant's website" link." which I think is correct.

 

Then on further investigation I noticed that when the voucher is not available the browser you are using at the time has a block with a paypal cookie ( or whichever payment processing you are using) . I think this is then allowing the code

 

$('.qty-field.cart_quantity_input, .cart_total_bar, .cart_quantity_delete, #cart_voucher *').remove();

 

to be activated.

 

I am having same problem with chrome, The issue disapears when the cache is cleared, but if i do the same again (buying item etc etc)  then isue appears again, I am not sure what to do with this information that appear to have worked for some people.

 

Do i remove this:

$('.qty-field.cart_quantity_input, .cart_total_bar, .cart_quantity_delete, #cart_voucher *').remove(); 

 

if so where can i find it.

 

regards

Edited by kenkokafe (see edit history)
Link to comment
Share on other sites

I am having same problem with chro,e, I am not sure what to do with this information that appear to have worked for some people.

Do i remove this:

$('.qty-field.cart_quantity_input, .cart_total_bar, .cart_quantity_delete, #cart_voucher *').remove(); 

 

if so where can i find it.

 

regards

 

hey, it will be much easier to do this:

Rename the id of the form "# cart_voucher" to "# cart_voucher2" in the file "/ themes / yourtheme / shopping_cart.tpl"

  • Like 1
Link to comment
Share on other sites

Ok. I tried to do so. initially appeared to have worked. but it does not work for me.

 

i have changed this part. Am i doing right?

 

<td colspan="5" id="cart_voucher" class="cart_voucher">

 

so looks  like

 

<td colspan="5" id="cart_voucher2" class="cart_voucher">

 

thx

  • Like 1
Link to comment
Share on other sites

I tried everthing mencioned, but it didn't work for me. I had to contract a freelancer to do the job. He told me that it had to do with the upgrade from a older version to 1.5.4.1. The freelancer didn't reveal any detail how he fixed it. That would be then the secret of a profesional...

Link to comment
Share on other sites

I tried everthing mencioned, but it didn't work for me. I had to contract a freelancer to do the job. He told me that it had to do with the upgrade from a older version to 1.5.4.1. The freelancer didn't reveal any detail how he fixed it. That would be then the secret of a profesional...

 

maybe you use some different modules, and they hiding this field.

can you share url to your website? i will inspect it.

Link to comment
Share on other sites

it looks like somehow paypal module with express checkout remove voucher code field, but i think that it is related to some modifications, im not sure at all - I was never able to reproduce the problem

 

 

Okay, that is strange indeed. I will be on the lookout for any similar problems in the future so we can narrow down the issue. Thank you again!

Link to comment
Share on other sites

  • 2 weeks later...

it looks like somehow paypal module with express checkout remove voucher code field, but i think that it is related to some modifications, im not sure at all - I was never able to reproduce the problem

 

 

Okay, that is strange indeed. I will be on the lookout for any similar problems in the future so we can narrow down the issue. Thank you again!

 

vekia, which sorts of modifications are you referring to?

 

I encounter this issue with my site (development status so far) as well, and the problem was there before I tried to get all Paypal-related problems sorted out. Happens with the default theme as well, not only my own theme.

 

(What's making things worse for me is, that the paypal module setup only allows Express checkout for me (obviously standard setting for Germany and Austria?? Just don't understand why! And can't see how to get rid of that limitation which causes all sorts of legal implications, as the way the Express checkout is done is highly against corresponding EU laws!).)

 

If you are interested and think it would help to narrow down this issue, I'd provide access to my development environment. Just let me know.

Link to comment
Share on other sites

hi guys, I have done all of the mods mentioned but none work for me, PS 1.5.3.1 and Paypal 3.6.1, even tried deleting the code and changing the voucher code id in the shopping cart.tpl.  I have the Alysum theme, google chrome and shopping_cart.tpl and shopping_cart2.tpl.

 

Honestly, I'm just lost as to what to do or where to look... I just don't understand how with updates there are always issues? 

Link to comment
Share on other sites

my voucher code isn't showing even after trying all the mods and code editing referred to in this topic.  www.especiallyforyou.ie  is the url.

 

any help will be appreciated as I have been struggling for a few days to get this sorted but with no luck.

Link to comment
Share on other sites

  • 1 month later...

I think that affect PS 1.4 too. I just updated my paypal module with the new one updated today and my voucher field disappeared...

If I revert back to my old paypal module voucher field appers again.

 

It was a lot of time I was afraid to upgrade anything in my shop, now I remember why. I will need to spend a lot of time if I want to use latest paypal module in my shop, nothing of the solution in this thread still worked.

 

 

EDIT: I noticed voucher filed disappears only with Firefox (every version) but works correctly with Chrome/Explorer.

Edited by davers44 (see edit history)
Link to comment
Share on other sites

  • 1 month later...

Hi,

I noticed the same thing, Firefox doesn't show the voucher box at all, but others do. My log says that something has changed on the classes/ProductSale.php file, but I can't really see what. Also, in another conversation Vekia told to enable the PS_CART_SALE table, but I don't have one at all! How the vouchers can work anywhere is beyond me. :huh:

Link to comment
Share on other sites

  • 1 month later...

Hi,

i have edited the paypal.js and deleted the line #cart_voucher *').remove();" but now i have some errors.

Sometime a order with paypal is in the BO without state (shipped, waiting for, processing) but show only a "--" and doesn't send me the email confirm order.

 

Now i restore that file and try with Renamed the id of the form "# cart_voucher" to "# cart_voucher2".

 

 

EDIT:

with the cart_voucher2 it work's ok, but i  want know why the solution 1 doesn't work...

so searching on the code and i found a second #cart_voucher *').remove();" in the file

 

modules/paypal/js/paypal.js

 

If i deleted that code also in this file the voucher box appears always. :)

Edited by Tia© (see edit history)
Link to comment
Share on other sites

  • 2 weeks later...

Hello every one,

The same problem here. I'm running 1.5.4.1 and can't see the voucher box in my cart after a update from 1.4.4. Not in chrome, not in FF, not in IE

I tried everything:

1. Unhooked PayPal module from Header of pages (Displayheader).

2. Deleted the code in modules > paypal > views > templates > hook > paypal.js which is lines 46-66.

3. deleting just line 56 (the line with the "#cart_voucher *').remove();" bit in it.)

4. Renamed the id of the form "# cart_voucher" to "# cart_voucher2" in the file "/ themes / yourtheme / shopping_cart.tpl"

 

Can anybody help me with this problem?

Thank you very much

 

same problem here , using PS 1.5.6.2

Link to comment
Share on other sites

  • 4 months later...

Thanks.

Changing "#cart_voucher" to "#cart_voucher2" in the tpl file sorted it for me with Prestashop 1.6 (I think the problem is with the Paypal module anyway not Prestashop).

 

BUT note that there is more than one instance of #cart_voucher. This might be why some people are still stuck.

Link to comment
Share on other sites

  • 1 month later...
  • 1 month later...

Go to themes/your theme/shopping-cart.tpl

 

In the file shopping-cart.tpl, try to find this line: 

<td rowspan="{3+$total_discounts_num+$use_show_taxes+$total_wrapping_taxes_num}" colspan="2" id="cart_voucher" class="cart_voucher">

 

Make this change:

<td rowspan="{3+$total_discounts_num+$use_show_taxes+$total_wrapping_taxes_num}" colspan="2" id="cart_voucher2" class="cart_voucher">

 

This issue is generated by PayPal module.
I always had this issue. Since version 1.5, and always solved changing the cart_voucher id.

I am currently using a Paypal module that automatically charges the customer for paypal fees.
With this module I never had this issue.
Hope it works for you.

Link to comment
Share on other sites

  • 1 month later...

tried everything, all fix available, modified paypal.js, shopping cart.tpl, unhooked paypal from header... NO WAY, the voucher box is still invisible in all browsers, i'm hopeless and in depression..  :unsure:  presta 1.6.0.9, using presta from 3 years, the first time i have this problem. www.lepo.it.

if anyone has suggestions are welcome...

Edited by polxxx (see edit history)
Link to comment
Share on other sites

tried everything, all fix available, modified paypal.js, shopping cart.tpl, unhooked paypal from header... NO WAY, the voucher box is still invisible in all browsers, i'm hopeless and in depression..  :unsure:  presta 1.6.0.9, using presta from 3 years, the first time i have this problem. www.lepo.it.

if anyone has suggestions are welcome...

you also tried the one page checkout?

Edited by Robert Schmitt (see edit history)
Link to comment
Share on other sites

you also tried the one page checkout?

 

With, or without express payment, I also tried to disable the paypal module, and configure the bank payment... Nothing changes, no voucher box: also in “my profile”, in the frontend, missing the icon "your voucher”. www.lepo.it.

 
CART_RULE_FEATURE_ACTIVE = 1
Smarty cache cleared
modified paypal.js
modified shopping-cart.tpl
unhooked paypal from header
 
If anyone has suggestions are welcome.
Link to comment
Share on other sites

Hello... I'm having the same issue and I haven't had luck using the simple method. 

I'm currently using PrestaShop 1.5.6.2 and modifying the code on mycurrenttheme / shopping_cart.tpl from id="cart_voucher" to   id="cart_voucher2doesn't work.

 

1. I'm currently using a module called One Page Checkout for the checkout page and i tried modifying the file shopping_cart.tpl inside the module but still no luck. Using latest chrome version Version 39.0.2171.71 m

 

2. I'm currently using Paypal module ver 3.6.8. Paypal is not hooked to Pages Header (Technical name: Display Header) the only header hook i see is Administration Panel Header (Technical name: displayBackOfficeHeader)

 

Any help would be really appreciated.

 

Shop url http://www.caronboutique.com/mdc

Edited by anpori (see edit history)
Link to comment
Share on other sites

Hello... I'm having the same issue and I haven't had luck using the simple method. 

I'm currently using PrestaShop 1.5.6.2 and modifying the code on mycurrenttheme / shopping_cart.tpl from id="cart_voucher" to   id="cart_voucher2doesn't work.

 

1. I'm currently using a module called One Page Checkout for the checkout page and i tried modifying the file shopping_cart.tpl inside the module but still no luck. Using latest chrome version Version 39.0.2171.71 m

 

2. I'm currently using Paypal module ver 3.6.8. Paypal is not hooked to Pages Header (Technical name: Display Header) the only header hook i see is Administration Panel Header (Technical name: displayBackOfficeHeader)

 

Any help would be really appreciated.

 

Shop url http://www.caronboutique.com/mdc

Finally i solved by re-installing default template, and then back to my custom template. I don't no why, but now works perfectly.

Link to comment
Share on other sites

×
×
  • Create New...