Post by jonesy » Tue Feb 06, 2007 7:28 pm

basically i've got the shop set up now, all is working but i've got two issues/queries.

Ive taken off the paypal feature as we dont want to use that at the time being, but i want the two methods:

Cash on Delivery (already set up and working)

and I want to now add Credit Cards.

How would i go about firstly adding a payment method (i couldnt seem to do it in the admin controls? Admin > Services > Payments

and secondly how do i then show all these options on this page:

http://www.ourpage.co.uk/shop/index.php ... ut_payment

Cheers

New member

Posts

Joined
Fri Jan 19, 2007 5:19 pm

Post by jonesy » Thu Feb 08, 2007 5:27 pm

ive changed all the names to show the correct payment methods, but still not sure how to add a new service.

is it just a case of inserting a new record into the mysql service table, and then create the template for say cards.php and cards.tpl ?

If i do a SELECT * FROM service WHERE type = 'payment';  i get details and the value as:

a:3:{s:6:"status";s:1:"1";s:10:"sort_order";s:1:"0";s:11:"geo_zone_id";s:1:"1";}

whats this mean, do i just add the same thing to my new 'card' record, or do I need to change this?

Any help would be muchly apreciated, then im near the end of my shopping cart stuff.

Thanks

New member

Posts

Joined
Fri Jan 19, 2007 5:19 pm

Post by jonesy » Thu Feb 08, 2007 6:05 pm

Ok, ive figured out how to do it, so this is how you add a new Payment method if you didnt know.

I wanted to add the payment method for allowing credit cards.

So. I copied the file:

shop/catalog/language/english/service/payment/cod.php  and then renamed it to card.php and then:
shop/catalog/service/payment/cod.php and renamed it to card.php aswell.

I change all the values within these files from cod to card and all the function name, and then added the code I needed within shop/catalog/service/payment/card.php (form boxes etc for card information).

I then uploaded these files to both their correct directories, and then went onto the Shop Control Panel.

Here i went to: Services > Payment and clicked on card and then clicked Install. That was it.

Fairly easy todo!

Hope this helps

New member

Posts

Joined
Fri Jan 19, 2007 5:19 pm

Post by chomp » Tue Feb 27, 2007 9:59 am

who is your payment gateway? i'd be interested in your code if it's for paypal pro or authorize.net

New member

Posts

Joined
Sat Feb 24, 2007 7:19 am

Post by flicman » Tue Sep 11, 2007 8:33 am

I've successfully completed the above tutorial (adjusting for the new paths in v.0.7.6) and uploaded the two new files, complete with changes made (COD -> CARD in all instances)  I add the payment module with no trouble, then when I go to enable the new module, I get a Page Could Not Be Found error.  The page that cannot be found is:

/admin/index.php?controller=payment_card&action=install

which, except for the card/cod thing, is the same as installing the COD option, which works fine.

Thanks in advance for your help!

Newbie

Posts

Joined
Tue Sep 11, 2007 8:29 am

Post by flicman » Wed Sep 12, 2007 5:59 am

Well, I got some of it figured out.  For version 0.7.6, here are the files that need changing:

/admin/controller/payment_cod.php
/admin/template/default/content/payment_cod.tpl
/admin/language/english/controller/payment_cod.php
/catalog/extension/payment/cod.php
/catalog/language/english/extension/payment/cod.php

Changing all references to cod/Cod (case-sensitive) seems to be relatively easy, and once all five new files are in place, we're ready to rock.

Or so it seems.  Upon trying to activate the new payment module, I find myself dashed upon the rocks of permissions failure.
TheEvilBackend wrote: Permission Denied!
You do not have permission to access this page, please refer to your system administrator.
More notes as I progress (or regress, I suppose).
flicman's edit wrote: In my haste, I didn't understand Daniel's instructions in another thread:
Daniel wrote:got to admin / user group and add the new page to allow to view and modify.
But now I do - when you create a new module, you have to give yourself permission to edit it.  Once I did that, I managed to get the module enabled immediately.

Now it's time to see about actually connecting to the gateway.
Last edited by flicman on Wed Sep 12, 2007 6:25 am, edited 1 time in total.

Newbie

Posts

Joined
Tue Sep 11, 2007 8:29 am

Post by dsnowden » Wed Sep 12, 2007 7:32 am

Your getting further than me, I can't seem to get passed "Page not found"

Newbie

Posts

Joined
Tue Sep 11, 2007 10:23 am

Post by flicman » Wed Sep 12, 2007 8:01 am

dsnowden wrote: Your getting further than me, I can't seem to get passed "Page not found"
You've got to make sure to change all five of the files listed above - change the filenames from "*cod*" to "*card*" in all five instances and then inside the file change every instance of "cod" to "card" and "Cod" to "Card".  There are a few of these case-sensitive changes, so be sure you do that part right.

Then it'll work.  Well, you still have to give yourself permission to modify the file as described above before you can enable the module.

Of course, there's still nothing like an actual connection to a payment gateway.  I'm hoping that maybe Authorize.net can help me out if no one here has a working script that they're willing to part with.  If only I was a coder, rather than a lucky-not-gifted code-modder.

Newbie

Posts

Joined
Tue Sep 11, 2007 8:29 am

Post by Tokai » Wed Sep 12, 2007 6:20 pm

Thank you for this, i was just asking for this on another thread...many thanks. I want to make a cheque being sent payment...Hopefully it will go okay. any tips always appreciated :)

Spirit Mind Body UK Directory | iPyramidia Holistic Web Design


New member

Posts

Joined
Tue Aug 14, 2007 4:55 pm


Post by jeeremie » Tue Nov 27, 2007 6:49 pm

jonesy wrote: I change all the values within these files from cod to card and all the function name, and then added the code I needed within shop/catalog/service/payment/card.php (form boxes etc for card information).

Hi Jonesy,

Could you tell me what fields you created for the form? Do we need the Swift code, name of the bank...? I really have no idea what  information are necessary for a credit card payment gateway.

Newbie

Posts

Joined
Sat Jul 28, 2007 8:46 pm


Post by mikeb » Tue Dec 11, 2007 3:03 am

"Could you tell me what fields you created for the form? Do we need the Swift code, name of the bank...? I really have no idea what  information are necessary for a credit card payment gateway."

need also, thanks

Newbie

Posts

Joined
Thu Nov 29, 2007 2:49 am
Who is online

Users browsing this forum: No registered users and 1 guest