473,405 Members | 2,421 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,405 software developers and data experts.

writing direct French characters into HTML

4
Today I read there is a possibility to write direct Fench characters in HTML.
Thus instead of having to write :

L'élève va à l'école et ceci est écrit en Français!

I should be able to directly write it in French, i.e. :

L'élève va à l'école et ceci est écrit en Français!

(I just hope this renders well on your output device)

I found two possibilities but none did work.

Possibility 1

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/strict.dtd">
<HTML lang="fr-fr">
<HEAD>
<TITLE>Un document français</TITLE>
</HEAD>
<BODY>
L'élève va à l'école et ceci est écrit en Français!
</BODY>
</HTML>

This gives some very queer characters on my screen (like a capital "Z" with a kind of half circle above it instead of the lowercase "e" with a "accent aigue"). Some characters are just omitted (like the c)cedille).

Solution 2

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/html4/strict.dtd">

<html lang="fr">
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title>Exemple de document HTML 4.01</title>
</head>
<body>
<h1>Un document français</h1>
<p>L'élève va à l'école et ceci est écrit en Français!</p>
</body>
</html>

This time I get for every special French character a question mark in a black diamond (lozenge).

WHAT AM I MISSING?!!

If I could I would send you the 2 ".jpg" partial screen shots in attachement (one is 8 KB, the other 16 KB; don't know how the INSERT IMAGE button works; apparently no browsing possible, nor a copy of my image in the pste-buffer).

Thank you for any help!

Sono
Jul 22 '07 #1
2 7882
drhowarddrfine
7,435 Expert 4TB
You need to set your charset in the head. The ideal situation is to use utf-8, so:

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

Also, instead of the character set you show, use unicode characters with the numbers and I'll be darned if I can't think of the name of these things right now. The special characters are #&1234; or somesuch. I'd give you a link but I have to leave but it should be easy to find on the W3C site or just google.
Jul 22 '07 #2
praveen2gupta
201 100+
Hi
Your solution no 2 is correct and it is working. Check your browser Encoding. The IE encoding should be shown as UTF-8. View--> Encoding --> select the encoding mode.

French language works goood with UTF-8.
If it is not showing properly past your html output
Jul 28 '07 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

5
by: darin dimitrov | last post by:
Hello, How can I convert an url encoded string containing some french characters back to the original string? I have the following html form: <form> name = <input type="text" name="name"...
2
by: yearTiger2002 | last post by:
Our company's back end database server does not handle french accentuated characters well. We need to replace those characters with english letters when validating the form inputs. Any suggestions?...
38
by: Xah Lee | last post by:
sometimes i wish to add white space in <p> as to achived effects similar to tab. what should i do? using empty image seems the sure way but rather complicated. (and dosen't change size with...
6
by: Vinoth | last post by:
Hi, Our Website is french website. When we search in google for our site its showing the title name with some characters like -- droit propriété industrielle, protection propriétà ... But...
9
by: kaustubh.deo | last post by:
I am facing issues printing french chars like using printf function. I have reproduced this issue with simple C program as follows. #include <stdio.h> #include <locale.h> int main(int...
7
chunk1978
by: chunk1978 | last post by:
i though i had this under control, but i'm completely lost... i have a form which allows a user to fill out information, which is then emailed to myself as well as themselves... the form is...
4
by: Rob | last post by:
Hi, I have a small VB.Net program that reads in an HTML file using a FileStream (this file was created by MS Word "Save as HTML" feature), uses regular expressions to remove all unwanted code...
1
by: rvenable | last post by:
Hi everyone, I'm new to this forum and I hope I'm in the right one. I have a question regarding MS Index server to search for french accent characters. I have a search engine for our website that...
0
by: shintu | last post by:
Hallo, I am trying to write french accented characters é è ê in Excel worksheet using my perl script , But I am stuck here as I couldnt find a way of writing it !: My code: use strict;...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.