Removing Address info on cc_info.php

Discussion in 'Templates customization' started by mjmtaiwan, Jul 10, 2008.

  1. mjmtaiwan

    mjmtaiwan aMember Pro Customer

    Joined:
    Aug 22, 2006
    Messages:
    45
    I don't have high hopes that I'll get a very detailed answer to this question but here goes.

    I have my eprocessing portal setup to not require user address information to process the transactions.

    My ecommerce guru tells me that the fewer form elements the visitor has to enter the more likely the chance of a sale (seems reasonable). So I want to remove the address info.

    I know how to remove the CVV box (by changing 'code' => 1 to 'code' => 0 in eprocessingnetwork.inc.php) but that's not what I am trying to do. I would like to remove the need for the user to enter street address, city, state, country and zip. Of course I can edit that out of cc_info.html but cc_core and eprocessing.inc are still requiring it.

    Alex, is there a way I can edit those files to remove those requirements?

    Thanks (as always) for your great, reasonably priced, script.
  2. getresults

    getresults Member

    Joined:
    Nov 1, 2006
    Messages:
    87
    You've checked that your ecommerce gateway doesn't need the address fields? Many merchant accounts now require the card holder's address details to do an address verification check.

    If they're not needed then you should be able to modify the credit card form page to remove the address fields and form validation for the address fields.

    If you're looking for someone to do that for you can drop me a line at: phill at getresults.co.nz

    Thanks,

    Phill
  3. mjmtaiwan

    mjmtaiwan aMember Pro Customer

    Joined:
    Aug 22, 2006
    Messages:
    45
    I can remove the fields without difficulty. Its the programatic need for them that I need to address.

    Removing the fields without changing the code that sends the info on to the processor or checks the form just causes an error.

    But you probably know that already.
  4. skippybosco

    skippybosco CGI-Central Partner Staff Member

    Joined:
    Aug 22, 2006
    Messages:
    2,526
    To confirm Phil's question, your credit card merchant account allows you to submit charges without validating the correct address from the customer?

    This seems like a security risk, but that aside.

    1) Are you asking for the user to fill in address details on the signup page? If so, you can pass the value of those fields to the CC page and just hide the form fields (and remove checking of the fields)
  5. binbin

    binbin New Member

    Joined:
    Jan 29, 2008
    Messages:
    38
    I would like to hide the state field and street field of the adress info but how I can remove the checking of this both required fields ?
    Thx
  6. getresults

    getresults Member

    Joined:
    Nov 1, 2006
    Messages:
    87
    I can't help for the next few days as I'm out of town at a conference, but if you email me at phill @ getresults.co.nz I'll take a look at this for you when I get back. Should be very easy to disable the checking of those fields.
  7. jimjwright

    jimjwright New Member

    Joined:
    Sep 12, 2007
    Messages:
    162
    Hello,

    I don't know what version of aMember or payment plugin so that will matter, but you can try commenting out the following lines in cc_core.inc.php in function validate_cc_info

    PHP:
        // if (!strlen($vars['cc_street']))
            // $errors[] = _PLUG_PAY_CC_CORE_ERROR14;

        // if (!strlen($vars['cc_state']))
            //$errors[] = _PLUG_PAY_CC_CORE_ERROR16;
    Jimmy
  8. mjmtaiwan

    mjmtaiwan aMember Pro Customer

    Joined:
    Aug 22, 2006
    Messages:
    45
    I'll try that... thanks
  9. skippybosco

    skippybosco CGI-Central Partner Staff Member

    Joined:
    Aug 22, 2006
    Messages:
    2,526
    Do check back in and let us know how it turns out.

Share This Page