Simple Form Issue:
- Problem: The width of the
<input>
element is not expanding to 100% - If the class
form-control
is applied to the element, it should have a width of 100%
Screenshot: Output from Visual Studio
- Utilizing Visual Studio 2017 (MVC5 ASP.NET C#) - identical code as shown below
- Both
<input>
and<textarea>
are constrained to a specific width. Attempting to setstyle="width:100%"
explicitly has no effect - Works flawlessly when tested on (https://jsfiddle.net/Dhinesh_Ram/0yh4Lx7w/) or "W3 school's Tryit Editor" but not within Visual Studio
- Browsers I've attempted to troubleshoot in: Chrome, IE, Edge
<link rel="stylesheet" href="https://bootswatch.com/3/lumen/bootstrap.min.css" />
<div class="well bs-component">
<form class="form-horizontal">
<fieldset>
<legend>Feedback</legend>
<div class="form-group">
<label for="inputName" class="col-lg-2 control-label">Name</label>
<div class="col-lg-10">
<input type="text" class="form-control" id="inputName" placeholder="Enter your name" />
</div>
</div>
<div class="form-group">
<label for="textArea" class="col-lg-2 control-label">Message</label>
<div class="col-lg-10">
<textarea class="form-control" rows="3" id="textArea" placeholder="Your message"></textarea>
<span class="help-block">Detail if reporting a bug, including a screenshot would be beneficial</span>
</div>
</div>
</fieldset>
</form>
</div>