PAYPAL redirect

  • Posts: 6
  • Thank you received: 0
12 years 5 months ago #29872

Hi at all,

So... my problem is as follows.

I set up as a payment method Paypal.
I configured the module by entering the email address in the required field.

The steps of e-commerce to work regularly until last, where I must confirm what type of paypal as payment for the purchase.
I click next and the page that appears as text "Please wait to be redirected to the PayPal website.
Should you not be redirected automatically after 10 seconds, click the button below "


My problem is that the page is never redirected automatically. To go to complete the payment on paypal you must always click on the button.

How can I fix so that the redirect page on paypal or automatic?

Thank you

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

  • Posts: 81540
  • Thank you received: 13070
  • MODERATOR
12 years 5 months ago #29879

Hi,

That means that you have a javascript error on your pages. You can see the error if you open your browser's javascript error console while on that page.
Having a look at your shop would help too.

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

  • Posts: 6
  • Thank you received: 0
12 years 5 months ago #29918

i trying to trace with firebug but doesn't show any javascript error.

my site is www.worldhorses.it

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

  • Posts: 6
  • Thank you received: 0
12 years 5 months ago #29919

to check the steps, select SELLERIA and SELLE AMERICANE after

www.worldhorses.it/index.php?option=com_...americane&Itemid=110

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

  • Posts: 81540
  • Thank you received: 13070
  • MODERATOR
12 years 5 months ago #29935

Could you try to change the code:
$doc =& JFactory::getDocument();
$doc->addScriptDeclaration("do_nothing( function() {document.getElementById('hikashop_paypal_form').submit();});");
JRequest::setVar('noform',1);
?>
</form>


to:
JRequest::setVar('noform',1); ?>
</form>
<script type="text/javascript">
document.getElementById('hikashop_paypal_form').submit();
</script>

That should avoid the problem (apparently an incompatibility on your website between mootools domready event and jquery).

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

  • Posts: 6
  • Thank you received: 0
12 years 5 months ago #29938

fantastic. it works!!!

Thank you!

Last edit: 12 years 5 months ago by alphascorpii.

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

  • Posts: 78
  • Thank you received: 1
11 years 9 months ago #57183

Which file requires this edit?

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

  • Posts: 81540
  • Thank you received: 13070
  • MODERATOR
11 years 9 months ago #57262

It's the file plugins/hikashoppayment/paypal/paypal_end.php

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

  • Posts: 78
  • Thank you received: 1
11 years 9 months ago #57386

Pardon the confusion, my file doesn't have the described code... Mine is:

<?php
/**
 * @package		HikaShop for Joomla!
 * @version		1.5.8
 * @author		hikashop.com
 * @copyright	(C) 2010-2012 HIKARI SOFTWARE. All rights reserved.
 * @license		GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html
 */
defined('_JEXEC') or die('Restricted access');
?>
<div class="hikashop_paypal_end" id="hikashop_paypal_end">
	<span id="hikashop_paypal_end_message" class="hikashop_paypal_end_message">
		<?php echo JText::sprintf('PLEASE_WAIT_BEFORE_REDIRECTION_TO_X',$method->payment_name).'<br/>'. JText::_('CLICK_ON_BUTTON_IF_NOT_REDIRECTED');?>
	</span>
	<span id="hikashop_paypal_end_spinner" class="hikashop_paypal_end_spinner hikashop_checkout_end_spinner">
	</span>
	<br/>
	<form id="hikashop_paypal_form" name="hikashop_paypal_form" action="<?php echo $method->payment_params->url;?>" method="post">
		<div id="hikashop_paypal_end_image" class="hikashop_paypal_end_image">
			<input id="hikashop_paypal_button" type="submit" value="<?php echo JText::_('PAY_NOW');?>" name="" alt="<?php echo JText::_('PAY_NOW');?>" />
		</div>
		<?php
			foreach( $vars as $name => $value ) {
				echo '<input type="hidden" name="'.$name.'" value="'.htmlspecialchars((string)$value).'" />';
			}
			JRequest::setVar('noform',1); ?>
		</form>
		<script type="text/javascript">
			document.getElementById('hikashop_paypal_form').submit();
		</script>
</div>

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

  • Posts: 81540
  • Thank you received: 13070
  • MODERATOR
11 years 9 months ago #57430

Yes. That modification was added several months ago to HikaShop.
You don't have to do it anymore.

Note that in another thread, in order to solve another problem, I told you to do the reverse modification of this thread. So you need to put it back to as it was before.

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

Time to create page: 0.086 seconds
Powered by Kunena Forum