티스토리 배경화면 변경 방법 (Tistory blog background)

티스토리 블로그를 운영하면서 공개되어 있는 스킨을 적용시 배경화면을 변경하는 방법입니다.

티스토리 관리 - HTML/CSS 편집 메뉴로 들어가면 아래와 같이 Body 구분으로 시작하는곳이 있거나 아니면 없으면 추가합니다.


body

background-color: #fff; 

background-image: url('./배경화면파일명.jpg');

background-attachment: fixed; 

background-repeat: no-repeat; 

background-position: center center; 

background-size: cover; 


 


  • 위와 같이 변경하시면 됩니다.


 
  • CSS 배경관련 명령어
    1. background-image: url(이미지주소);

    2. background-size:
      1. auto; 원본 크기

      2. 100px; 픽셀크기 지정

      3. 50%; 비율 지정

      4. contain; 가로 세로 비율 유지, 이미지 중심으로 늘려준다 (화면 크기에 따라서 배경화면이 잘리거나 빈 공간이 생길 수 있습니다.)

      5. cover; 가로 세로 비율 유지, 요소 중심으로 커진다


    3. background-repeat:
      1. repeat; 반복 채움

      2. no-repeat; 반복 없이 하나만

      3. repeat-x; 가로만 반복

      4. repeat-y; 세로만 반복


    4. background-attachment ;
      1. scroll; 스크롤을 움직임에 맞춰서 배경이 위로올라가거나 아래로 내려간다

      2. fixed; 배경이 고정됨 (스크롤을 움직여도 배경만 그대로)

      3. background-position:

      4. center / left / right / top / bottom; 기준위치

      5. 0% 0%; 죄측상단

      6. 100% 100%; 우측하단



0 개의 댓글: