0

I have a button on my ASP.NEt web page which shows up green when I launch my project in VS2012 but when I launch it in VS2013 it does not show up any colour.

.input-control {
    margin-top: 10px;
    margin-left: 10px;
    margin-right: 10px;
    border-style: none;
}

.btn {
   border-style: none;
   border-color: inherit;
   width: 100%;
   height: 35px;
   background-color: green;
}
<div class="input-control">
    <input type="button" id="btnRequestInvite" value="Request Invite" name="RequestInvite" class="btn" />
</div>

After reading this link: CSS background color not working I have tried adding in the following at the end of hte css tag but it makes no difference:

overflow:auto;

Any ideas?

Community
  • 1
  • 1
Harry Boy
  • 4,159
  • 17
  • 71
  • 122
  • The CSS and HTML you've provided function as expected. This suggests that the issue is related to the larger code in your ASP.NET website, perhaps something is overriding `.btn`? – Robert Aug 19 '16 at 18:11
  • Can you try renaming `btn` to `btn1` to see if it makes a difference? – ConnorsFan Aug 19 '16 at 18:13
  • 1
    To debug this yourself, start with the browser-based tools in Chrome, Firefox, or IE. In all three, use F12 to open the tool. The details vary, but in all three tools you can explore the DOM (HTML) and see what styles apply to the current element. From there, you can determine whether your style is applied to the element or not, and if it does apply, whether other styles have a higher priority. If you can't determine the problem after using F12, update your question with whatever you learn from using F12. – Johnny Cee Aug 19 '16 at 19:14

0 Answers0