부트스트랩 프로젝트 실무 하위 컬럼 정보 content_javascript 기술

WBOY
풀어 주다: 2016-05-16 15:04:01
원래의
1279명이 탐색했습니다.

이번 글에서는 참고하실 수 있도록 정보 내용 칼럼을 작성했습니다.

Google 크롬 파싱 순서를 조정하세요. 모든 항목을 로드한 후 실행해야 합니다

$(window).load(function() {
  $('.text').eq(0).css('margin-top', ($('.auto').eq(0).height() - $('.text').eq(0).height()) / 2 + 'px');
}); 
로그인 후 복사

참고: Firefox 브라우저의 경우 Ctrl+Shift+M을 눌러 모바일 크기를 조정할 수 있습니다.
하위 열 제목

<div class="jumbotron">
  <div class="container">
    <hgroup>
      <h1>资讯</h1>
      <h4>企业内训的最新动态、资源等...</h4>
    </hgroup>
  </div>
</div>
로그인 후 복사

열 CSS

.jumbotron {
  margin: 50px 0 0 0;
  padding: 60px 0;
  background: #ccc url(../img/bg.jpg);
  color: #ccc;
}
.jumbotron h1 {
  font-size: 26px;//768,30; 992,33; 1200,36;
  padding: 0 0 0 20px;
}
.jumbotron h4 {
  font-size: 16px;//768,16; 992,17; 1200,18
  padding: 0 0 0 20px;
}
로그인 후 복사

정보 콘텐츠

<div id="information">
  <div class="container">
    <div class="row">
      <div class="col-md-8 info-left">
        <div class="container-fluid" style="padding:0;">
          <div class="row info-content">
            <div class="col-md-5 col-sm-5 col-xs-5">
              <img src="img/info1.jpg"
              class="img-responsive" alt="">
            </div>
            <div class="col-md-7 col-sm-7 col-xs-7">
              <h4>广电总局发布 TVOS2.0 华为阿里参与研发</h4>
              <p class="hidden-xs">
                TVOS2.0 是在 TVOS1.0 与华为 MediaOS 及阿里巴巴 YunOS 融合的基础上,打造的新一代智能电视操作系统。华为主要承担开发工作,内置的电视购物商城由阿里方面负责。
              </p>
              <p>
                admin 15 / 10 / 11
              </p>
            </div>
          </div>
        </div>
      </div>
      <div class="col-md-4 info-right hidden-xs hidden-sm">
        <blockquote>
          <h2>热门资讯</h2>
        </blockquote>
        <div class="container-fluid">
          <div class="row">
            <div class="col-md-5 col-sm-5 col-xs-5"
            style="margin:12px 0;padding:0;">
              <img src="img/info3.jpg"
              class="img-responsive" alt="">
            </div>
            <div class="col-md-7 col-sm-7 col-xs-7"
            style="padding-right:0">
              <h4>标题</h4>
              <p>
                admin 15 / 10 / 11
              </p>
            </div>
          </div>
        </div>
      </div>
    </div>
  </div>

로그인 후 복사

정보 콘텐츠 CSS

#information {
  padding: 40px 0;
  background: #eee;
}
.info-right {
  background-color: #fff;
  box-shadow: 2px 2px 3px #ccc;
}
.info-right blockquote {
  padding: 0;
  margin: 0;
}
.info-right h2 {
  font-size: 20px;
  padding: 5px;
}
.info-right h4 {
  line-height: 1.6;
}
.info-content {
  background-color: #fff;
  box-shadow: 2px 2px 3px #ccc;
  margin: 0 0 20px 0;
}
.info-content img {
  margin: 12px 0;
}
.info-content h4 {
  font-size: 14px;//768,16; 992,18; 1200,20;
  padding: 2px 0 0 0;
}
.info-content p {
  line-height: 1.6;
  color: #666;
}
로그인 후 복사

.info-content h4의 경우 중대형 화면에서 한 줄을 유지해야 합니다.

.info-content h4 {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

로그인 후 복사

자세한 내용은 부트스트랩 학습 튜토리얼

을 참조하세요.

위는 Bootstrap을 이용하여 하위 컬럼 정보 콘텐츠를 생성하는 코드입니다.

원천:php.cn
본 웹사이트의 성명
본 글의 내용은 네티즌들의 자발적인 기여로 작성되었으며, 저작권은 원저작자에게 있습니다. 본 사이트는 이에 상응하는 법적 책임을 지지 않습니다. 표절이나 침해가 의심되는 콘텐츠를 발견한 경우 admin@php.cn으로 문의하세요.
인기 튜토리얼
더>
최신 다운로드
더>
웹 효과
웹사이트 소스 코드
웹사이트 자료
프론트엔드 템플릿
회사 소개 부인 성명 Sitemap
PHP 중국어 웹사이트:공공복지 온라인 PHP 교육,PHP 학습자의 빠른 성장을 도와주세요!