"HTML dt, dd 한줄로 출력하기"의 두 판 사이의 차이

잔글 (봇: 자동으로 텍스트 교체 (-</source> +</syntaxhighlight>, -<source +<syntaxhighlight ))
 
(사용자 2명의 중간 판 9개는 보이지 않습니다)
4번째 줄: 4번째 줄:


==예시==
==예시==
<source lang='html5' highlight='2'>
<syntaxhighlight lang='html' highlight='2' run>
<style>
<style>
dt { float: left; }
dt { float: left; }
dd { float: left; }
</style>
</style>


14번째 줄: 13번째 줄:
<dt>배</dt><dd>배나무의 열매</dd>
<dt>배</dt><dd>배나무의 열매</dd>
</dl>
</dl>
</source>
</syntaxhighlight>
<jsfiddle>xgdq1nLw</jsfiddle>


==같이 보기==
==같이 보기==

2021년 7월 17일 (토) 14:15 기준 최신판

1 개요

HTML dt, dd 한줄로 출력
  • dt에 float: left;를 주면 됨

2 예시

html
Copy
<style>
dt { float: left; }
</style>

<dl>
	<dt>사과</dt><dd>사과나무의 열매</dd>
	<dt></dt><dd>배나무의 열매</dd>
</dl>

3 같이 보기

편집자 220.119.201.73 J Jmnote Jmnote bot