seevaa.net

  • 본문 바로가기
  • 블로그 내 검색
  • 글 분류 목록
  • 최근 글 목록
  • 기타 블로그메뉴
  • about
  • photolog
  • socialpage
  • taglog
  • guestbook
  • admin

페이지 속 특정부분만 인쇄

from Web Standard/CSS 2011. 12. 28. 14:37 by seevaa Share on Twitter*

웹페이지상에서 뿌려지는 데이터를 사용자가 인쇄할 수 있도록-버튼같은 걸- 만들어 달라는 요구사항이 종종 있다. 웹브라우저상에서 페이지 인쇄가 가능한데 굳이 버튼을 만들어 달라는 건 필요한 데이터만 깔끔하게 출력되게 끔 원하는 것이다.

이런 경우 데이터만 보이는 페이지를 별도로 만들어 서버를 한번 더 타게 만드는 경우가 있는데, CSS(media="print")로 같은 페이지 상에서 쉽게 해결할 수 있다.

style 속성에 media="print" 라고 주면 인쇄시에만 해당 스타일이 적용되는데, 위의 예에서처럼 출력시 필요없는 부분은 display:none; 이런식으로 막아버리면 된다.

...


...
...
...
... ...
...
...

'Web Standard > CSS' 카테고리의 다른 글

HTML to Excel : mso-number-format style attribute  (0) 2013.01.29
CSS - the Selector syntax  (0) 2011.03.24
Bookmark - 20110309 : NHN, HTML Elements의 id/class(CSS selector) 네이밍  (0) 2011.03.09
,
<< 1 2 3 4 5 6 ··· 316 >>

Categories

  • All (316)
    • Life Style (102)
    • Images (94)
      • Photo (94)
    • Web Standard (11)
      • HTML (0)
      • CSS (4)
      • JavaScript (7)
    • Application Programing (8)
      • java/jsp (8)
    • DataBase (5)
      • Oracle (3)
      • MySQL (0)
    • Programing Tool (2)
      • Eclipse (2)
    • Tistory (50)
      • Skin (22)
    • Fonts (12)
    • Bookmarks (31)

Recent Posts

Recent Comments

Recent Trackbacks

Archive

Links

  • http://wing91.tistory.com
  • http://xylosper.net
  • http://hanrss.co.kr
  • http://poty.cafe24.com
  • http://standardmag.org
  • http://www.raysoda.com/ess
  • http://startuu.net
  • http://cyoonk.com
  • http://trio.co.kr/webrefer/css…
  • http://designsen.net
  • http://tipography.tistory.com
  • http://twitter.com/seevaa_
  • http://tum.seevaa.net
  • http://clip.seevaa.net
subscribe to RSS

T Y T
subscribe to RSS, valid XHTML, CSS
Powered by , Designed by seevaa

  • 처음으로
  • 본문 바로가기
  • 블로그 내 검색
  • 글 분류 목록
  • 최근 글 목록
  • 기타 블로그메뉴
seevaa.net - seevaa.net
작성자 : 쎄바(seevaa)
연락처 : seevaa@seevaa.net

티스토리툴바