On 9/16/06, Phil <[EMAIL PROTECTED]> wrote: > In the base.html template I added in the <head> section a {% block > extrahead %}{% endblock %}. > And in the index.html template I added {% block extrahead %} <meta > http-equiv="content-type" content="application/xhtml+xml; > charset=UTF-8" /> {% endblock %}
It is really strange that you need to duplicate your content-type to make it work. I believe your problem lies in how the browser is interpreting your html file and not in Django. Also, what happens if you instead specify your content-type in your base.html file like this? <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> There are two differences, Content-Type (first letters are uppercase) and the mime type is "text/html" instead of "application/xhtml+xml" By default, Django serves the Content-Type header (in the HTTP response headers) like that. See DEFAULT_CHARSET and DEFAULT_CONTENT_TYPE: http://www.djangoproject.com/documentation/settings/#default-charset > I plan to debug this to see why Django doesn't seem to know what is the > encoding of the index.html template. If your text editor is correctly writing your files in UTF-8 and you didn't changed the DEFAULT_CHARSET setting in your settings file, then there shouldn't be any problem with how Django reads your templates. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users -~----------~----~----~----~------~----~------~--~---