2012-11-20 9 views
0

div의 기본 동작을 변경하여 오버플로 : 숨김으로 인해 div의 맨 아래가 아닌 div의 오른쪽 밖으로 내용이 오버플로되도록 멀리 있습니까?div 오버플로 오른쪽

+1

CSS에서 overflow-x 및 overflow-y를 사용하는 방법을 살펴보십시오. –

+0

@Diodeus 이러한 속성은 자신의 문제와 아무 관련이 없습니다. –

답변

3

시도 white-space:nowrap 그렇게하면 내용이 새로운 줄로 감싸지지 않습니다.

div{ 
    overflow:hidden; 
    white-space:nowrap; 
    width:100px; 
} 
+1

아, 고마워요! 정확히 내가 필요로하는 것. 정말 고마워. (내가 충분히 높은 평판을 얻지 못해서 아직 투표 할 수 없다.) – Ryan

2

예. 텍스트를 줄 바꿈하지 마십시오 :

<div style="width:100px;height:30px; overflow:hidden; white-space:nowrap;"> 
    Is there away to change the default behavior of a div so that 
    overflow:hidden causes the content to overflow out the right side 
    of a div, rather than out of the bottom of the div? 
</div>