[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Storing Arabic and English in the same table ( Mysql )
- To: Development Discussions <developer at arabeyes dot org>
- Subject: Re: Storing Arabic and English in the same table ( Mysql )
- From: Armelle Nedelec <anedelec at gmail dot com>
- Date: Thu, 23 Mar 2006 08:47:05 +0200
- User-agent: KMail/1.7.1
That's it. It's working for me without any problem, even without putting
character set utf8 in MySQL database
but you have in php to use utf8 encoding for the arabic text and set you web
page encoding to utf-8.
Don't forget in php to use mb_string function for string function.
Regards
Armelle Nedelec
Le jeudi 23 Mars 2006 02:54, yousef albarak a écrit :
> I think u entered the data with form and the brrowser encoding
> window-1256.You should change the setting to utf-8 when entering the data.I
> test your code with browser set to utf-8, I have enterd the data to mysql
> throw phpmyadmin and it is okay. I did not get any value with "#234" or
> something like.
>
> ===================
> CREATE TABLE `t1_test` (
> `c1_utf8` varchar(50) character set utf8 default NULL,
> `c2_eng` varchar(50) default NULL
> ) ENGINE=MyISAM DEFAULT CHARSET=latin1;
>
> --
> -- Dumping data for table `t1_test`
> --
>
> INSERT INTO `t1_test` VALUES ('كيف الحال', 'test2');
> ==================
>
> >From: "Tasmeea Noor" <tasmeea at gmail dot com>
> >Reply-To: Development Discussions <developer at arabeyes dot org>
> >To: "Development Discussions" <developer at arabeyes dot org>
> >Subject: Re: Storing Arabic and English in the same table ( Mysql )
> >Date: Wed, 22 Mar 2006 16:25:07 -0500
> >MIME-Version: 1.0
> >Received: from arabeyes.org ([216.18.0.60]) by
> > bay0-mc6-f6.bay0.hotmail.com with Microsoft SMTPSVC(6.0.3790.1830); Wed,
> > 22 Mar 2006 13:25:13 -0800 Received: from art.arabeyes.org (sina
> > [127.0.0.1])by arabeyes.org (Postfix) with ESMTPid BA62E5FF3D; Wed, 22
> > Mar 2006 13:25:31 -0800 (PST)
> >Received: from xproxy.gmail.com (xproxy.gmail.com [66.249.82.196])by
> >arabeyes.org (Postfix) with ESMTP id 6E37D5F8F0for
> ><developer at arabeyes dot org>; Wed, 22 Mar 2006 13:25:29 -0800 (PST)
> >Received: by xproxy.gmail.com with SMTP id s7so198755wxcfor
> ><developer at arabeyes dot org>; Wed, 22 Mar 2006 13:25:08 -0800 (PST)
> >Received: by 10.70.108.14 with SMTP id g14mr1616932wxc;Wed, 22 Mar 2006
> >13:25:07 -0800 (PST)
> >Received: by 10.70.115.19 with HTTP; Wed, 22 Mar 2006 13:25:07 -0800 (PST)
> >X-Message-Info: NDMZeIBu+sqoHAq2g/RD1DVAsevXDsE9GY8Q8P1kiFg=
> >X-Original-To: developer at arabeyes dot org
> >Delivered-To: developer at arabeyes dot org
> >DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta;
> >d=gmail.com;h=received:message-id:date:from:to:subject:in-reply-to:mime-ve
> >rsion:content-type:references;b=SA1YLo6jzvxJHLkiu3GlZAXBfkAAM+reSMwBVl2uRk
> >KlJtb5m8lVVqZOZuLEZH9wMOJuND+yNLKSj/fSXpnaGDmEQV4cCek2to6R7OZ+CAgJvivxq1Bp
> >TmHWepta4NohuawLvlu9c004jarXy3tA+CKs/KBacNpeMr+cPVUwjpc= References:
> ><d4e3764b0603221213x5942c60dyc4ca4f27e680f7f4 at mail dot gmail dot com><BAY23-F229A5
> >8D81B0F15642F785FECD90 at phx dot gbl> X-BeenThere: developer at arabeyes dot org
> >X-Mailman-Version: 2.1.5
> >Precedence: list
> >List-Id: Development Discussions <developer.arabeyes.org>
> >List-Unsubscribe:
> ><http://lists.arabeyes.org/mailman/listinfo/developer>,<mailto:developer-r
> >equest at arabeyes dot org?subject=unsubscribe> List-Archive:
> > </archives/developer>
> >List-Post: <mailto:developer at arabeyes dot org>
> >List-Help: <mailto:developer-request at arabeyes dot org?subject=help>
> >List-Subscribe:
> ><http://lists.arabeyes.org/mailman/listinfo/developer>,<mailto:developer-r
> >equest at arabeyes dot org?subject=subscribe> Errors-To:
> > developer-bounces at arabeyes dot org
> >Return-Path: developer-bounces at arabeyes dot org
> >X-OriginalArrivalTime: 22 Mar 2006 21:25:17.0968 (UTC)
> >FILETIME=[1DD95100:01C64DF7]
> >
> >Thanks Usef, I tried, this is what I got ....
> >I must be doing something wrong....
> >
> >CREATE TABLE t1_test
> >(
> > c1_utf8 VARCHAR(50) CHARACTER SET utf8,
> >c2_eng VARCHAR(50) );
> >
> >INSERT INTO t1_test (c1_utf8,c2_eng ) values
> >( '������������' , 'test2' );
> >
> >The result shows:
> >
> >INSERT INTO t1_test (c1_utf8,c2_eng ) values
> > (
> >'الْعَالَمِين'
> >, 'test2' )
> >
> >But also when I select, I get the the same value.
> >
> >
> >INSERT INTO t1_test (c1_utf8,c2_eng ) values
> >('test'
> >,'الْعَالَمِين'
> >);
> >
> >On 3/22/06, yousef albarak <usef_ksa at hotmail dot com> wrote:
> > > Try to use utf-8 for ecoding data when u create the data base.you can
> > > use phpmyadmin to do this.
> > >
> > >
> > >
> > > Regards,
> > >
> > > Usef
> > >
> > > Try
> > >
> > > ------------------------------
> > > From: *"Tasmeea Noor" <tasmeea at gmail dot com>*
> > > Reply-To: *Development Discussions <developer at arabeyes dot org>*
> > > To: *Developer at arabeyes dot org*
> > > Subject: *Storing Arabic and English in the same table ( Mysql )*
> > > Date: *Wed, 22 Mar 2006 15:13:50 -0500*
> > > MIME-Version: *1.0*
> > > Received: *from arabeyes.org ([216.18.0.60]) by
> > > bay0-mc8-f19.bay0.hotmail.com with Microsoft SMTPSVC(6.0.3790.1830);
> >
> >Wed,
> >
> > > 22 Mar 2006 12:13:57 -0800*
> > > Received: *from art.arabeyes.org (sina [127.0.0.1])by
> >
> >arabeyes.org(Postfix) with ESMTPid 4E7F75FDCA; Wed, 22 Mar 2006 12:14:14
> >-0800 (PST)
> >
> > > *
> > > Received: *from xproxy.gmail.com (xproxy.gmail.com [66.249.82.196])by
> > > arabeyes.org (Postfix) with ESMTP id 2E600570A9for
> >
> ><Developer at arabeyes dot org>;
> >
> > > Wed, 22 Mar 2006 12:14:12 -0800 (PST)*
> > > Received: *by xproxy.gmail.com with SMTP id t13so214968wxcfor <
> > > Developer at arabeyes dot org>; Wed, 22 Mar 2006 12:13:50 -0800 (PST)*
> > > Received: *by 10.70.109.16 with SMTP id h16mr1483990wxc;Wed, 22 Mar
> >
> >2006
> >
> > > 12:13:50 -0800 (PST)*
> > > Received: *by 10.70.115.19 with HTTP; Wed, 22 Mar 2006 12:13:50 -0800
> > > (PST)*
> > >
> > >
> > >
> > > Salam,
> > > ?
> > > I need to create a table ( database mysql ), where I need to store
> > > data in English and Arabic.
> > > In the internet, there were lots of suggestion/ tips how to work in
> > > multi-lingual environment, but some reason I could not able to handle
> >
> >it. I
> >
> > > will be greatful if someone can help me in following:
> > > ?
> > > A small sample code for:
> > > 1) Create table statement at least one column for English data and
> >
> >other
> >
> > > column for Arabic data
> > > 2) insert statement to insert 1 or 2 rows.
> > > 3) select statement where data will be displayed in both the
> > > languages. ?
> > > Well next step will be to display the data thru website using php. I
> > > should figure that out - but any help will be appreciated. :-)
> > > ?
> > > Zajakallah Khairan.
> > >
> > > >_______________________________________________
> > > >
> > > >Developer mailing list
> > > >Developer at arabeyes dot org
> > > >http://lists.arabeyes.org/mailman/listinfo/developer
> > >
> > > ------------------------------
> > > Express yourself instantly with MSN Messenger! MSN
> >
> >Messenger<http://g.msn.com/8HMAEN/2737??PS=47575>Download today it's FREE!
> >
> > > _______________________________________________
> > > Developer mailing list
> > > Developer at arabeyes dot org
> > > http://lists.arabeyes.org/mailman/listinfo/developer
> >
> >_______________________________________________
> >Developer mailing list
> >Developer at arabeyes dot org
> >http://lists.arabeyes.org/mailman/listinfo/developer
>
> _________________________________________________________________
> FREE pop-up blocking with the new MSN Toolbar - get it now!
> http://toolbar.msn.click-url.com/go/onm00200415ave/direct/01/