-2
我試圖模仿維基的佈局,在每一行之前顯示每行中出現的第一節經文。這甚至可以用基本的HTML?模仿HTML中的聖經詩歌佈局
http://jsfiddle.net/ukfpj2o8/It
<div style="margin-left:2em"><span style="color:#2E8B57; float:left; text-align:right; margin-left:-3em; width:2.5em;" id="I.">I.</span> IN the beginning God made the heaven and the earth. <span style="color:#2E8B57; float:left; text-align:right; margin-left:-3em; width:2.5em;" id="I.">2</span> And the earth was invisible and unfurnished and there was darkness over this abyss; and a breath of God was brought on above the water. <span style="color:#2E8B57; float:left; text-align:right; margin-left:-3em; width:2.5em;" id="I.">3</span> And God said, "Let there be Light;" and there was light. And God saw the light that it was good. <span style="color:#2E8B57; float:left; text-align:right; margin-left:-3em; width:2.5em;" id="I.">4</span>And God made a separation between the light and the darkness. <span style="color:#2E8B57; float:left; text-align:right; margin-left:-3em; width:2.5em;" id="I.">5</span>And God called the light day; and the darkness he called night. And there was an evening and there was a morning. The first day.</div>
我希望有人能幫助 感謝
這是不可能的基本的HTML,但可以用CSS/JavaScript實現。請提供一個起點(CodePen或JSFiddle),另請參閱http://stackoverflow.com/help/mcve – Roy
那麼,該頁面如何做呢?你可以看到他們的HTML。 – David
這是我想出的。 https://jsfiddle.net/jpez/ukfpj2o8/它可以正常工作,除非經文編號在浮動跨度重疊的同一行上。 – jpez