"자바스크립트 현재 페이지 호스트명 확인"의 두 판 사이의 차이

6번째 줄: 6번째 줄:
console.log(window.location.hostname);
console.log(window.location.hostname);
console.log(location.hostname);
console.log(location.hostname);
console.log(document.URL.hostname);
</syntaxhighlight>
</syntaxhighlight>



2023년 10월 9일 (월) 01:30 판

1 개요

자바스크립트 현재 페이지 도메인명 확인
자바스크립트 현재 페이지 도메인 주소 확인
console.log(window.location.hostname);
console.log(location.hostname);

2 같이 보기

3 참고

문서 댓글 ({{ doc_comments.length }})
{{ comment.name }} {{ comment.created | snstime }}