Jump to content

Offline Credit Card Module (new version 3.01.production)


Recommended Posts

  • Replies 417
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Popular Posts

The version mentioned in this thread is OUTDATED and has been REPLACED by version 3.01.production. Please see http://www.prestashop.com/forums/viewthread/58273/third_party_modules/module_offline_credi

Posted Images

Sam, to retrieve the credit card detail... read reply #94 by lordanthony

From there you can view the card details for a particular order, however i also see as error message just above the card details.

Share this post


Link to post
Share on other sites
After installing, adding an order using the module and adding ... "lordanthony" code above.

On Back office>Orders page, I can view the credt card details, however just above that is an error mgs..

Notice: Undefined index: remData in /public_html/modules/creditcard/creditcard.php on line 244

I get this error in 1.1 3b

Any ideas ?


I just added the following isset conditional on line 244ish on the creditcard.php file

           if (isset($_GET['remData'])){

           if(intval($_GET['remData']) == 1)

               $this->removeDataString($id_order);

           }



Might not be the best way to sort but a workaround until the next release

Just stumbled across prestashop tonight. It has a lot of potential - much faster than magento.

Share this post


Link to post
Share on other sites
This problem can be corrected by adding

/* SSL Management */
$useSSL = true;

in payment.php

The next thing is to make the user go back to regular http after that…


I'm quite new to Prestashop and loving it so far. I installed this module (v2.0.5) and it works like a dream.

I too had the SSL issue, which I resolved using the above hack.

However, I can't achieve a return to regular http. I tried setting useSSL to false in order-confirmation.php (which is the next page shown after payment.php) but that doesn't seem to have an effect.

Has anyone else solved this?

Share this post


Link to post
Share on other sites

I installed v2.0.5 and I’m using v1.1.0.3
Everything working ok but when I tested it in the front page I in counted a problem during checkout when I got to the payment page and filled all the info
And clicking 'Submit Order’. it does nothing it bring me back to the same page http://xxx .com/modules/creditcard/payment.php and the order does not registered
Any Idea?? I really can use this module
Help

Share this post


Link to post
Share on other sites

The data is encrypted before being stored in the database. It uses the blowfish algorithm for this encryption.
You will need to change line 181 and 250 (encrypt and decrypt, respectively) to accomplish the transition to RSA. You will also need to include some type of RSA function for the code to use.

Quick question, why RSA? Are you talking public/private key encryption with RSA? If so, it is something I looked at and threw out because of the difficulty of use, and the fact that private RSA keys are very hard to remember (and often get written down, leading to LESS security).

Any questions, let me know!
--Kevin Klika

Share this post


Link to post
Share on other sites

this is the 4 time I posted below:
I installed v2.0.5 and I’m using v1.1.0.3
Everything working ok but when I tested it in the front page I in counted a problem during checkout when I got to the payment page and filled all the info
And clicking ‘Submit Order’. it does nothing it bring me back to the same page http://xxx .com/modules/creditcard/payment.php and the order does not registered
Any Idea?? I really can use this module
Help

I really need some answer for the above!!!
go to www.motosportgear.com and check it

Share this post


Link to post
Share on other sites


The next thing is to make the user go back to regular http after that...

I'm quite new to Prestashop and loving it so far. I installed this module (v2.0.5) and it works like a dream.

I too had the SSL issue, which I resolved using the above hack.

However, I can't achieve a return to regular http. I tried setting useSSL to false in order-confirmation.php (which is the next page shown after payment.php) but that doesn't seem to have an effect.

Has anyone else solved this?


I am also looking for this solution. going back to the non http site after using this module causes IE to throw the "This page contains both secure and non secure items. Do you want to display the non secure items?" error message. Google Chrome and Firefox have similar but less obvious warnings. What is causing this?

Share this post


Link to post
Share on other sites

I work with 3 alowed currencies, but the module only shows the first currency selected without option to select another.

[sOLVED] Also it not accept translations of words that have accent, like 'card' to 'cartão'. Thus the previous word in English prevails. I addded thiscode:

<?php header("Content-Type: text/html;  charset=ISO-8859-1",true); ?>



And can I modify the your code below in order to translate months to portuguese?

{html_select_date    prefix='expDate_'    start_year='-0'  end_year='+15'  display_days=false      year_empty="Year"  month_empty="Month"}

Share this post


Link to post
Share on other sites

Does anybody know how to get the credit card information to display so that i can manually process the orders.

If it helps i am using Prestashop version 1.1.0.5 and Credit card module version 2.05.

Share this post


Link to post
Share on other sites

Hello first of all thanks for this module, it will come in handy. I am however having the same issue of not seeing the CC info once an order is processed in the Order Details.

Also, I know this is a pain but it might be a good idea to add a SSL login from the order detail screen in order to view the CC data. I know Digishop has a feature like that. I'm really new to PS so maybe it isn't necessary and I just need to turn on SSL for the entire admin section. I will search the boards to see if that's possible.

thanks
-IC

Share this post


Link to post
Share on other sites

How I can know if the credit card is a Visa, Mastercad, America Express or another one?
When the customer fills the information of the card, a flag is shown, but which type of card in Admin Orders is not shown.

Share this post


Link to post
Share on other sites
How I can know if the credit card is a Visa, Mastercad, America Express or another one?
When the customer fills the information of the card, a flag is shown, but which type of card in Admin Orders is not shown.


As a rule of thumb, American Express begin the number with 3, Visa begins with 4, Master Card begins with 5, and Discover begins with 6. Hope I answer your question.

Share this post


Link to post
Share on other sites

Just FYI: I have not tested this module with the newest versions of PS.
To retrieve CC information, just click "Click here to reveal information" in the order review screen.
I will add card type display to the next version, when I get around to it, as well as the ability to easily edit the title of Year/Months in the date select, as well as multiple currencies.

Anything else?

--Kevin

Share this post


Link to post
Share on other sites
Just FYI: I have not tested this module with the newest versions of PS.
To retrieve CC information, just click "Click here to reveal information" in the order review screen.
I will add card type display to the next version, when I get around to it, as well as the ability to easily edit the title of Year/Months in the date select, as well as multiple currencies.

Anything else?

--Kevin


Perhaps the option of payment in 2x 3x…?!

Share this post


Link to post
Share on other sites

When my customer purchase more than $ 100,00 I accept that this amount is divided in up to 4 times. In case that the customer buys more than $200,00, I accept that the amount is divided in up to 6 times….and so on.

Share this post


Link to post
Share on other sites

I have installed the module and all nearly working fine
Without ssl enabled it works fine
with ssl enabled the pages stay in ssl until you click on the pay by credit card image and then it goes back to not being secure transaction.

Any help would be apreciated

Share this post


Link to post
Share on other sites
  • 2 weeks later...
Just FYI: I have not tested this module with the newest versions of PS.
To retrieve CC information, just click "Click here to reveal information" in the order review screen.
I will add card type display to the next version, when I get around to it, as well as the ability to easily edit the title of Year/Months in the date select, as well as multiple currencies.

Anything else?

--Kevin


Hi, firt of all congrats and thanks for developing this module its looking great!. As a previous user stated, even with the code hack I cannot see the credit card data. I tried your suggestion above of finding the "Click here to reveal information" and at least where I though it should be Backoffice>>orders>>order xxxxxx. I did not find said option. Am I looking in the right place? If so, is there any other thing I can try to display the credit card number?

Thanks for your time!

Share this post


Link to post
Share on other sites

THIS module will not work without a hack in PS version 1.1!!! The developers forgot a hook in the back office that allowed me to display the data... It will be available in the next release - the bug has been fixed in SVN as well. I will post a detailed How-To on fixing the bug yourself in a while.

--Kevin

Share this post


Link to post
Share on other sites
THIS module will not work without a hack in PS version 1.1!!! The developers forgot a hook in the back office that allowed me to display the data... It will be available in the next release - the bug has been fixed in SVN as well. I will post a detailed How-To on fixing the bug yourself in a while.

--Kevin


Ok. Thanks for your patience and work.

Share this post


Link to post
Share on other sites

To enable this module in prestashop v1.1:

On line 386 of /yourPSDir/yourAdmindir/tabs/AdminOrders.php, you will see this:

       /* Display invoice information */
       if ($currentState->invoice OR $order->invoice_number)
       echo '

id.'&pdf;"> '.$this->l('Invoice').'
id.'&pdf;">'.$this->l('Invoice #').''.Configuration::get('PS_INVOICE_PREFIX', intval($cookie->id_lang)).sprintf('d', $order->invoice_number).'

'.$this->l('Created on:').' '.$order->invoice_date.'

';



Right after this code, add the code below:

    
       if (($hook = Module::hookExec('invoice', array('id_order' => $order->id))) !== false)
           echo $hook;



Save, and refresh your order information screen.

As confident as I am in my programming, I take no responsibility for anything that happens through this 'upgrade' process.

With that said, have a nice day, good luck!

--Kevin

Share this post


Link to post
Share on other sites

I did it on my website - it worked like a charm. I reported it to the PS developers, they fixed it in SVN. I also had another user of this module report success with this fix just yesterday. :)

--Kevin

Share this post


Link to post
Share on other sites

I've had no trouble with the module EXCEPT that I wanted to know if there was any way to get an email notice when a purchase is made with the module. If it's supposed to be doing it, I'm not getting one.

Share this post


Link to post
Share on other sites
I've had no trouble with the module EXCEPT that I wanted to know if there was any way to get an email notice when a purchase is made with the module. If it's supposed to be doing it, I'm not getting one.


kevin (Ox40) at moment is working in some upgrades. He will add card type display to the next version, as well as the ability to easily edit the title of Year/Months in the date select, as well as multiple currencies.

I hope this occurs as soon as possible. This free module is very important to me.

Share this post


Link to post
Share on other sites

Any News about the multicurrency version?
I want to use it with swedish Kronor and if I understand this correctly, is not possible until the new release/upgrade. Or can I tweak the 2.0.5 version so I can use it with swedish currency?

Thank you for developing this module!

Share this post


Link to post
Share on other sites

It currently does not work to accept two different currencies. It will work to accept whatever your default currency is. I have not tested my latest development version because I dont have my shop set up yet to test it on, but multi-currency support is definitely in the works and will come out shortly.

Share this post


Link to post
Share on other sites

I am the original creator of this module, I did not design it to send an email. It is an option I currently have not looked into, nor is it enabled in the module. So, I am not sure how the person who posted that thread was able to 'set it up to use order_conf' email template. Either way, it is not set up to the the template. I will add it to the list of features I am working on. Look for the newest release in about a week.

--Kevin

Share this post


Link to post
Share on other sites

Hello again,
A minor set back for this module, atleast for Swedish users. I called my bank and asked about this way of offline payment. First of all they didn't recomend offline payments, not so suprising. But the more urgent issue is that some debit-/ creditcards do not accept offline payments without security code (pin-code that you use at your local ATM etc.) With that said, the customer would either have to give their PIN-code to you (not so likely) or fysicaly be present in your store. This is due to the increased security demands from banks and creditcard issuers, like VISA and Mastercard.
Which cards that doesn't accept offline payments was not known by the support personel but they just said that it has been a problem and will continue to be problem until the creator of my/your terminal comes up with a solution (in this case BABS). Has anyone had a problem with cards not beeing accepted?

Share this post


Link to post
Share on other sites

Hi Kevin
I set this module up for my client & the issue we had with the mail variables was simply resolved by adding $mailvars to the validateOrder function
here is a temporary solution until you re-write the mail template variables.

Line 186

$this->validateOrder($cart->id, $this->idOrderState, $total, $this->displayName, null, $mailVars, $currency->id);



of course it is also possible to set additional mail variables in the $mailvars array.

within the PaymentModule.php you will find the arrays are merged
$data = array_merge($data, $extraVars);

$data is the default PS Variables & $extraVars
in this case is $mailVars in the validateOrder function.

Share this post


Link to post
Share on other sites

hi kevin,
just installed the 2.0.5 version on a 1.1.0.5 prestashop, but when i try to process a payment i get an error:

validation.php was not found on the server

is this the latest version or is there an up to date version of this module?

thanks

Share this post


Link to post
Share on other sites

The latest version of this module is attached to the first page of this post. There should not be an error like that occurring any more, I have removed validation.php from the source and put the necessary code in the creditcard.php file itself.

--Kevin

Share this post


Link to post
Share on other sites

i have removed and reinstalled the files you supplied and still no luck.

this is very strange, i have the latest version as you say 2.0.5 and have added it to the modules folder on prestashop

but still get this validation.php error. i will PM you the store where this is implemented.

I am using Prestashop 1.1.0.5 if this could be the problem?
CHeers
Norman

Share this post


Link to post
Share on other sites

yes 100% sure. i just downloaded it again from your first post and removed the folder from my server and unzipped this one. here is the directory listing:

drwxr-xr-x 3 apache apache 4096 Feb 16 23:55 .
drwxrwxrwx 71 apache apache 4096 Feb 16 23:55 ..
-rw-r--r-- 1 apache apache 2478 Sep 5 15:25 admin_form.tpl
-rw-r--r-- 1 apache apache 24890 Sep 5 15:25 creditcard.jpg
-rw-r--r-- 1 apache apache 16626 Sep 5 15:26 creditcard.php
-rw-r--r-- 1 apache apache 6792 Sep 5 15:25 es.php
-rw-r--r-- 1 apache apache 6714 Sep 5 15:25 fr.php
-rw-r--r-- 1 apache apache 5508 Sep 5 15:25 functions.js
drwxr-xr-x 2 apache apache 4096 Sep 5 15:25 img
-rw-r--r-- 1 apache apache 309 Sep 5 15:25 index.php
-rw-r--r-- 1 apache apache 639 Sep 5 15:25 invoice_block.tpl
-rw-r--r-- 1 apache apache 657 Sep 5 15:25 logo.gif
-rw-r--r-- 1 apache apache 390 Sep 5 15:25 payment.php
-rw-r--r-- 1 apache apache 286 Sep 5 15:25 payment.tpl
-rw-r--r-- 1 apache apache 4728 Sep 5 15:25 payment_execution.tpl
-rw-r--r-- 1 apache apache 850 Sep 5 15:25 payment_return.tpl

the date should match the one you uploaded?

and I still get this validation.php error.

cheers
norman

Share this post


Link to post
Share on other sites

I've just installing this module, but i've some questions :

1 - How to specifie (the customer) the type of credit card ?

2 - How can I know (the administator) the credit card number enterred to do the manual online payment?

3 - In Mysql, where are stocked the payment informations?

Thank's a lot for your help and sorry for my english...

Share this post


Link to post
Share on other sites

Does anyone have an ideas on how to get the email notification to work on the credit card module? I have made the changes I found here. I am running 1.1 with no luck.

What I have done to try and make this work is add $mailvars to the validateorder function on line 186 in creditcard.php and this has not work.

If anyone could provide any help I would appreciate it.

Share this post


Link to post
Share on other sites

Or do I need to add something to the creditcard.php to defind $mailVars like this that I found on the validation.php for the bankwire form.


$mailVars = array(
'{bankwire_owner}' => Configuration::get('BANK_WIRE_OWNER'),
'{bankwire_details}' => nl2br(Configuration::get('BANK_WIRE_DETAILS')),
'{bankwire_address}' => nl2br(Configuration::get('BANK_WIRE_ADDRESS'))
);

Share this post


Link to post
Share on other sites

Hi Kevin,
Any luck with the validation.php problem on 1.1.0.5? I have the correct version, haven't I?
I not sure what else to do to get it working, but to setup a new instance and see if this will work.
Please advise.
Many thanks
Norman

Share this post


Link to post
Share on other sites

A new problem: Order Failed
Error: Access to restricted URI denied code 1012
in jquery.pack.js

has something to do with the eval function, looks like it is called at some point by creditcard.php...

this is on my 1.1.0.5 install and on the SVN version.

Share this post


Link to post
Share on other sites

Hi everybody,

I loved this module, I have read the earlier posts and have downloaded the cc module v 2.0.5 and it does validate the cards well and there was no stack or hack error reported. My only concern was when the card details were submitted, at the back-end of the site I could see that Mr (X), has paid using a card but it says Awaiting credit card validation. I do have an option of changing status of payment as payment accepted etc. But I do not know where will I get the card details of the customer to process it in order to receive the money in my account. I do not know if there is something really silly that I have missed. Kindly do point me in the right direction.

Thanks a lot in advance,

Best Regards,

Cyrus

Share this post


Link to post
Share on other sites
  • 2 weeks later...

Kevin,
Happy to report that the module works like a gem (2.0.5 on ps1.1)! May I recommend that you add the note of AdminOrder.php update to the top of the thread - will save time. Thanks for contrib!

Just a note - in Europe we have cards called maestro (like debit cards but "special") which require the "valid from date" and "issue number" given to be processed. The issue number is of max 3 digits. Is there any chance that you add those?

I have made the changes to creditcard.php and payment_execution.tpl to add the fields. See attached.

If you would like to include in mainstream distribution please feel free ;-)

Improvements needed in the check up (I have not done yet) - to make the Valid From Date and Issue Number fields required when the card type is recognized as Maestro...

Vlad

from_issue_update.zip

Share this post


Link to post
Share on other sites

How are you getting spammed? It _HAS_ to be a valid CC number to be processed -- are you sure those aren't orders?? ;) I have no current plans to work in a captcha as the module is almost it's own captcha. What kind of stuff are you getting spammed? It just doesnt make sense to me :-]

--Kevin

Share this post


Link to post
Share on other sites

Hi,

They definately aren't orders. And they appear to be valid credit card numbers, however when they are processed, they all are declined. It would appear that the cards either no longer work or have been registered stolen.

The items that are ordered are always Nikon and always for about £400-£900. The delivery address is often different from the billing address, and the shipping address is nearly always London (shawbury court). When you try and contact the mobile number provided the mobile is ALWAYS turned off (we tested this theory several weeks running on several customers phones, always fwith the same responce!)...

So definately spam... who could be doing that?

Cheers,
Sam

Share this post


Link to post
Share on other sites

Hi,

I have installed this module and its looks brilliant, the only trouble I am having is when you click submit I get a blank page with Invalid new order state message at the top of the page when its should go to the order confirmation page. Any ideas as why this is happening? The cheque payment page works fine with me getting a order confirmation after clicking submit.


Thanks,

Mark.

Share this post


Link to post
Share on other sites

Try uninstalling and reinstalling. This module creates a new "Order Confirmation Pending" order state upon installation and saves the ID of the new order state to the configuration. If any part of that fails, it will give you that error message.

--Kevin

Share this post


Link to post
Share on other sites

Hi There, Sorry for my english!
I have a question... i have instaled the module and works great! But i can not find the credit card data number in the back pannel.

I have the shiping data, the phone number.. and evry thing. But i dont have the credit card number that the user place in the form. Can you tell me guys, were is that data?
TNKS!!!!

Share this post


Link to post
Share on other sites
Hi There, Sorry for my english!
I have a question... i have instaled the module and works great! But i can not find the credit card data number in the back pannel.

I have the shiping data, the phone number.. and evry thing. But i dont have the credit card number that the user place in the form. Can you tell me guys, were is that data?
TNKS!!!!


Look in AdminOrders.php

and find this line

/* Display customer information */



and put this code above it

// display card module
       $hook = Module::hookExec('invoice', array('id_order' => $order->id));
       if ($hook !== false)
       {
           echo '
'.$hook;
       }



maybe make a backup of the file before, so if you make a mistake you can try again from new. ;-)

Share this post


Link to post
Share on other sites

I have just come back for my third try with PS and found that 1.1.05 looks quite good. Not why I'm posting here, however.

I just have to say that if you are not storing the CC data in SSL you are in serious violation of your merchant agreements and subject to extremely heavy fines.

Here is what one cart has to say about it -

Enable CCV in Offline order form? (default is no, and for very good reasons)

WARNING: Do not enable this unless you have good reason, or have an approved server that meets lawful security requirements (according to your credit card merchant account agreement and governing laws in your country). It could be against the law and subject you to criminal and civil liabilities of an extreme magnitude including but not limited to jail time, full disclosure if data or server is compromised or might have been, payment of very high fines and legal fees, embarrassment, and distrust from the public. By enabling this feature, you willingly agree to the following: that you, your company, and all concerned/affiliated agents, companies, customers, officers, et al hold The Cart and all affiliated divisions, agents, companies, officers, et al harmless from any and all legal action as well as protect the above from all other liabilities or punitive damages arising from your misuse of client data. Furthermore you, of your own freewill and desire, knowingly endanger your customers and their personal data, and furthermore you are also acknowledging the fact that you are purposely, and of your own freewill and desire, ignoring the outlined laws and procedures set forth by credit card companies and the laws of the USA and all governing localities and municipalities (should you be subject to the laws of the US).

This is me again -
If your website is ever audited by one of the card processors or one of their contractors, you will be in major trouble. If I recall correctly the MINIMUM fine is $ 10,000 USD.

This is not something to be treated lightly.

Share this post


Link to post
Share on other sites

Yes, I have stated this before - in less words however.

DONT USE THIS MODULE IF YOU DONT HAVE SSL
It is dangerous!

DONT USE THIS MODULE IF IT VIOLATES YOUR MERCHANT AGREEMENT
I assume no responsibility for any damages caused by a breach in security or misuse of this module

If you have ANY reservations about using this module -- ASK before installing.

--Kevin

Share this post


Link to post
Share on other sites
Hi There, Sorry for my english!
I have a question... i have instaled the module and works great! But i can not find the credit card data number in the back pannel.

I have the shiping data, the phone number.. and evry thing. But i dont have the credit card number that the user place in the form. Can you tell me guys, were is that data?
TNKS!!!!


Look in AdminOrders.php

and find this line

/* Display customer information */



and put this code above it

// display card module
       $hook = Module::hookExec('invoice', array('id_order' => $order->id));
       if ($hook !== false)
       {
           echo '
'.$hook;
       }



maybe make a backup of the file before, so if you make a mistake you can try again from new. ;-)



Also i think these notes could be added to a readme in the module download. maybe the display customer information fix mentioned earlier in this thread

Thanks for the module

Share this post


Link to post
Share on other sites

Hi,

I am looking into using the offline credit card module and setting up ssl. I can get a personal ssl with a dedicated ip from my web host. I understand that for the certificate I have to set up either http://www.domain.com or http://domain.com, on which there are a number of threads here, so I'm not too worried about that.

However, I have two domains, a .com and a .co.uk. I will point the second domain to my website so that both domains open the site, but I assume that this will cause problems when you get the the payment page as the certificate is just for one of the domains. To avoid having to purchase and run two certificates is there a way to make sure that the payment page (and whatever other pages are protected by ssl) uses the only the certified domain?

I suppose I could do a redirect when a visitor comes via the second domain, but I'd rather not do that. Any suggestions?

I hope that all makes sense! I can't be the only person out there with more than one domain.

Thanks in advance,

Lisa

Share this post


Link to post
Share on other sites

you either have to redirect one domain to the other and have only one SSL cert and website, or each domain will need its own certificate and website.

if you use your thinking when you use the secure section (payments or occ module) of your site it will display that url of the installed certificate, ie if you have got to your site using .com but the one ssl certificate you have installed is for .co.uk, when you goto https (secure) .co.uk will be shown replacing the .com in the address bar.

my thoughts:

use a redirect (of some description) on one of the domains and then just have one cert and one website.

Share this post


Link to post
Share on other sites

Thanks for your reply. One certificate and one website is all I want - I don't want to go setting up more!

I was thinking of a redirect - I suppose it would be best to do it when the visitor fisrt comes to the site. I assume that Prestashop uses relative links so that if you enter the site through .co.uk, you stay on .co.uk and vice versa with .com?

Share this post


Link to post
Share on other sites

You can do the "redirect" right at your domain provider. Just go to where you bought the .com and set it to "Forward" to the .co.uk

Simple as that.

Share this post


Link to post
Share on other sites

I Have been working on my SSL and is now working!!

could someone explain to me how you process the credit card? To take out the payments from the credict card. Is the a way that I can just transfer the payment to my bank? IS the a site were the money can be transfer to a bank or how is that done???

-Sparior

Share this post


Link to post
Share on other sites

Thanks for the nice module, i have use that, but not sure where the credit card information will be displayed on the admin panel under order section,

Can any one please tell me that where i can see the credit card information for that order.

Many thanks
Faisal Zafar

Share this post


Link to post
Share on other sites
Thanks for the nice module, i have use that, but not sure where the credit card information will be displayed on the admin panel under order section,

Can any one please tell me that where i can see the credit card information for that order.

Many thanks
Faisal Zafar


Look in AdminOrders.php

and find this line

/* Display customer information */



and put this code above it

// display card module
       $hook = Module::hookExec('invoice', array('id_order' => $order->id));
       if ($hook !== false)
       {
           echo '
'.$hook;
       }



maybe make a backup of the file before, so if you make a mistake you can try again from new. ;-)