- Posts: 69
- Thank you received: 0
Worldpay Business Gateway Plugin
Have today been on to worldpay and they have stepped through and tested its interaction with hikashop...
Basically the call back facility in the plugin is functional and does work, where the problem comes in is:
The screen which diverts to worldpay has the following callback value:
www.example.com/index.php?option=com_hik...omponent&lang=en
When worldpay server returns to the above callback url its server protocol throws it out... to solve the problem a 1 second meta refresh needs adding to the callback url page...
Where in the hikashop component would be the best place to add it... ?
Thanks
Please Log in or Create an account to join the conversation.
I'm sorry but I'm not following you.
I don't understand your sentence "its server protocol throws it out."
What do you mean by server protocol ? HTTP ?
What do you mean by throws it out ? You get a blank page ? an error message ?
Please Log in or Create an account to join the conversation.
The way it was explained to me by worldpay after they tested it was:
The worldpay server checks the hikashop return page url before it sends out a message.
It interprets the page as a possible dummy page and aborts.
He says the way round it is to add a meta refresh tag for one second, and the server can confirm the page is genuine.
If you can point me to where I should add the refresh tag I can test it, if it works problem solved and I will report back to you, if it doesnt I can go back to worldpay and ask them to test again.
Thanks
Please Log in or Create an account to join the conversation.
You can do that by replacing the lines:
echo '[OK]';
by:
echo '<html><meta http-equiv="refresh" content="1;url='.hikashop_currentURL().'"><body>[OK]</body></html>';
in the file plugins/hikashoppayment/bf_rbsbusinessgateway.php
But I'm not sure if that's what they want and why ?
Please Log in or Create an account to join the conversation.
Thanks
Please Log in or Create an account to join the conversation.
Have added code to script:
$mailer->Send();
$orderClass->save($order);
echo '<html><meta http-equiv="refresh" content="1;url='.hikashop_currentURL().'"><body>[OK]</body></html>';
if($element->payment_params->debug) {
$dbg = ob_get_clean();
echo '<html><meta http-equiv="refresh" content="1;url='.hikashop_currentURL().'"><body>[OK]</body></html>';
ob_start();
Have tried all sorts of syntax checks on code you have posted but keep getting the same error...
Parse error: syntax error, unexpected T_STRING in /home/thelazys/public_html/tswservices/plugins/hikashoppayment/bf_rbsbusinessgateway/bf_rbsbusinessgateway.php on line 1
When I change back to original script no errors showing.
Appreciate if you could have a look.
Thanks
Please Log in or Create an account to join the conversation.
you should have that:
Please Log in or Create an account to join the conversation.
Have tried the code still getting no joy...
Have contacted worldpay again, this time I got a lady who wouldn't test it but sent me the following information, said if your team wanted to speak direct about the hikashop plug in, no problem, just use the number and reference at the bottom...
Dear Mr xxxxxxxxxxx,
Thank you for speaking with me earlier.
As promised, here is the information needed in order to redirect shoppers back to the originating site:
In order to redirect the shopper back to the originating website you will need to create a customised results page, which either uses a meta-refresh
i.e. <meta http-equiv=“refresh” content=“5;url=http://www.yoursite.com/” />
or has a static redirection URL, using one of methods shown below:
1.) Customised results (resultY.html and resultC.html) page.
- to create a customised results page please which will include a link to allow the shopper to return to the originating website please see: www.worldpay.com/support/kb/bg/customisi...anced/custa7105.html .
Once you have created these pages you will need to upload them via the File Management tool, which can be found within the "Payment Page Editor" which can be located within the "Installations" section of the Merchant Administration Interface (MAI) at www.worldpay.com/admin . For further details on this tool please refer to: www.worldpay.com/support/kb/bg/customisi...anced/custa7003.html
Please note that following:
- when uploading the results pages please ensure that they are named correctly, i.e. resultY.html and resultC.html otherwise the system will ignore the files.
- once you are happy with how these pages appear in the test environment, you will need to select the "copy to production" option within the payment page editor to copy these pages to the production environment.
- it can take up to 6 hours for files to be replicated from test to production, once the the "copy to production" option is selected.
2.) Shopper response:
- the shopper response mechanism your callback script can reply with a page of HTML (which will include a static redirection URL) that will be displayed to the shopper, on WorldPay's servers. For further details on the shopper response mechanism please refer to the link at: www.worldpay.com/support/kb/bg/paymentresponse/pr5402.html
Should you have any queries at all you can call Technical Support at any time on 0870 366 1233 and select option 4 or email support@worldpay.com Please use the incident number 120210-000789 when speaking with us so that we can assist you with this query.
Kind regards,
xxxxxxxxxxxxxxxxx
Technical Support
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
The plug in works ok when submitting data...
Is there a work around I can use with a static callback url...
Thanks
Please Log in or Create an account to join the conversation.
I would recommend to try to use the other worldpay plugin if possible. This one seems to work better.
Please Log in or Create an account to join the conversation.
The only reason I signed up with worldpay was because a plugin was listed...
Please Log in or Create an account to join the conversation.
The plugin submits the data correctly so it can be used...
The plugin callback does not, so an overruling url callback in worldpay to a static page is required...
If the worldpay data is sent to a static page what hikashop code do I need to update the status of an order...
Please Log in or Create an account to join the conversation.
The value <wpdisplay item=MC_callback> has to be added to the worldpay interface Payment Response URL and the Payment Response enabled? needs to be ticked.
Will update on cancelled...
Thanks
Please Log in or Create an account to join the conversation.
That's great to hear that the modification we made allowed the callback to work.
Indeed, we didn't wrote any documentation for that plugin as we didn't develop it.
Let us know how it goes with the cancellation.
Please Log in or Create an account to join the conversation.
Have done further testing with cancelled and spoke to worldpay...
Below is path to guidance on payment message (example of authorised)
www.worldpay.com/support/kb/bg/paymentre...ayment_response.html
Select option : Reference
Select option : Payment Message
The returned transStatus variable is assigned: capital Y or C
Y : successful transaction
C : cancelled transaction
Y is working fine C is not picking up the value.
On selecting cancel in the worldapay interface the page hangs and does not divert.
Thanks
Please Log in or Create an account to join the conversation.
Please try with that plugin package.
Please log in or register to see it.
Please Log in or Create an account to join the conversation.
For both Confirmation or Cancelled to work the Debug mode has to be set to Yes.
Have tested Cancelled and works fine.
Thanks to all involved in sorting it out
Please Log in or Create an account to join the conversation.
I'm going through a similar problem now with Hikashop and Worldpay and I hope your experience can save me a headache.
So is the Worldpay plug in that ships with Hikashop faulty?
Do we just need to install the zip file in this thread (as a regular Joomla plug in?) and add the value <wpdisplay item=MC_callback> into the Payment Response URL in the merchant interface to fix the problem?
Thanks,
Paul.
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.