Skip to content

.unpriceFormat is not a function #89

@doubleprincez

Description

@doubleprincez

When used in function, I get the error " specialBonusAmount.unpriceFormat is not a function", when i tried to get the price from the input field and also return it back to the display div


        $("#specialBonusAmount").priceFormat({
            prefix: '₦',
            centsSeparator: '.',
            thousandsSeparator: ','
        });

  function addSpecialBonus() {
            let specialBonusAmount =  $("#specialBonusAmount");
             specialBonus = specialBonusAmount.unpriceFormat();
            console.log("special "+specialBonus);
            let amountDisplay = $("#amountDisplay");
            amountDisplay.text(specialBonus).priceFormat();
}

please what is the right way to carry out the above function?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions