以联系方式输入电话号码掩码.. [英] Input masking for telephone number in contact form..

查看:298
本文介绍了以联系方式输入电话号码掩码..的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

亲爱的所有人,



我正在开发一个使用素面的应用程序,我使用的是联系表格,其中包括移动电话号码和电话号码。



这里的电话样本如下:

(国家代码)。(州代码)(电话号码)。

(+91)。(80)。(4465444)..



印度国家代码在哪里相同,但州代码各有不同...任何一个帮助验证电话领域的国家代码号码..



示例州代码,080,04545,0452

等待回复..



提前致谢,



Siva

Dear All,

I am developing an application using prime faces where i use contact form in that which consists of mobile and telephone numbers..

Here the sample for telephone are as follows:
(country-code).(state-code)(telephone number).
(+91).(80).(4465444)..

Where in India country code is same , but state code differs form each..can any one help in validating a number for state code in telephone field..

Example state-codes,080,04545,0452
Awaiting a reply..

Thanks in advance,

Siva

推荐答案

你已经说过 - 验证是关键。

您需要在使用/存储之前检查输入的值。

如果值是有效数字,则可以。否则反应。



州代码是固定值。他们不会改变。所以比较它们非常简单。

比较一个数字应该不是什么大问题!?
You already said it - validation is the key.
You need to check the entered value before you use/store it.
If the value is a valid number it''s ok. Otherwise react.

State codes are fixed values. They don''t change. So it''s pretty simple to compare them.
Comparing a number should not be a big deal!?


这篇关于以联系方式输入电话号码掩码..的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆