2014-04-24 4 views
0

border 속성을 사용하여 요소의 border-radius을 설정할 수 있습니까? 나는 다음과 같은 몇 가지 코드를 원하는 (하지만 코드 아래에 작동하지 않습니다)테두리 속성을 사용하는 것만으로 테두리 반경을 설정하는 방법

#myelement { 
    border: 1px solid #535353; 
    border-radius: 5px 5px 5px 5px; 
} 

:

#myelement { 
    border: 1px solid #535353 5px 5px 5px 5px; 
} 

을 그리고 당신은 답을 알고 있다면 당신은 마음 것

나는 아래와 같은 결과를 원하는 어떻게 대답을 찾았습니까? 난 그냥 가능하지 구글 :(한마디로

+1

border 내부에 포함하는 것은 불가능하다 border-top-radius','border-right-radius','border-bottom-radius','border-left-radius' 등)을 구분할 수 있습니다. 속기 속성 ('border'는 속기 속성입니다.) – Ming

답변

4

, 그것을 찾을 수 없습니다.

Formal syntax: <br-width> || <br-style> || <color>

당신이 border 속성에 대한 Mozilla's Documentation을 읽어야

3

border 속성의 구문은 :

<br-width> || <br-style> || <color> 

이 값의 의미 :

<br-width> 
The width of the border of the elements. Default value medium is used if absent 
<br-style> 
The line style for all four sides of the elements border. Default value none is used if absent 
<color> 
Denote the color of the border. If not set, its default value is the value of the element's color property (the text color, not the background color) 

그래서 내가 국경 radius`가`에 대한 (자체 속기`때문에, 당신이 할 수 있다고 생각하지 않습니다 border-radius

관련 문제