Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Nochex APC on 2.3.1


trogette

Recommended Posts

Yesterday I installed the Nochex APC on a vanilla copy of osc 2.3.1, it worked fine in test mode. Then I tried to add it to a copy with a few add-ons added, and when I got to the checkout stage, instead of the cart sending me to this:

 

5407478645_37beef0e8b_m.jpg

(this is sent from a functional version of Nochex APC on a much older site with lots of add-ons, but set to test mode for the purpose of checking the page!)

 

it's sending me to this:

 

5407478487_9e57db2a9c_m.jpg

 

So I thought 'right, let's start again from scratch' and did the vanilla thing again, and now I don't even get the top version on the vanilla + nochex install. Does anyone have any idea what would cause this? Thanks!

Link to comment
Share on other sites

Right, I'm doing a step-by-step installation from scratch again with the payment pages and APC add-on from 2006. Fresh copy of osc 2.3.1 named nochex. The second sql statement in the file nochex_apc.sql isn't compatible with the structure of the table order_status in 2.3.1 so I manually added them in PHPMyAdmin with the resulting sql:

INSERT INTO `orders_status` (
 `orders_status_id` ,
 `language_id` ,
 `orders_status_name` ,
 `public_flag` ,
 `downloads_flag` 
)
VALUES (
'50000', '1', 'Nochex Processing', '0', '0'
), (
'50001', '1', 'Nochex Authorised', '1', '1'
);

 

This time around, using Beyond Compare:

  • I'm adding all the files including the admin panel box even though it's not compatible with 2.3.1 and I had decided to simply take the link for the transactions page and place it in the Tools box, if I can persuade the front end to work properly I'll come back and change this later.
  • I'm adding the call to the Nochex APC box in admin/includes/column_left.php as an include rather than a require, to match the other box calls in the file.
  • I've added the defines to the admin/includes/database_tables.php, admin/includes/filenames.php, admin/includes/languages/english.php, includes/database_tables.php and includes/filenames.php files.
  • I'm ignoring the edits to includes/modules/downloads.php, account.php and account_history.php as it appears the flag settings in the order_status table for visibility and download status supercede the need to manually add the order status 'Nochex Processing' to the statements in order for orders with that status to be ignored by those files.
  • I'm editing checkout_success.php leaving in the apparent typo of 'nochex_reponse' just in case it's that that's causing my problem!
  • I'm installing the module, setting the checkout mode to 'test' and setting a random email address in case it's having issues with my actual nochex email address.

 

It's still sending me to nochex seemingly without passing any information other than the email address. Does anyone have any suggestion as to what's causing this?

Link to comment
Share on other sites

  • 2 months later...

Right, I'm doing a step-by-step installation from scratch again with the payment pages and APC add-on from 2006. Fresh copy of osc 2.3.1 named nochex. The second sql statement in the file nochex_apc.sql isn't compatible with the structure of the table order_status in 2.3.1 so I manually added them in PHPMyAdmin with the resulting sql:

INSERT INTO `orders_status` (
 `orders_status_id` ,
 `language_id` ,
 `orders_status_name` ,
 `public_flag` ,
 `downloads_flag` 
)
VALUES (
'50000', '1', 'Nochex Processing', '0', '0'
), (
'50001', '1', 'Nochex Authorised', '1', '1'
);

 

This time around, using Beyond Compare:

  • I'm adding all the files including the admin panel box even though it's not compatible with 2.3.1 and I had decided to simply take the link for the transactions page and place it in the Tools box, if I can persuade the front end to work properly I'll come back and change this later.
  • I'm adding the call to the Nochex APC box in admin/includes/column_left.php as an include rather than a require, to match the other box calls in the file.
  • I've added the defines to the admin/includes/database_tables.php, admin/includes/filenames.php, admin/includes/languages/english.php, includes/database_tables.php and includes/filenames.php files.
  • I'm ignoring the edits to includes/modules/downloads.php, account.php and account_history.php as it appears the flag settings in the order_status table for visibility and download status supercede the need to manually add the order status 'Nochex Processing' to the statements in order for orders with that status to be ignored by those files.
  • I'm editing checkout_success.php leaving in the apparent typo of 'nochex_reponse' just in case it's that that's causing my problem!
  • I'm installing the module, setting the checkout mode to 'test' and setting a random email address in case it's having issues with my actual nochex email address.

 

It's still sending me to nochex seemingly without passing any information other than the email address. Does anyone have any suggestion as to what's causing this?

Link to comment
Share on other sites

Just spent a couple of days trying to get the Nochex APC contribution working on osCommerce RC2a. A few pointers which might help folk...

 

I started with the Contribution 2280 - using the download dated 15th December 2006 as a starting point.

When updating the database using the SQL file there was an error - as RC2a has more columns in the table order_status (5 instead of 3), so modified the code as follows:

 

Part of nochex_apc.sql

 

/*Table data for table `orders_status` */

INSERT INTO `orders_status` VALUES (50000, 1, 'Nochex Processing', 0, 0);

INSERT INTO `orders_status` VALUES (50001, 1, 'Nochex Authorised', 1, 1);

 

 

Also in the download is a text file checkout_success.txt containing the instructions to modify catalog/checkout_success.php

this has a typo.

this line:

if ($nochex_apc['nochex_reponse']=='AUTHORISED') {

should read:

if ($nochex_apc['nochex_response']=='AUTHORISED') {

 

 

There is still a problem in getting downloads sorted as described in the downloads.txt file which modifies this file:

catalog/includes/modules/downloads.php

This is because the original code (around line 25) differs quite a bit in RC2a from that described in downloads.txt, so I left it.

 

 

 

Regarding your Nochex account - make sure you ring/email Nochex Customer Services after activating your account and tell them you want APC enabled.

 

I was using a shared SSL and had to set the Success URL/Cancel URL and Callback URL settings to this format:

 

https://webxx.securedserver.com/yourdomainnamehere.com/catalog/checkout_success.php

https://webxx.securedserver.com/yourdomainnamehere.com/catalog/checkout_payment.php

https://webxx.securedserver.com/yourdomainnamehere.com/catalog/nochex_apc_handler.php

 

Until I did this the customer would go through the Nochex pages ok but on returning to the osCommerce site the order had not been processed correctly, the item(s) were still in the shopping cart and the order status was 'Nochex Processing' rather than 'Nochex Authorised'

Link to comment
Share on other sites

  • 3 months later...

I've come back to this, I think it's alright so far (I need to figure out a bit of add-on integration) but I'm wondering if there's an issue with using it on more than one site considering the need to enter the callback/cancel/success URLs in the payment page.

Link to comment
Share on other sites

I rang nochex and got an answer that really should be in the payment page setup instructions somewhere!

 

So the process is this:

  • log into nochex, and select 'payment page setup' from the menu at the bottom of the control panel page
  • click the button to 'add merchant id' and set up the page for each website you want to connect to your account (colours, logos etc plus the callback/cancel/success links for the 'site)
  • install the nochex APC module including the database changes (doh!! lol) and any adjustments that other add-ons make to checkout_process
  • enter the merchant id but *not* the nochex account email (unless that is actually the one you've used to set up the page) in the appropriate place in the nochex module set-up

 

Now it's working well enough, but I have a couple of back-end problems. Firstly, despite me ticking the box to tell it not to subtract before payment is received, that's exactly what it's doing (I have QTPro installed, and I assume that's affecting it as it appears to be subtracting the attribute stock correctly, but before payment, and then subtracting the product stock, but not the attribute stock, when the payment is made, it's triggering the QTPro Doctor error message.) Secondly, it's still saying in the order details that it's emailing customers on 'nochex processing,' though it actually isn't. Thirdly, when a payment is refunded, it doesn't change the status on the order at all, though I'm not sure if nochex gives APC feedback on refunds.

 

I'm sure there was another problem but I can't remember what it was now *frown*

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...