jQuery val not working properly in Chrome
Posted
by Mircea
on Stack Overflow
See other posts from Stack Overflow
or by Mircea
Published on 2010-05-27T10:08:22Z
Indexed on
2010/05/27
10:11 UTC
Read the original article
Hit count: 377
I have a simple jQuery function:
$('#selectable1 span').live('mousedown', function() {
var ff = $(this).css("font-family");
$("#family").val(ff);
});
When a span element is clicked (mousedown) an input (#family) gets its font family value. It works in FireFox but in Chrome it works only for font families composed from only one word. Georgia will work but Times New Roman will now.
You can see the code here:
or live at http://www.typefolly.com
What is wrong with this? Thanx
© Stack Overflow or respective owner