Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8534153
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T10:07:44+00:00 2026-06-11T10:07:44+00:00

I am during the expansion and development of cash flow There is a problem

  • 0

I am during the expansion and development of cash flow
There is a problem to obtain the information of the credit card form, but read less than a credit card verification number (CVN)

For example, class

class Xxx_Yzz_Model_Method_Zcc extends Mage_Payment_Model_Method_Abstract
{
    public function setParams ()
    {
        ....
        $ CcCid = $ this-> getInfoInstance () -> getCcCid ();
        ....
    }
}

I reference the Mage_Payment_Model_Method_Cc of, inside the assignData override, but in vain

public function assignData ($ data)
{
    if (! ($ data instanceof Varien_Object)) {
        $ data = new Varien_Object ($ data);
    }
    $ info = $ this-> getInfoInstance ();
    $ info-> setCcType ($ data-> getCcType ())
        -> setCcOwner ($ data-> getCcOwner ())
        -> setCcLast4 (substr ($ data-> getCcNumber (), -4))
        -> setCcNumber ($ data-> getCcNumber ())
        -> setCcCid ($ data-> getCcCid ())
        -> setCcExpMonth ($ data-> getCcExpMonth ())
        -> setCcExpYear ($ data-> getCcExpYear ())
        -> setCcSsIssue ($ data-> getCcSsIssue ())
        -> setCcSsStartMonth ($ data-> getCcSsStartMonth ())
        -> setCcSsStartYear ($ data-> getCcSsStartYear ())
    ;
    return $ this;
}

In addition, I also made reference to the Mage_Payment_Model_Method_Cc, prepareSave override, can only obtain a credit card number, but did not get verification code

public function prepareSave ()
{
    $ info = $ this-> getInfoInstance ();
    if ($ this-> _canSaveCc) {
        $ info-> setCcNumberEnc ($ info-> encrypt ($ info-> getCcNumber ()));
    }
    // $ info-> setCcCidEnc ($ info-> encrypt ($ info-> getCcCid ())); 
    // These three lines seems useless
    $ info-> setCcNumber (null) 
        // These three lines seems useless
        -> setCcCid (null); 
        // These three lines seem useless
    return $ this;
}

Hope you can help me, thank you

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T10:07:45+00:00Added an answer on June 11, 2026 at 10:07 am

    In order to save the CVV code (verification code), the prepareSave() method should look like this:

    public function prepareSave ()
    {
        $info = $this->getInfoInstance();
        if ($this->_canSaveCc) {
            $info->setCcNumberEnc($info->encrypt($info->getCcNumber()));
        }
    
        // Uncommented this line
        $info->setCcCidEnc($info->encrypt($info->getCcCid()));
    
        $info->setCcNumber(null)->setCcCid(null); 
    
        return $this;
    }
    

    Unless this saving/retrieving functionality was also disabled elsewhere, that should make Magento save the CVV Code. I believe that line that was commented out was what used to set the CVV Code to be saved in the database.

    You may have to edit a template file for the admin to also make it show on the order management page. I’m not positive though.

    At some point Magento stopped storing CVV codes for a reason as it violates the terms of service with credit card companies. I don’t recommended re-introducing this functionality, but there ya go. Let me know if that works (unless you already found the solution).

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

During the development I experience unhandled exceptions at random occasions, but mostly after closing
During some of the page transitions (for example during the turn and flow transitions)
How can I fix the simple macro foo in (elisp)Eval During Expansion ? None
I am investigating an issue relating to a large log expansion during an ETL
During merges mercurial leaves .orig file for any unresolved file. But after manually resolving
During development, I like the idea of frameworks like Entity Framework 4.3 Migrations (although
I want to overload navigator.geolocation.getCurrentPosition and navigator.geolocation.watchPosition to simulate geolocation during development. Is it
I am a new, but huge fan, of the BDD approach to software development
During my EclipseRCP development I often end up having Eclipse plugin project directory terminating
Is there a way to force methods to be accessible only during certain events

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.