[php] 일본어 홈페이지를 만들기 위한 .htaccess 기본 설정 > 팁앤테크

본문 바로가기
사이트 내 전체검색

팁앤테크

[php] 일본어 홈페이지를 만들기 위한 .htaccess 기본 설정

페이지 정보

본문

일본어는 크게 UTF-8, Shift_JIS, EUC-JP로 구분이 되서 언어 세팅을 합니다..

추세는 UTF-8이지만 하나만을 고집할 수만 없는 실정입니다..
이메일 수신을 못할수도 있는 경우가 생기기 때문입니다..

최대한 서버설정과 홈페이지 언어의 설정을 마추기 위해서 .htaccess 기본 설정을 수정해 봅니다..

UTF-8 で作成・保存して UTF-8 で表示させる場合
*注 php5 のみを記述する場合は <IfModule> タグは不要です。
# PHP5.
<IfModule mod_php5.c>
php_flag output_buffering Off
php_value output_handler none
php_value default_charset UTF-8
php_value mbstring.language japanese
php_flag mbstring.encoding_translation On
php_value mbstring.http_input auto
php_value mbstring.http_output UTF-8
php_value mbstring.internal_encoding UTF-8
php_value mbstring.substitute_character none
</IfModule>
# PHP4.
<IfModule mod_php4.c>
php_flag output_buffering Off
php_value output_handler none
php_value default_charset UTF-8
php_value mbstring.language japanese
php_flag mbstring.encoding_translation On
php_value mbstring.http_input auto
php_value mbstring.http_output UTF-8
php_value mbstring.internal_encoding UTF-8
php_value mbstring.substitute_character none
</IfModule>

UTF-8 で作成・保存して Shift_JIS で表示させる場合
# PHP5.
<IfModule mod_php5.c>
php_flag output_buffering On
php_value output_handler mb_output_handler
php_value default_charset Shift_JIS
php_value mbstring.language japanese
php_flag mbstring.encoding_translation On
php_value mbstring.http_input auto
php_value mbstring.http_output SJIS
php_value mbstring.internal_encoding UTF-8
php_value mbstring.substitute_character none
</IfModule>
# PHP4.
<IfModule mod_php4.c>
php_flag output_buffering On
php_value output_handler mb_output_handler
php_value default_charset Shift_JIS
php_value mbstring.language japanese
php_flag mbstring.encoding_translation On
php_value mbstring.http_input auto
php_value mbstring.http_output SJIS
php_value mbstring.internal_encoding UTF-8
php_value mbstring.substitute_character none
</IfModule>

EUC-JP で作成・保存して EUC-JP で表示させる場合
# PHP5.
<IfModule mod_php5.c>
php_flag output_buffering Off
php_value output_handler none
php_value default_charset EUC-JP
php_value mbstring.language japanese
php_flag mbstring.encoding_translation On
php_value mbstring.http_input auto
php_value mbstring.http_output EUC-JP
php_value mbstring.internal_encoding EUC-JP
php_value mbstring.substitute_character none
</IfModule>
# PHP4.
<IfModule mod_php4.c>
php_flag output_buffering Off
php_value output_handler none
php_value default_charset EUC-JP
php_value mbstring.language japanese
php_flag mbstring.encoding_translation On
php_value mbstring.http_input auto
php_value mbstring.http_output EUC-JP
php_value mbstring.internal_encoding EUC-JP
php_value mbstring.substitute_character none
</IfModule>

EUC-JP で作成・保存して Shift_JIS で表示させる場合
# PHP5.
<IfModule mod_php5.c>
php_flag output_buffering On
php_value output_handler mb_output_handler
php_value default_charset Shift_JIS
php_value mbstring.language japanese
php_flag mbstring.encoding_translation On
php_value mbstring.http_input auto
php_value mbstring.http_output SJIS
php_value mbstring.internal_encoding EUC-JP
php_value mbstring.substitute_character none
</IfModule>
# PHP4.
<IfModule mod_php4.c>
php_flag output_buffering On
php_value output_handler mb_output_handler
php_value default_charset Shift_JIS
php_value mbstring.language japanese
php_flag mbstring.encoding_translation On
php_value mbstring.http_input auto
php_value mbstring.http_output SJIS
php_value mbstring.internal_encoding EUC-JP
php_value mbstring.substitute_character none
</IfModule>
추천0

댓글목록

등록된 댓글이 없습니다.

Total 770건 21 페이지
  • RSS
팁앤테크 목록
번호 제목 글쓴이 조회 추천 날짜
270 제로쪽지보내기 홈페이지 자기소개 아이디로 검색 전체게시물 16052 0 12-18
269 제로쪽지보내기 홈페이지 자기소개 아이디로 검색 전체게시물 16070 0 04-24
268 제로쪽지보내기 홈페이지 자기소개 아이디로 검색 전체게시물 16077 0 06-02
267 제로쪽지보내기 홈페이지 자기소개 아이디로 검색 전체게시물 16092 0 02-08
266 제로쪽지보내기 홈페이지 자기소개 아이디로 검색 전체게시물 16110 0 03-20
265 제로쪽지보내기 홈페이지 자기소개 아이디로 검색 전체게시물 16111 0 06-15
264 제로쪽지보내기 홈페이지 자기소개 아이디로 검색 전체게시물 16130 0 12-05
263 제로쪽지보내기 홈페이지 자기소개 아이디로 검색 전체게시물 16182 0 10-22
262 제로쪽지보내기 홈페이지 자기소개 아이디로 검색 전체게시물 16202 0 05-31
261 제로쪽지보내기 홈페이지 자기소개 아이디로 검색 전체게시물 16213 0 03-22
260 제로쪽지보내기 홈페이지 자기소개 아이디로 검색 전체게시물 16218 0 10-29
259 제로쪽지보내기 홈페이지 자기소개 아이디로 검색 전체게시물 16242 0 12-22
258 제로쪽지보내기 홈페이지 자기소개 아이디로 검색 전체게시물 16244 0 05-06
257 제로쪽지보내기 홈페이지 자기소개 아이디로 검색 전체게시물 16262 0 09-18
256 제로쪽지보내기 홈페이지 자기소개 아이디로 검색 전체게시물 16265 0 12-23
255 제로쪽지보내기 홈페이지 자기소개 아이디로 검색 전체게시물 16265 0 12-14
254 제로쪽지보내기 홈페이지 자기소개 아이디로 검색 전체게시물 16271 0 12-04
253 제로쪽지보내기 홈페이지 자기소개 아이디로 검색 전체게시물 16294 0 10-08
252 제로쪽지보내기 홈페이지 자기소개 아이디로 검색 전체게시물 16304 0 03-20
251 제로쪽지보내기 홈페이지 자기소개 아이디로 검색 전체게시물 16305 0 10-10
250 제로쪽지보내기 홈페이지 자기소개 아이디로 검색 전체게시물 16316 0 01-24
249 제로쪽지보내기 홈페이지 자기소개 아이디로 검색 전체게시물 16318 0 05-19
248 제로쪽지보내기 홈페이지 자기소개 아이디로 검색 전체게시물 16318 0 11-24
247 제로쪽지보내기 홈페이지 자기소개 아이디로 검색 전체게시물 16342 0 05-02
246 제로쪽지보내기 홈페이지 자기소개 아이디로 검색 전체게시물 16375 0 04-10

검색

회원로그인

회원가입

사이트 정보

株式会社YHPLUS / 대표 : ZERO
〒140-0011 東京都品川区東大井2-5-9-203
050-5539-7787
오픈카카오톡 (YHPLUS) :
https://open.kakao.com/o/slfDj15d

접속자집계

오늘
7,517
어제
7,420
최대
8,233
전체
1,523,642
Copyright (c) 株式会社YHPLUS. All rights reserved.