如何实现这种布局?

hel*_*hod -1 html css gwt uibinder

我想基本上创建这种布局:

登录面板

实现这一目标的最佳方法是什么?

the*_*gah 6

你的HTML:

<div id="login">
    <div class="float_left">
      Your input here <br/>
       Your remember me checkbox and text
    </div>
    <div class="float_left">
      Your second input here <br/>
      And then your forget password link
    </div>
    <div class="float_left">
      Login button here
    </div>
    <br style="clear:both;"/>
</div>
Run Code Online (Sandbox Code Playgroud)

你的CSS:

#login {}
.float_left {float:left;}
Run Code Online (Sandbox Code Playgroud)

  • 我不理解downvotes,但我确实认为将整个表单封装在div中,使用brs而不是正确的样式并命名类"float_left"从代码风格的角度来看是次要的. (3认同)