• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1306
  • Last Modified:

ASP.NET: UTF-8 and Server-side includes

Dear Experts,
I have .Net site and I'm using <!--#include virtual=""--> to include headers and footers. Everything has been working fine until now I need to do my website in French as well and none of the accented characters are rendered.
I am not using usercontrols because I don't want my element id's to be renamed... the site is xhtml and utf-8.
Is there a way?
0
mmiika
Asked:
mmiika
  • 3
  • 2
1 Solution
 
illCommented:
' is utf-8 defined in your header?
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
  <meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
0
 
topazgCommented:
Can you not just use things like:

&Aacute; or &#193; to get what you're after?

If you can the following is an excellent resource:

http://www.w3schools.com/html/html_entitiesref.asp

Just drop down to "ISO 8859-1 Character Entities"

Hope that helps,
- Graham
0
 
mmiikaAuthor Commented:
yep utf-8 is defined, I tried before with entites and yes they work, but again I'd like to have it without... Do you know is there a way to set up how the SSI's are handled? It seems like the .net framework doesn't do anything with them (page directives set the contentype to utf-8)
0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 
topazgCommented:
How does the user define whether the page is written in French or English?
0
 
mmiikaAuthor Commented:
At the moment they don't... I am converting a site done in english for French, with different data and everything. Later on this new site will be done in english as well, at which point I'm going to have to write everything again anyway (using localization xml files etc...). So the way the user selects the language at that time is not decided.
0
 
topazgCommented:
Oh ok, fair enough - Have you tried setting your pages to the correct French ISO standard, I'm a bit fuzzy on how the other language standards interpret non-standard UK characters?
0

Featured Post

Upgrade your Question Security!

Add Premium security features to your question to ensure its privacy or anonymity. Learn more about your ability to control Question Security today.

  • 3
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now