Neuigkeiten
  • Die modified eCommerce Shopsoftware ist kostenlos, aber nicht umsonst.
    Spenden
  • Damit wir die modified eCommerce Shopsoftware auch zukünftig kostenlos anbieten können:
    Spenden
  • Thema: Create IBAN on the go?

    blaupunkt

    • Neu im Forum
    • Beiträge: 26
    Create IBAN on the go?
    am: 21. Januar 2014, 16:12:06
    Hello again!

    I have put an IBAN field on my checkout_payment page. Right now, if the user has a valid Kontonummer and BLZ the IBAN is automatically generated by the make_iban function.

    Code: PHP  [Auswählen]
    $make_iban = new IbanAccountCheck;
              $make_iban_result = $make_iban->make_iban($order->customer['banktransfer_number'], $order->customer['banktransfer_blz'], $ctry_iso2 = 'DE');

    However, I was wondering if it is possible to create the IBAN as the user enters his details, the same way Bank name is generated from the BLZ.

    Cheers,
    Ned


    Linkback: https://www.modified-shop.org/forum/index.php?topic=29031.0

    dmun

    • Mitglied
    • Beiträge: 241
    Re: Create IBAN on the go?
    Antwort #1 am: 21. Januar 2014, 16:49:25
    Hi,

    do you mean IBAN or BIC ?
    However the BIC is not needed for Lastschriften inside Germany.

    Viele Grüße, Dirk

    blaupunkt

    • Neu im Forum
    • Beiträge: 26
    Re: Create IBAN on the go?
    Antwort #2 am: 21. Januar 2014, 17:05:13
    IBAN. I want to be generated on the go in order to make it easier for the customers.

    dmun

    • Mitglied
    • Beiträge: 241
    Re: Create IBAN on the go?
    Antwort #3 am: 21. Januar 2014, 17:14:08
    Hi,

    Add your code in the banktransfer.php and not the checkout_payment.php than the customer can enter his / her IBAN / BIC and the IBAN gets calculated when the customer goes to net next page .
    Or do you want to get it calculated while the customer types in the Kontonummer and BLZ ? In that case you should use Javascript but I have no idea how it could be done with Javascript.

    Viele Grüße, Dirk

    Matt

    • Experte
    • Beiträge: 4.241
    Re: Create IBAN on the go?
    Antwort #4 am: 21. Januar 2014, 20:07:57
    http://toms-cafe.de/iban/iban.de.html

    Not sure wether it's a good idea to calculate an IBAN while typing. You know that a BLZ has 8 digits, but you never know how many digits the bank code has so you have to update the IBAN on every KeyUp event. Tends to confuse more than it helps.

    dmun

    • Mitglied
    • Beiträge: 241
    Re: Create IBAN on the go?
    Antwort #5 am: 21. Januar 2014, 20:27:55
    Hi,

    I will update the banktransfer.php with the "make_iban" function and use it to convert the Konto / BLZ to IBAN if the customer enters the them instead of the IBAn / BIC. I think this is useful because finally I just need to transfer the IBAN if I import orders from the Shop to the backend-system but creating an IBAN while typing is not a good idea - IMO.

    Cheers, Dirk

    blaupunkt

    • Neu im Forum
    • Beiträge: 26
    Re: Create IBAN on the go?
    Antwort #6 am: 22. Januar 2014, 00:06:11
    Thanks for the answers.

    @Matt - that's exactly what I want to do but Tom's javascript is too big while the make_iban function is pretty simple to use. My boss wants me to do it this way so I'm trying my best. I'll check if AJAX can help me and I'll see how it goes.

    vr

    • modified Team
    • Beiträge: 2.664
    Re: Create IBAN on the go?
    Antwort #7 am: 22. Januar 2014, 12:37:37
    Ned, all,

    while technically it is certainly possible and a number of conversion libs exist - you are aware that there are legal subtleties? Officially only banks (or people using software that the banks provided for that purpose) are entitled to derive IBANs from legacy BANs. To my knowledge, in Germany at least. If a generated IBAN is invalid, banks can charge the creditor/merchant a fee, and probably will.

    Volker

    blaupunkt

    • Neu im Forum
    • Beiträge: 26
    Re: Create IBAN on the go?
    Antwort #8 am: 23. Januar 2014, 11:08:51
    Hi vr, yes, I know about this and that's why I've included a text field warning the customers that the generated IBAN might be wrong and so on. Anyway, in case someone else wants to do the same thing as me, here is how I did it:

    1)Included the iban.js in the checkout_payment.html
    2)Edited a bit the iban.js file(mostly the variables and predefined the country code to DE)
    3)put onchange event for the Kontonummer and BLZ fields
    4)put onclick event for the IBAN field
    0 Antworten
    3146 Aufrufe
    17. Februar 2012, 16:21:30 von hstreicher
    2 Antworten
    3049 Aufrufe
    17. Januar 2014, 09:12:24 von blaupunkt
    11 Antworten
    6754 Aufrufe
    14. Juni 2011, 13:56:09 von Tomcraft
    1 Antworten
    1331 Aufrufe
    19. Juni 2017, 18:55:05 von awids
               
    anything