473,545 Members | 2,002 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

French accent problem when using ajax

bss
Dear All,

I have developing a French website using PHP & Ajax. In that I tried
to display some French texts from mysql database using Ajax. Form
local I got the text from db with
Correct accents but in online French accents are missing. The text
displays like this "de r?isation pour regroup?a majorit?es ". I
declared following code in the head section of the file.

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dt d">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html;
charset=iso-8859-1" />
<script src="include/showartical.js" type="text/javascript"
language="javas cript" </script>
</head>
When i display the text with out using Ajax I get the French text
perfectly.

Please help me how to display French text without missing any accents
using PHP & Ajax.

With Regards
Ashok

Mar 20 '07 #1
3 5892
On 20 Mar, 11:27, "bss" <masho...@gmail .comwrote:
Dear All,

I have developing a French website using PHP & Ajax. In that I tried
to display some French texts from mysql database using Ajax. Form
local I got the text from db with
Correct accents but in online French accents are missing. The text
displays like this "de r?isation pour regroup?a majorit?es ". I
declared following code in the head section of the file.

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dt d">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html;
charset=iso-8859-1" />
<script src="include/showartical.js" type="text/javascript"
language="javas cript" </script>
</head>
When i display the text with out using Ajax I get the French text
perfectly.

Please help me how to display French text without missing any accents
using PHP & Ajax.

With Regards
Ashok
make sure your encoding is consistent, set it all to utf-8 OR
iso-8859-1, but dont mix them, my choice is utf-8 because it will
allow you to use many other languages too.

Mar 20 '07 #2
ASM
bss a écrit :
Dear All,

I have developing a French website using PHP & Ajax. In that I tried
to display some French texts from mysql database using Ajax. Form
local I got the text from db with
Correct accents but in online French accents are missing.
You should have a charset in utf-8
then have to correct some disfunctions in PHP

voir le fil :
<http://groups.google.c om/group/fr.comp.infosys temes.www.auteu rs/msg/a16b01658f55c88 d?rnum=1>

sinon : le pb d'encodage sur PHP =
mysql_query ("SET NAMES 'utf8'"); force le jeu utf8.
--
Stephane Moriaux et son (moins) vieux Mac déjà dépassé
Stephane Moriaux and his (less) old Mac already out of date
Mar 20 '07 #3
bss
finaly i got the result
i missed the "header("Conten t-Type: text/html; charset=iso-8859-1");"
in php code part.
Thanks for your valuable info and Time

With Regards
ashok

On Mar 20, 8:26 pm, ASM <stephanemoriau x.NoAd...@wanad oo.fr.invalid>
wrote:
bss a écrit :
Dear All,
I have developing a French website using PHP & Ajax. In that I tried
to display some French texts from mysql database using Ajax. Form
local I got the text from db with
Correct accents but in online French accents are missing.

You should have a charset in utf-8
then have to correct some disfunctions in PHP

voir le fil :
<http://groups.google.c om/group/fr.comp.infosys temes.www.auteu rs/msg/a...>

sinon : le pb d'encodage sur PHP =
mysql_query ("SET NAMES 'utf8'"); force le jeu utf8.

--
Stephane Moriaux et son (moins) vieux Mac déjà dépassé
Stephane Moriaux and his (less) old Mac already out of date

Mar 22 '07 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

114
7644
by: muldoon | last post by:
Americans consider having a "British accent" a sign of sophistication and high intelligence. Many companies hire salespersons from Britain to represent their products,etc. Question: When the British hear an "American accent," does it sound unsophisticated and dumb? Be blunt. We Americans need to know. Should we try to change the way we...
3
21794
by: Darren Jensen | last post by:
Hi, Does anyone have a function which replaces accent chars from a string with the non-accented equivalent? For example 'hôpital' should return 'hopital'. Thank you in advance.
0
1454
by: Ike | last post by:
I'm wondering, in the I18N'ized version of our application, if someone is running it, say, on a French system, where certain characters have accent marks, and such characters are saved into a MySQL database from Java Strings that go into Varchar fields, do I need to process those Strings in any fashion before/after they are moved to the...
2
12450
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? I've never delt with foreign languages before...any help greatly apprieciated!
0
1180
by: ucasesoftware | last post by:
I send some sms in my Win app. but i have trouble with accent accènts = accAent for example when i receive my sms :( if i request the url directly in IE all accent are fine... so it's this code here who is not like "Iso ???". Someone can help pls ? Dim myReg As Net.HttpWebRequest = _...
1
3036
by: bssjohn | last post by:
Dear All, I have developing a French website using PHP & Ajax. In that I tried to display some French texts from mysql database using Ajax. Form local I got the text from db with Correct accents but in online French accents are missing. The text displays like this “de r?isation pour regroup?a majorit?es “. I declared following code in the...
2
7908
by: sono | last post by:
Today I read there is a possibility to write direct Fench characters in HTML. Thus instead of having to write : L'&eacute;l&egrave;ve va &agrave; l'&eacute;cole et ceci est &eacute;crit en Fran&ccedil;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...
1
1226
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 uses MS Index Server and it works great but it doesn't find any results for searches that contain french accented characters. If I'm searching...
0
1725
by: Amzul | last post by:
hello all. im trying to insret (using php) french words into a table. my list contailn words that are written allready with the code of the accent word. eg: capacitxc3xa9s achicrxc3xa9e i know that xc3xa9 is &eacute; i thought to convert the word using ereg_replace("xc3xa9",????,$word); but i dont know what mysql need here (????)
0
7475
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
0
7921
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
1
7437
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
0
7771
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
0
5982
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
0
4958
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
0
3465
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
0
3446
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
1023
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.