Arabic website

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
ibndiyaa
Forum Newbie
Posts: 4
Joined: Mon Jan 11, 2010 7:52 pm

Arabic website

Post by ibndiyaa »

Greetings again,

I am wondering if there is any way to change the keyboard which PHP uses for a foreign language, such as Arabic? I have changed the default_charset value to iso-8859-6, so I can display Arabic characters, but they are not in the same sequence on the keyboard as Windows.

Thank you.

Sohail.
ibndiyaa
Forum Newbie
Posts: 4
Joined: Mon Jan 11, 2010 7:52 pm

Re: Arabic website

Post by ibndiyaa »

Actually, just figured out that I had to change the page encoding to Arabic(Windows). Any way I can have that set in the PHP script so I won't have to do so in the web browser each time?
User avatar
Weirdan
Moderator
Posts: 5978
Joined: Mon Nov 03, 2003 6:13 pm
Location: Odessa, Ukraine

Re: Arabic website

Post by Weirdan »

You can do that via header() function:

Code: Select all

 
<?php
header('Content-type: text/html;charset=iso-8859-6'); // put here whatever encoding you need.
// ... the rest of your script here
 
Post Reply