Pages:

Adding Credit Card Fields and Securing the Checkout Process

ProSam

No avatar

2006-08-31 18:37

Follow these instructions in order to add credit card fields to your QC 1.x.

1. In your "lang" folder find the "Name of fields in forms" section. This is where your field titles will be added. Add the following to that section:

$lang['Credit_card'] =    'Credit Card';
$lang['Credit_expire'] =  'Expiration Date';



NOTE: You can choose to add more fields by adding more lines, do the same with each of the following instructions.

2. Go To: templates/orders_delivery.tpl

Add the following to the arrays at the top (around line 6)

,Array( 'sCreditCard' )
,Array( 
'sCreditExpire' )



Add the following to the table (I added them right after the email but this is up to you):


<tr>
<
th>
$lang[Credit_card]:
</
th>
<
td>
<
input type="text" name="sCreditCard" maxlength="40" />
</
td>
</
tr>
<
tr>
<
th>
$lang[Credit_expire]:
</
th>
<
td>
<
input type="text" name="sCreditExpire" maxlength="40" />
</
td>
</
tr>



3. Go to: core/orders.php

Line 25 add the following (again I added it after the email variables):

$aList['sCreditCard'], $aList['sCreditExpire'],



Around Line 169 add the following (it was line 172 on mine just look for the familiar variables and add them):

$aForm['sCreditCard'], $aForm['sCreditExpire'],



4. Go to: templates/admin/orders_more.tpl

Add the following to the table (again, up to you where to place the code):


<tr>
<
th>
$lang[Credit_card]
</
th>
<
td>
$aData[sCreditCard]
</
td>
</
tr>
<
tr>
<
th>
$lang[Credit_expire]
</
th>
<
td>
$aData[sCreditExpire]
</
td>
</
tr>



5. Go to: templates/admin/orders_print.tpl

Add the following to the table (again, up to you where to place the code):


<tr>
<
td class="label">
$lang[Credit_card]
</
td>
<
td>
$aData[sCreditCard]
</
td>
</
tr>
<
tr>
<
td class="label">
$lang[Credit_expire]
</
td>
<
td>
$aData[sCreditExpire]
</
td>
</
tr>



That's it! Now you will be able to not only collect the info on the site but in the admin you will see it in the orders page.

Now that you are able to collect the credit card info you also want to secure the process. To secure the site seems simple in principle. I have yet to test this but once I have the ssl setup I will give you guys an update.

1. Go to: templates/orders_basket.tpl

Line 4 Replace

<form action="?p=$p&amp;sOption=save" method="post">



With

<form action="https://www.yourdomain.com/index.php?p=$p&amp;sOption=save" method="post">



2. If your site is on a subdirectory replace with:

<form action="https://www.yourdomain.com/subdir/index.php?p=$p&amp;sOption=save" method="post">




If you have questions email me at prosam at gmail dot com and I will try to help.

ProSam

No avatar

2006-09-13 20:01

Securing the cart in the above has been and it works just fine at my cart, see here
http://www.radioavivamiento.com/store/

Add something to the cart and then proceed to checkout you willsee it goes just fine into the secure area.

ProSam

No avatar

2006-09-13 20:03

EDIT:

Securing the cart in the above manner has been tested and it works just fine at my cart, see here
http://www.radioavivamiento.com/store/

Add something to the cart and then proceed to checkout you willsee it goes just fine into the secure area.

Another user emailed me and told me it did not work for him, not sure why but if you do try this method and it does or does not work for you please post your experience.

ata

No avatar

2006-09-14 05:37

nice job ProSam

re-aktor

No avatar

2006-09-17 18:59

works!

Jo

No avatar

2006-09-17 20:36

The credit card fields work...

But I get a message saying your security certificate is not recognised or not configured properly so you might want to fix that.

But in regards to adding the fields to the cart, all seems to work nicely :)

ProSam

No avatar

2006-09-19 15:48

It seems the other users issue has something to do with the fact that he is using a shared ssl certificate, I on the other hand am using a regular single user certificate. So the sahred certificate users might need to look into a work around. But with Secure Certs being so cheap nowadays buying one is well worth it.

One weird thing I noticed was that the cart does not have a State field. I just looked at the demo and it also does not have the state field. Why is that?

pbernal

No avatar

2006-11-06 22:03

will this setup the credit card fields as mandatory?????

ProSam

No avatar

2006-11-30 18:22

Yes it does. All the fields are required.

supershower

No avatar

2007-01-08 03:44

what about credit card for V.2.0 ? :S

zonzo

No avatar

2007-01-09 23:01

Is credit card information stored permanently or is it deleted after orders are processed?

glen

No avatar

2007-01-11 00:58

I was wondering the same thing zonzo.

We were looking at implementing a secure credit card feature too.

But we not so sure about keeping records of peoples CC details on the server.

rvakili

No avatar

2007-03-30 22:30

Hi all,

I have set up the cc payment. 2 things.

Fields are not required.
Valued are not passing to admin order.

Please post as why?

Thanks to all.

Chocolinx

No avatar

2007-10-31 23:38

ProSam are you still updating this Plugin? I've noticed on your site there's a CVV table as well. Can you show us how to do that too?

Also is there a way to make a user choose payment? Like if they pick credit card it goes a credit card payment form and if they pick paypal the payment form will no longer have the credit card fields. Essential having two different payment pages, I think.

Hopefully someone can answer. Thanks!

www.silenttweak.net

webworkspro

No avatar

2008-03-13 22:33

Hi - I've been editing the files, but I can't see that there is a file called templates/admin/orders_more.tpl. Could it be called something else in my version?

Thanks in advance for your response,
Heather

webworkspro

No avatar

2008-03-13 22:39

Added - Actually there's no orders_print either...

webworkspro

No avatar

2008-03-13 23:02

Wow - not my day :(
Everytime i try to change my admin email address, I'm getting a full page of this errors:

Warning: fwrite(): supplied argument is not a valid stream resource in /home/oldcityy/public_html/core/preferences.php on line 134

I rechecked my permissions, and all appropriate directories are at 777.

Hmmmm

d00d

No avatar

2008-03-15 08:39

Are there any payment methods that work with 2.x?

webworkspro

No avatar

2008-03-15 15:43

I guess not (?) I'm having trouble with the language - can anyone direct me where I can download version 1.x?

webworkspro

No avatar

2008-03-15 15:50

Disregard the above - I found it. I think I'll wait to see if there's anything that can be done about the newer version before I downgrade. Does anyone have credit card field instructions for 2.x?

Pages:
Back to top
about us | contact