提交表单后从输入掩码中删除文字? [英] Remove literals from input mask after form submit?
本文介绍了提交表单后从输入掩码中删除文字?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
这个问题已经被提出,但是解决方案还不清楚.
this question has already been asked but the solutions where not clear.
我正在使用Josh Bush的MaskedInput jQuery插件
Im using Josh Bush's MaskedInput plugin for jQuery
我要实现的目标是:
例如:带掩码的电话输入
E.g: a phone input with the mask
$("#txtPhone").mask("(99)9999-9999");
等于:(00)9398-8373
EQUALS: (00)9398-8373
我希望它提交:0093988373
i want it to submit : 0093988373
------是否可以在提交时删除.mask但保留其值?
------ Is it possible to remove the .mask on submit but keep the value?
推荐答案
我认为您想使用unmask
$("#myForm").submit(function() {
$("#txtPhone").unmask();
});
这篇关于提交表单后从输入掩码中删除文字?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文