Remove full width to fieldset

0

Good day, I have a detail with a fieldset that I can not solve, I have named class to the fieldset and to the form with padding and width but it is still doing the responsive fieldset, and I want to have it fixed that is not responsive.

.frmingreso {
	padding-right: 80px;
}
input {
	padding: 12px 20px;
	margin: 8px 0;
	display: inline-block;
	border: 1px solid #ccc;
	border-radius: 4px;
	box-sizing: border-box; 
}

.btnenviar {
    background-color: white; 
    color: black; 
    border: 2px solid #4CAF50;
}

.btnenviar:hover {
    background-color: #59BDF2;
    color: white;
}
<fieldset class="frmingreso">
			<form action"login.php" method="POST">
				Usuario:<br>
				<input type="text" name="usuario"><br>
				Contraseña:<br>
				<input type="text" name="contrasena"><br><br>
				<input type="submit" name="btnenviar" value="Entrar" class="btnenviar">
</fieldset>
    
asked by EduardoVelazquez 04.08.2017 в 17:53
source

2 answers

1

The trick is the display property , you can use inline or inline-block.

.frmingreso {
	padding-right: 80px;
    border: 2px solid #3F4;
    display: inline-block;
}
input {
	padding: 12px 20px;
	margin: 8px 0;
	display: inline-block;
	border: 1px solid #ccc;
	border-radius: 4px;
	box-sizing: border-box; 
}

.btnenviar {
    background-color: white; 
    color: black; 
    border: 2px solid #4CAF50;
}

.btnenviar:hover {
    background-color: #59BDF2;
    color: white;
}
<fieldset class="frmingreso">
	<form action"login.php" method="POST">
		Usuario:<br>
		<input type="text" name="usuario"><br>
		Contraseña:<br>
		<input type="text" name="contrasena"><br><br>
		<input type="submit" name="btnenviar" value="Entrar" class="btnenviar">
	</form>
</fieldset>
    
answered by 04.08.2017 / 18:36
source
0

You can define the width in the following way

.frmingreso{
  width: 180px;
}

see link: link

    
answered by 04.08.2017 в 18:26