这种布局是否可以使用html / css?

时间:2013-05-10 13:18:33

标签: html css html5

我正在尝试创建一个杂志样式布局,文本环绕中间的大引号。现代浏览器只会没问题。谁能把我送到正确的方向?

我读过 css regions。不幸的是,它仅适用于少数webkit版本,因此它不适合生产。

example

2 个答案:

答案 0 :(得分:1)

http://jsfiddle.net/hezj7/

HTML:

<div class="row">
    <div class="left-50">
        <p>Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.</p>
    </div>
    <div class="right-50">
        <p>Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.</p>
    </div>
</div>
<div class="row">
    <div class="left-33">
        <p>Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.</p>
    </div>
    <div class="middle-33">
        <p>SOME HUGE CONTENT HERE</p>
    </div>
    <div class="right-33">
        <p>Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.</p>
    </div>
</div>
<div class="row">
    <div class="left-50">
        <p>Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.</p>
    </div>
    <div class="right-50">
        <p>Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.</p>
    </div>
</div>

CSS:

.row {
    width: 100%;
}

.left-50 {
    width: 48%;
    float: left;
    margin: 0 4% 0 0;
    border: 1px solid red;
    box-sizing: border-box;
}

.right-50 {
    width: 48%;
    float: left;
    border: 1px solid orange;
    box-sizing: border-box;
}

.left-33 {
    width: 31%;
    float: left;
    margin: 0 3% 0 0;
    border: 1px solid purple;
    box-sizing: border-box;
}

.middle-33 {
    width: 31%;
    float: left;
    margin: 0 3% 0 0;
    border: 1px solid yellow;
    box-sizing: border-box;
}

.middle-33 p {
    font: 24px bold;
}

.right-33 {
    width: 31%;
    float: left;
    margin: 0;
    border: 1px solid blue;
    box-sizing: border-box;
}

答案 1 :(得分:0)

您是否尝试过以下内容:http://www.jwf.us/projects/jQSlickWrap/ 它需要HTML 5 canvas对象,因此IE可能不支持..