Hi,

"Chris W. Parker" <[EMAIL PROTECTED]> wrote:

> - Edwin - <mailto:[EMAIL PROTECTED]>
>     on Monday, September 15, 2003 9:45 PM said:
> 
> > Or, you can just declare it inside you're <head> tags (as mentioned
> > previously). Also, depending on the charset you're using, you might
> > need "shift_jis" instead of "euc-jp". ("euc-jp" is recommended though
> > esp. if data is coming from a database.)   
> 
> Explain to me then why my test page didn't work until I put that
> header() function in my php code when I copy and pasted verbatim from a
> japanese website?

Hmm... let's see...

> Here's what I did:
> 
> 1. Went to www.ajapanesesite.com (don't remember what it was called)
> 2. Viewed source

Did you check the header info? What's in-between the <head> tags?

> 3. Ctrl-A (select all in windows)
> 4. Ctrl-C (copy)
> 5. Open html-kit and create a new blank page
> 6. Ctrl-V (paste)

Did you check if the Japanese characters are readable inside html-kit? In other words, 
Japanese characters should appear as it is inside your editor...

> 7. Save the page

Did you save it as euc-jp or shift_jis?

> 8. open it in the web browser

Before opening it in your browser, did you try opening again in your editor just to 
see whether you saved it correctly?

> 9. cry because it doesn't work

Hmm... If everything is properly declared inside your <head> tags, your browser 
*should* automatically render the page correctly. Anyway, if it doesn't work, check 
that the "character coding" in your browser is properly selected. (If you're on 
Netscape or Mozilla, choose "View" -> "Character coding" -> 
your_character_coding_here.)

> A friend later figured out that the header() declaration at the top of
> the page was what made the difference.

Did this one work for you?

> Do you know why it wouldn't work until that php code was added?

Not really sure. But think about this. People can write HTML pages without the help of 
php and the like and still have Japanese pages correctly rendered by their browsers. 
In other words, I can write an HTML page with Japanese characters in it, save it on my 
desktop (and not on my web server), double click it, my browser starts and show me the 
characters correctly--no php code necessary.

Try that again and see if it works. If not, most probably the problem lies somewhere 
else...

> > Quanta works fine for me. ( http://quanta.sourceforge.net/ ) And you
> > don't have to buy it ;) Actually, as long as you can change the
> > default font used (and assuming you have the fonts installed), *most*
> > editors should do just fine.
> 
> Looks good, do you know if it has been ported to windows?

Not really sure. (I know it works on OS X though...) But if it's not ported, *maybe* 
you can use with cygwin+windows combination.

Btw, iirc, phpedit on Win2k worked for me. Just make sure that you have Japanese fonts 
(and an IME) installed and you chose the correct (default) font for phpedit. This 
works even if you have on English version of Win2k (or XP).

--

- E -

__________________________________________________
Do You Yahoo!?
Yahoo! BB is Broadband by Yahoo!
http://bb.yahoo.co.jp/

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to