views:

49

answers:

2
+1  Q: 

JQuery datepicker

Coud someone help me with this? I am getting these question marks in the graphic and i'm not sure why? I have seen these symbols before and i am sure it had something to do with charset. I am using:

<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>

Here is my JQuery code

    <script type="text/javascript">
        $(function() {
            var date = $('#date').datepicker({
                minDate: 0,
                dateFormat: "dd/mm/yy",
                beforeShowDay: function(date){
                    if (date.getDay() == 0){
                        return [false, ''];
                    } else {
                         return [true, ''];
                    }
                }
             }
            );
        });
</script>

Image can be found here: http://kevinhenney.com/jquery-datepicker.jpg

Tried to add an image in the post, not allowed just yet.

Thanks in advance

A: 

The code you've provided isn't the problem. I just tested your provided code in Opera10/FF3/IE8 and I do not get the ? characters.

  • Are you specifying a specific font in your css?
  • Does this happen in all browsers on your machine?
  • Tested on another machine?
JClaspill
It happens in Chrome, Firefox 3.6.3, IE8, and Opera 10. My font stack in my stylesheet is just font:12px/18px Arial, Helvetica, sans-serif;I can't test another machine at the moment.
showFocus
A: 

Problems like this are usually encoding issues as you've said, and they can often be difficult to figure out. Often it is because the editor you're using saves the file in one encoding, even though your meta tag specifies a different encoding. Try changing the charset to ISO-8859-1 and see if that solves the problem.

Andrew M. Andrews III