2014-02-27 2 views
1

다음 코드가있는 MVC 뷰가 있습니다. 위 두 테이블을보고 960로 폭을 갖는 @using (Html.BeginForm())을 할 수있는 것처럼너비를 MVC 3의 Html.BeginForm()으로 설정합니다.

<table width="960" border="0" align="center" cellpadding="0" cellspacing="0"> 
       . 
       . 
       . 
       . 
</table> 
@using (Html.BeginForm()) 
      { 

     <table width="960" border="0" align="center" cellpadding="0" cellspacing="0"> 
      <tr> 
       <td> 
        . 
        . 
        . 
        . 
        . 
} 
       </td> 
      </tr> 
     </table> 

하지만이 코드는 브라우저가 자동으로 form tag (코드 Html.BeginForm())에 1100px로 폭을주는 렌더링한다. 어디서 왔는지 모르겠다. Html.BeginForm()에서 너비를 설정하려고 생각 중이거나 더 좋은 아이디어가 있지만 너비를 Html.BeginForm()으로 설정하는 방법조차 모릅니다. 도와주세요. 감사합니다. .

답변

0

좋은 생각은 CSS 파일의 폭을 제공하는 것입니다

table form{ 
width:960px; 
} 
관련 문제