text-indent 百分比實現自適應布局怎么實現?具體寫法怎么寫?求大神詳細解說。。(正解第一時間采納)
<!DOCTYPE?HTML> <html> <head> ??<style> ??????.textindent{text-indent:?1100px;?height:?30px;?line-height:?30px;?padding:?10px;?position:?relative;} ??????.textindent?span{?position:?absolute;?top:10px;?right:?10px;???} ??</style> </head> <body> ??<p?class="textindent">15874006673?<span>測試縮進</span></p> </body> </html>
2017-01-17
首先你得有個父級,設置這個父級元素相應的寬度或者高度,然后在設置子級的,子級的寬高可以設置成百分比形式的,因為子級是依據父級的,具體的數值,可以自己慢慢調試。