Jump to content
Sign in to follow this  
rickhudson

Urgent Help Needed with ePDQ Payments

Recommended Posts

Hi Dave

 

There's no real need to specify names.... using

tep_mail('', SEND_EXTRA_ORDER_EMAILS_TO, EMAIL_TEXT_SUBJECT, $email_order, STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS);

...and setting SEND_EXTRA_ORDER_EMAILS_TO to comma separated email addresses with no "<" or ">" works fine, e.g. youraddress@hotmail.com, anotheraddress@hotmail.com.

 

Steve

Edited by mj_superfly

Share this post


Link to post
Share on other sites

Thanks Steve,

 

sussed it out, my fault, I had left some of the code in from when i was trying various way to get it to work before you so kindly steppd in to help. :)

 

Cheers

 

Dave

Share this post


Link to post
Share on other sites

Sorted - emails were going out OK. Thanks again to all. :thumbsup:

Share this post


Link to post
Share on other sites

Has anyone else had problems with epdq over the last 24 hours? I haven't changed anything that i know of and orders which have been approved by epdq are still showing as 'awaiting payment' in osc??

 

Dave

Share this post


Link to post
Share on other sites

Thanks for the quick reply Steve,

 

I'm just uploading the original complete again to see if that sorts it

 

cheers

 

Dave

Share this post


Link to post
Share on other sites

Thats weird, seems it was complete.php.

 

The last change i made to it was the email addresses.

 

Anyway, back to the drawing board... do you know if there is anyway to put epdq into a test mode so I don't have to use my cards eaxh time to test an order?

 

Cheers

 

Dave

Share this post


Link to post
Share on other sites

Annoyingly, there's no test mode. In the manual they request that you put test transactions through to the value of ?11.11 so that they know it's a test, but presumably that's more for anti fraud purposes than anything else.

 

If memory serves, there's also a test Mastercard number, but it is always declined (by design) so it's of limited use. If you haven't got the manual, drop me a PM and I'll email it to you.

 

Steve

Share this post


Link to post
Share on other sites

Thanks steve, that would be useful. I'll drop you a pm.

 

Its working again now and the only thing different in complete.php between the one that didn't work and the one that does is the extra order email thing...

 

The one that works has this...

 

		  // Email ourselves exactly what we e-mailed the customer but prepended with the status.
	$orders_status_check_query_raw = "SELECT os.orders_status_name FROM " . TABLE_ORDERS . " o LEFT JOIN " . TABLE_ORDERS_STATUS . " os on o.orders_status = os.orders_status_id WHERE o.orders_id = '" . (int)$oid . "'";
	$orders_status_check_query = tep_db_query($orders_status_check_query_raw);
	  $orders_status_check = tep_db_fetch_array($orders_status_check_query);

	$new_status_name = $orders_status_check['orders_status_name'];

	  $message = sprintf(EMAIL_TEXT_MERCHANT_EMAIL_MESSAGE, $new_status_name);

	  $message .= $email_order;

	  tep_mail(EMAIL_TEXT_MERCHANT_EMAIL_TO, STORE_OWNER_EMAIL_ADDRESS, sprintf(EMAIL_TEXT_MERCHANT_EMAIL_SUBJECT, ucfirst($order->customer['name']), STORE_ABBR, (int)$oid), $message, STORE_NAME, STORE_OWNER_EMAIL_ADDRESS);
}


//***********************
//***********************
//***********************	  

} else {

 

and the one that doesn't has this

 

		  // Email ourselves exactly what we e-mailed the customer but prepended with the status.
	$orders_status_check_query_raw = "SELECT os.orders_status_name FROM " . TABLE_ORDERS . " o LEFT JOIN " . TABLE_ORDERS_STATUS . " os on o.orders_status = os.orders_status_id WHERE o.orders_id = '" . (int)$oid . "'";
	$orders_status_check_query = tep_db_query($orders_status_check_query_raw);
	  $orders_status_check = tep_db_fetch_array($orders_status_check_query);

	$new_status_name = $orders_status_check['orders_status_name'];

	  $message = sprintf(EMAIL_TEXT_MERCHANT_EMAIL_MESSAGE, $new_status_name);

	  $message .= $email_order;

	  tep_mail(EMAIL_TEXT_MERCHANT_EMAIL_TO, STORE_OWNER_EMAIL_ADDRESS, sprintf(EMAIL_TEXT_MERCHANT_EMAIL_SUBJECT, ucfirst($order->customer['name']), STORE_ABBR, (int)$oid), $message, STORE_NAME, STORE_OWNER_EMAIL_ADDRESS);
	// send emails to other people
 if (SEND_EXTRA_ORDER_EMAILS_TO != '') {
tep_mail('', SEND_EXTRA_ORDER_EMAILS_TO, EMAIL_TEXT_SUBJECT, (int)$oid), $email_order, STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS);
 }



//***********************
//***********************
//***********************	  
}
} else {

 

Thanks for your help (again :) )

Share this post


Link to post
Share on other sites

Hi Joe

I have been using this contribution successfully on two shops for many moons now, I havent bothered updating to the very latest version that you updated in Feb yet.

 

I have suddenly started to receive an error on the initial transfer of the transaction from my shop to EPDQ as follows:-

 

CPI Error

 

 

 

It is not possible to order from the store at this time.

Please contact the merchant for further information.

Error:

Mandatory information not present.

 

Now this has been working fine for months on end and i havent touched the CPI Console, the only changes i have made have been to do with changing prices over to taxable as i am now VAT registered and to compound the issue further it doesnt always error, on some products they sail through ok, but others get the error !!

 

Any pointers you can give, i am waiting until 9 and then speaking to EPDQ Support as well

Share this post


Link to post
Share on other sites

ok Barclays Support say the error they are seeing for these erraneous transactions is as follows:-

 

Charge total amount too long

 

hmmm I am wandering if its some calculation somewhere that isnt rounding down perhaps now that i have bought tax into the equation. Anyone else encountered anything similar ?

 

Edit: Yep its definately related to tax as i made one of the items that had the issue a non taxable good and it went through ok !!

Damn anyone know where i should be looking for where the tax is calculated in oscommerce and what the actual length of the field is that epdq needs

Edited by fuzioneer

Share this post


Link to post
Share on other sites

Fuzioneer...

 

I highly recommend installing FireFox with the Web Developer Toolbar. With it you can easily examine form elements and their values. Whenever something doesn't work, you can quickly inspect what the form is sending Barclays. That way you can easily establish the order value is incorrect, without having to wait for them.

 

Tax is calculated in functions/general.php tep_get_Tax. I hacked that function to bits since I completely removed zones. Can;t help you much with that.

 

And here's another announcement.

 

I'm completely moving away from Barclays' epdq. 18 months of requests have resulted in nothing more but 'that little HTML tweak we agree with has to be proposed to the board and decided up by them old men in grey suits who don't have a clue about the interweb so don't count on it happening anywhere in the foreseeable future'. It's the classic scenario of a large multi-billion company and its inherent bureacracy.

 

So it's World Pay for me. And here's what it offer off the shelve that Barclays is having troubles with even grasping:

 

- AVS responses by default included in POST (fraud prevention anyone?!)

- Verified by VISA response in POST (anyone interested in knowing they aren't liable for this transaction anymore?)

- Remote post auth (no more logging in to an unintuative admin back-end where links should have been buttons and the other way around)

- Remote refunds (no more having to enter all the details again just to give them 2 quid back, take their billing address from osCommerce database and just type the card number).

- No more 'hey dumb customer, you know you just entered you shipping and billing address on our shop? Well guess what, enter them again on Barclays pages because it makes an aweful lot of sense adding 2 pages to the checkout flow just to annoy you and give you 2 extra chances to cock up and give up, abandon the sale etc.' - WorldPay allows you to hide them, reducing the endless stream of checkout pages significantly.

- No more 'look on page 1634 of the third of the 7 manuals we gave you for the answer' - simple online tutorials and responsive support staff who aren't held back by the inertia of a multi billion pound organisation.

- Get a free fully functional test account so you can mock about until you're convinced it all works.

 

My code isn't to a stage yet where I feel comfortable sharing it but it only took me a day and a half to take the current old-ish WorldPay contrib, mix it with the principle of the ePDQ (mainly taking the order before checkout_process and then just updating the status based on the POST response like complete.php) and then coding the post auth into orders.php as well as a refund function.

 

So if, like me, you've had enough of a quickly falling behind payment system (seriously, ClearCommerce and especially Barclays version of it is getting so outdated compared to WorldPay and others) I can highly recommend WorldPay. You can keep Barclays as your bank, just dump their poor payment system and opt for full osCommerce integration.

 

WorldPay should pay me for this advert :) (and Barclays should still pay me for consultancy and this contrib :evil: )

 

So... I'm turning off the topic subscription in this thread and I hope to see you guys and girls soon in a new WorldPay thread. I hope the code I left behind is transaprent enough for you to further develop. And if you do stay with Barclays ePDQ, I hope they get their ass in to gear for you.

 

Ciao for now!

 

PS if anyone is truely ineterested in WorldPay and subsequently able and willing to help me develop the contrib further then please do PM me. But please, only if you can contribute with solid code.


Johan a.k.a. T0PS3O elsewhere.

 

Contributed Barclay's ePDQ Payment Module though not originally mine. Made it work though...

Share this post


Link to post
Share on other sites

ok sussed it

 

I modified the EPDQ.php file as follows:-

 

// $postparams["total"] = $order->info['total'] ;// Graith mod * $currencies->currencies['GBP']['value'];

$totalrounded = round($order->info['total'],4);

$postparams['total'] = $totalrounded;

 

and that seems to do the trick :)

 

Sorry to see you go Joe, might track that new thread to see your contrib on Worldpay as well ;)

Share this post


Link to post
Share on other sites

Hi Joe,

 

I'm interested in how the worldpay rates compare with epdq for you to switch, or have you moved pureley for a functionality reason?

 

Barclays were far cheaper than worldpay when i made the switch from them to epdq 4 years ago.

 

regards

 

Dave

Share this post


Link to post
Share on other sites

Depends on what your turnover is. And how good your negotiation skills are. Never deal with the first bunny answering the phone and never sound too excited. Everything is negotiable. They want your money.

 

I'm not the one who did the rates deal with them but I think they were equally as good as we had with Barclays. Functionality was the main reason indeed.

 

One benefit I forgot to mention will save us some dough as well. We currently have 7 ePDQ accounts on 7 shops because they only allow one URL for the referrer (paying 7 x monthly charge). WorldPay has a different authentication system and you can have many 'installations' within one 'account'. It's just way more flexible. And I hadn't mentioned full control of the lay-out. Compare that to Barclays 1 x image and font colour.


Johan a.k.a. T0PS3O elsewhere.

 

Contributed Barclay's ePDQ Payment Module though not originally mine. Made it work though...

Share this post


Link to post
Share on other sites

Hi there,

 

this isn't really a question with regards the contribution, more a question for those of you using epdq.

 

On my store, I have just noticed that some customers still have a session ID in the URL when they leave the site and go to epdq, this then gives a Not a valid allowed URL error at epdq.

 

This is with force cookie use to off.

 

If i turn force cookie use on then this messes up my cart and I end up with a visitor online constantly as it seems that when one visitor leaves another inherits their details??

 

Also with it turned on no spiders are identified in WOL, even though they are there, they just appear as regular visitors.

 

Any ideas on a solution to this? Has anyone else experienced the same problem?

 

Thanks

 

Dave

Share this post


Link to post
Share on other sites

Hi Dave

 

There's no way your customers should have session IDs in their URL by the time they get through the checkout process - I'd check that sessions are set up correctly in configure.php.

 

Steve

Share this post


Link to post
Share on other sites

Hi Steve,

 

thanks for the quick reply (as usual :) )

 

All I have in configure is

define('STORE_SESSIONS', 'mysql');

 

Is there anything else I should be looking at?

 

Cheers

 

Dave

Share this post


Link to post
Share on other sites
Hi Steve,

 

thanks for the quick reply (as usual :) )

 

All I have in configure is

define('STORE_SESSIONS', 'mysql');

 

Is there anything else I should be looking at?

 

Cheers

 

Dave

 

You could check that the SESSIONS table in the database has data in it - lots of goobledgook looking session ids and data.

 

On MyFirstChopper I can't add anything to my cart if I block cookies, so presumably you have Force Cookies turned on for this site?

 

On DirtBikeBitz I can add stuff to the cart without cookies and the session ID appears when it switches to https:// for the checkout, which is normal, but it should only be there for the first page. I don't want to put in false details, so you should check that it disappears when you go through the checkout process.

 

Any change from http:// to https:// will see the session ID appended to the URL (check out html_output.php), so make sure that the checkout process is secure the whole way through.

 

This might be the problem. If you're not going direct from checkout_confirmation.php to ePDQ, make sure any page in between is https.

 

Hope this helps.

Steve

Share this post


Link to post
Share on other sites

Hi Steve,

 

thanks for having a look, yes i had turned force cookie use to on as a temporary solution whilst I was out for the day.

 

The session gets assigned to the url when you get to the https area and from then on doesn't dissappear. You are more than welcome to test it out and creat an account to see.

 

I'll have a look around and see what else I find

 

Thanks

 

Dave

Share this post


Link to post
Share on other sites

Hi Dave

 

Session ID is now always appended to the url on DirtBikeBitz....

 

I suspect the problem lies with saving the sessions. Did you manage to check whether the SESSIONS table had any data in it?

 

You could also try file based sessions rather than MySQL.... just delete MySQL from the STORE_SESSIONS definition in configure.php and make sure that the correct tmp folder is set in Sessions in the admin Configuration.

 

Ta for now

Steve

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×