trooprr / jquery-watermark

Automatically exported from code.google.com/p/jquery-watermark
0 stars 0 forks source link

Watermark not recognizing HTML5 Input Types #54

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Create inputs using types other than text, such as type="email" or type="tel"
2. Add appropriate id's to inputs. ie. id="email" id="telephone"

<input type="email" name="Email" id="email" placeholder="Email" />

3. Add calls to plugin:

$('#email').watermark('Phone');
$('#telephone').watermark('Phone');

What is the expected output? What do you see instead?

Expected watermarks to appear in inputs type="email" and type="tel"

What version of the product are you using? On what operating system?

3.1.3
Firefox 3.6.8
Mac OS X 10.6.6

Please provide any additional information below.

The problem goes away when I change types back to text. 

Original issue reported on code.google.com by he...@patdryburgh.com on 24 Mar 2011 at 4:37

GoogleCodeExporter commented 8 years ago
Thanks for the problem report.  You're right, the new HTML5 types are not 
recognized.  I'll add them in the next release.

Original comment by t...@speednet.biz on 24 Mar 2011 at 2:48

GoogleCodeExporter commented 8 years ago
BTW, this is already fixed in the source code, so it will definitely be in the 
next release.

Original comment by t...@speednet.biz on 21 Jul 2011 at 10:53

GoogleCodeExporter commented 8 years ago
If you need a quick fix before the next release, just open the un-minified 
version, go tot like 36, where you will see a var declaration called 

selWatermarkAble = 
"input:text,input[type=email],input:password,input[type=search],input:not([type]
),textarea"

In there just add this at the end:
,input[type=email]

And it'll work fine.

Original comment by desduvau...@gmail.com on 2 May 2012 at 2:06

GoogleCodeExporter commented 8 years ago
Fixed in version 3.1.4

Original comment by t...@speednet.biz on 13 Aug 2012 at 3:53