www.xxx.com 에서 주소앞에 www.를 없애주려면??? 정보
www.xxx.com 에서 주소앞에 www.를 없애주려면???본문
플래시 파일을 사용중인데 주소를 http://xxx.com 으로 설정해놓은 상태입니다.
그런데 http://www.xxx.com 으로 접속했을시 이게 먹통이 되네요...
그래서 말인데, www. 주소로 접속했을시 www. 를 지우고 그냥 http://xxx.com 주소로
접속되게 하는 방법은 없을까요.,,.?
P.S 만일 주소를 변환해서 접속하는데 어떤 트래픽이 발생한가더나 하진 않겠죠...?
그런데 http://www.xxx.com 으로 접속했을시 이게 먹통이 되네요...
그래서 말인데, www. 주소로 접속했을시 www. 를 지우고 그냥 http://xxx.com 주소로
접속되게 하는 방법은 없을까요.,,.?
P.S 만일 주소를 변환해서 접속하는데 어떤 트래픽이 발생한가더나 하진 않겠죠...?
댓글 전체
<script language="JavaScript" type="text/javascript">
var host = location.host.toLowerCase();
var currentAddress = location.href;
if (host.indexOf("www") == -1)
{
currentAddress = currentAddress.replace("//","//www.");
location.href = currentAddress;
}
</script>
[http://도메인.com >> http://www.도메인.com]
var host = location.host.toLowerCase();
var currentAddress = location.href;
if (host.indexOf("www") == -1)
{
currentAddress = currentAddress.replace("//","//www.");
location.href = currentAddress;
}
</script>
[http://도메인.com >> http://www.도메인.com]
감사합니다. 근데 해당 스크립트를 어디다 넣는게 좋을까요? head.sub.php인가요?
그리고 [http://도메인.com >> http://www.도메인.com] 이 의미하는건 무엇인지...
그리고 [http://도메인.com >> http://www.도메인.com] 이 의미하는건 무엇인지...
시도해봤는데 검색만 뜨네요....ㄷㄷ;;; 어떻게 해야하는건지...;
.htaccess
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{HTTP_HOST} !^zombi\.kr$ [NC]
RewriteRule (.*) http://zombi.kr/$1 [R=301,L]
</IfModule>
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{HTTP_HOST} !^zombi\.kr$ [NC]
RewriteRule (.*) http://zombi.kr/$1 [R=301,L]
</IfModule>
유아원님, 위 소스를 어디다 붙여넣어야되는지도 좀 알려주시면 감사하겠습니다..;;
.htaccess 파일을 만들어 ftp에 업로드 합니다.
그런파일도 있나요..? 확장자가...??? .htaccess. php로 만들면 될까요?
확장자 없습니다. 모든파일로 해놓고 .htaccess 파일명으로 저장. ftp 업로드 끝. 입니당~~
우와아앙, 되네요ㅠㅠ눈물나게 감사합니다ㅠㅠ
www빼기