---
title: "[jquery插件]金额及银行卡号格式化"
author: "全冠清"
date: "2013-07-16T15:54:48Z"
tags: []
categories: ["Web前端"]
slug: "jquery"
draft: false
lastmod: "2013-07-16T15:55:59Z"
id: 1907930
url: "https://story.iteye.com/blog/1907930"
---

![](http://dl2.iteye.com/upload/attachment/0087/0055/18da983f-7868-3fe6-b21f-17efbbfe92bd.jpg)
示例：

```html

<!doctype html>
<html lang="cn">
<head>
	<meta charset="UTF-8">
	<title>Document</title>
	<script src="http://libs.baidu.com/jquery/1.9.1/jquery.min.js"></script>
	<script src="inputFormat.js"></script>
	<script type="text/javascript">
	    $(function(){
			$('#account').inputFormat('account')
			$('#money').inputFormat('amount')
      })
	</script>
</head>
<body>
	帐号：<input id="account"/><br/>
    金额：<input id="money"/>
</body>
</html>

```