+ Reply to Thread
Page 3 of 4 FirstFirst 1234 LastLast
Results 21 to 30 of 40

Thread: Add commas to the price input field

  1. #21
    Senior Member
    Join Date
    Jun 2016
    Location
    New York
    Posts
    158
    I'm using jquery_number.js, do you want to use it? if the answer is yes I'll leave it here attached. I am waiting...

  2. #22
    Senior Member
    Join Date
    Jun 2016
    Location
    New York
    Posts
    158

    Arrow Number Format Price

    First step:

    PHP Code:
    Only registered members can view the code
    Second step:

    PHP Code:
    Only registered members can view the code
    Below the line:

    PHP Code:
    Only registered members can view the code
    add the line:

    PHP Code:
    Only registered members can view the code
    Attached Files Attached Files
    Last edited by Ed; May 6, 2018 at 10:14 PM. Reason: updated

  3. #23
    Senior Member
    Join Date
    Jun 2016
    Location
    New York
    Posts
    158
    Read the post above, in a while I am going to post the Third step (3), please wait ...

  4. #24
    Senior Member
    Join Date
    Jun 2016
    Location
    New York
    Posts
    158
    Third step:

    With the "step_form.tpl" file opened, locate the code:

    PHP Code:
    Only registered members can view the code
    Add below the line: hashTabs();

    PHP Code:
    Only registered members can view the code
    The end result should be this:
    PHP Code:
    Only registered members can view the code
    Save and close.

    I'm going to post Fourth step(4) in a moment ...
    Last edited by Ed; May 6, 2018 at 10:49 PM.

  5. #25
    Senior Member
    Join Date
    Jun 2016
    Location
    New York
    Posts
    158

    Arrow Number Format Price

    Fourth step:

    On your site open the file:
    PHP Code:
    Only registered members can view the code
    below the line:
    PHP Code:
    Only registered members can view the code
    edit the line:
    PHP Code:
    Only registered members can view the code
    you just need to replace class="numeric"

    per ...

    id="price"

    The end result is:
    PHP Code:
    Only registered members can view the code
    Save and clear your browser's cache and see if it's working.
    Last edited by Ed; May 6, 2018 at 11:15 PM.

  6. #26
    Senior Member
    Join Date
    Jun 2016
    Location
    New York
    Posts
    158

    Arrow Number Format

    Reread what I posted above because some things have been updated!

    In my script the price setting looks like this:

    5.000,00 (five thousand)
    5.700,00 (five thousand and seven hundred)

    but you can change the configuration through the line:

    PHP Code:
    Only registered members can view the code

  7. #27
    Senior Member
    Join Date
    Jun 2016
    Location
    New York
    Posts
    158
    Last edited by Ed; May 7, 2018 at 12:08 AM. Reason: updated

  8. #28
    Thanks Ed, did it messup with your saved search criteria? I notice that when I look at my alert page, which show my saved search criteria, the price show two ',,' like 2,,000 or xx,,xxx, xx is just number. Everything else works fine.

  9. #29
    Member
    Join Date
    Jul 2016
    Location
    Iran
    Posts
    74
    Hello,
    Thanks Ed very much for your complete description and guidance.

    Your method worked, but I have two problems:
    1) I do not need a cent separator, with the change this code
    PHP Code:
    Only registered members can view the code
    to
    PHP Code:
    Only registered members can view the code
    still separates two digits.
    2) I have some type of price field that works only for the main case where the key is price, for other items that do not work the price1 key, price2, and so on.

    I would like the price of 123456789 to be typed as 123,456,789 without cent separator.
    Thanks, if these tips are resolved.
    Last edited by Mousa Lotfi; May 7, 2018 at 09:33 AM. Reason: Complete the description
    Car sell in: BanBan.ir

  10. #30
    Hello Mousa,

    For other price fields try to use this code:
    Code:
    Only registered members can view the code.
    Viktor,
    Flynax technical department,
    Best wishes.

+ Reply to Thread