【问题标题】:Foundation- Contact Form adjustment基金会-联系表格调整
【发布时间】:2014-10-05 08:13:08
【问题描述】:

我一直在使用基础模板来创建我的网站。由于表单的布局是行和列的,我试图改变文本字段的宽度,因为它们在页面上太大了。当我为它们指定高度时,表单会移动到页面的左侧并且不居中。我想让它保持居中以及让文本字段更小。网址是http://www.f-sharpmedia.com/

HTML:


<!-- Contact Form -->
<div class="container">
 <div class="panel">


  <!-- This is where the main form is created for the contact page-->

    <div id="form">
   <div class="row">
  <div class="large-12 columns">

  <div class="panel">
  <h1>Contact F-Sharp Media</h1>
  <br>
<p>Got a creative project for us? Please share as much detail as you can to help us
ensure we can connect you with<br> the right people here at F-Sharp Media. <p>
<div class="large-3 columns">    
</div>

</div>
</div>  
 <!-- FORM -->
 <div id="form">
 <form action="sendmail.php" method="post">

 <p>
  <label for="name">Name:</label>
  <input name="name" id="name" type="text" class="required">
  <span>Please enter your name</span>
  </p>

<p>
<label for="email">Email:</label>
<input name="email" id="email" type="text" class="required"> 
<span>Please enter a valid email address</span>
</p>

<p>
<label for="subject">Subject:</label>
<input name="subject" id="subject" type="text"> 
<span>Please enter your subject</span>
</p>

<p>
<label for="message">Message</label>
<textarea name="message" id="message" class="required"></textarea> 
<span>Please enter your message</span>
</p>
<p class="submit">
<input type="submit" value="Submit" class="btn-submit">
</p>
</form>
</div>
 <div class="row">
 <div class="large-9  columns ">

  </div>
  </div>
  </div>
  </div>

【问题讨论】:

  • 给定的网站链接已损坏。
  • 再看一遍我已经编辑好了

标签: php html css forms contact


【解决方案1】:

在您的 CSS 中添加以下类。

 .grid_12.omega form p
{
  width:75%; /* Increase or decrease this width to adjust your textbox */
  margin:0px auto;
}

【讨论】:

  • 这并没有改变任何东西@Suresh Ponnukalai
  • 这是我的回答中的一个小错误。现在你复制并检查一下。
猜你喜欢
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2011-04-15
  • 1970-01-01
  • 2015-03-04
  • 2016-10-29
  • 2014-11-01
相关资源
最近更新 更多