简体   繁体   English

使 Submit 和 Reset 具有与输入标签边框不同的边框

[英]Making Submit and Reset have a different border from the input tag border

Please how can i make the submit button and reset button have a different border apart from the input tags请问如何使提交按钮和重置按钮具有与输入标签不同的边框

     HTML
     <input typ="image" name="submit"     value=" " scr="image.png">

      <input type="image" name="reset"      value=" " scr="reset.png" >

   CSS
   input, textarea, select {
   border: 2px solid red;
   }

I have tried to add another selector with the name submit and reset but both of them still get the values from the input tags border.我试图添加另一个名为 submit 和 reset 的选择器,但它们仍然从输入标签边框获取值。

input[type=image] or give them a class name or give them an id , name is not used for css input[type=image]或给他们一个class name 或给他们一个idname不用于 css

Write:写:

id="submit"

In the input tag of the submit button, and then in the CSS, type:在提交按钮的输入标签中,然后在CSS中输入:

#submit
{
    border: 1px solid black;     /* as an example */
}

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM