Skip to content

Commit

Permalink
updated readme
Browse files Browse the repository at this point in the history
  • Loading branch information
jackocnr committed Jun 1, 2013
1 parent 5e6a543 commit c59e5eb
Showing 1 changed file with 34 additions and 1 deletion.
35 changes: 34 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,38 @@
# International Telephone Input
A jQuery plugin for entering international telephone numbers
A jQuery plugin for entering international telephone numbers. It adds a flag dropdown to any input, which lists all the countries and their international dial codes next to their flags.

## Demo
https://bluefieldscom.github.io/intl-tel-input/

## Getting started
Add the stylesheet in your <head> section, and add the script file at the end of your <body>. You will also need to have jQuery included somewhere. You will then be able to initialise the plugin on your input using the main intlTelInput() function. See below.
```html
<html>
<head>
<link rel="stylesheet" href="build/css/intlTelInput.css">
</head>
<body>
<input type="tel" id="mobile-number">

<script src="https://code.jquery.com/jquery-1.9.1.min.js"></script>
<script src="build/js/intlTelInput.js"></script>
<script>
$(function() {
$("#mobile-number").intlTelInput();
});
</script>
</body>
</html>
```

## Current features (v0.1.0)
* Add the flag dropdown to any of your existing inputs with one line of JavaScript
* Select a country from the dropdown to populate the input with it's international dial code
* Click off the dropdown to close it
* Typing a different dial code will automatically update the displayed flag

## Roadmap
* Type country name to select it

## Attributions
* Flag images and CSS from https://github.com/lafeber/world-flags-sprite
Expand Down

0 comments on commit c59e5eb

Please sign in to comment.