VirtueMart Forum

VirtueMart 2 + 3 + 4 => Plugins: Payment, Shipment and others => Topic started by: camble on September 25, 2014, 17:22:57 PM

Title: Basket confirmation - Thank you for your order page (page which loads PayPal)
Post by: camble on September 25, 2014, 17:22:57 PM
Hi guys,
I've had this problem with several websites in the past and it's driving me crazy!

Basically I've got PayPal as my payment method on a site and everything works perfectly, however when the user has confirmed their order in the basket and it takes them to the page which loads PayPal it always breaks the HTML below the "Please wait while redirecting to PayPal" button. So in this case the footer etc is removed completely from the page.

I have attached a screenshot of the problem so you can see.


Please note that I'm using Joomla 2.5.24 and VM2.6.6 with template overrides for the frontend.


Kind regards
Liam

[attachment cleanup by admin]
Title: Re: Basket confirmation - Thank you for your order page (page which loads PayPal)
Post by: GJC Web Design on September 25, 2014, 17:57:24 PM
you should be on 2.6.10 - http://virtuemart.net/news/latest-news/462-security-release-of-vm2-6-10-and-vm2-9-9b

I also remember this problem a while ago - I think it was a closing div missing in the paypal plug html

sure it is fixed on 2.6.10

Title: Re: Basket confirmation - Thank you for your order page (page which loads PayPal)
Post by: camble on September 25, 2014, 18:21:23 PM
I'm just doing a full backup of the site now before deciding whether to update or to just apply the fix in the link.

With regards to the issue, I've just found your post (http://forum.virtuemart.net/index.php?topic=119835.0) that I assume might cover it, so I'll give that a go once my FTP program has finished downloading the backup.


I searched so many different terms trying to find somebody else who'd had this problem haha!


Thanks
Liam
Title: Re: Basket confirmation - Thank you for your order page (page which loads PayPal)
Post by: camble on September 25, 2014, 18:54:59 PM
Fixed it!

There was a closing </body></html> in the code which once I commented out fixed the page.

if ($this->_method->debug ) {

$html .= '<div style="background-color:red;color:white;padding:10px;">
<input type="submit"  value="The method is in debug mode. Click here to be redirected to PayPal" />
</div>';
$this->debugLog($post_variables, 'PayPal request:', 'debug');

} else {

$html .= '<input type="submit"  value="' . vmText::_('VMPAYMENT_PAYPAL_REDIRECT_MESSAGE') . '" />
<script type="text/javascript">';
$html .= ' document.vm_paypal_form.submit();';
$html .= ' </script>';
}
$html .= '</form></div>';
//$html .= '</body></html>';
Title: Re: Basket confirmation - Thank you for your order page (page which loads PayPal)
Post by: GJC Web Design on September 25, 2014, 22:43:41 PM
that was it - Alatak though has fixed this in later editions