html
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="viewport" content="width=device-width,initial-scale=1.0">
<title>无标题文档</title>
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@4.6.0/dist/css/bootstrap.min.css" integrity="sha384-B0vP5xmATw1+K9KRQjQERJvTumQW0nPEzvF6L/Z6nronJ3oUOFUFpCjEUQouq2+l" crossorigin="anonymous">
<style>
div{ display:flex}
label { width:100px}
small{ margin-left:120px}
</style>
</head>
<form class="container">
<div class="form-group row">
<label class="col-sm-12 col-md-1" for="user">账号:</label>
<input type="text" class="form-control col-sm-12 col-md-11" id="user" aria-describedby="emailHelp" placeholder="请输入账号">
</div>
<div class="form-group row">
<label class="col-sm-12 col-md-1" for="pw">密码:</label>
<input type="password" class="form-control col-sm-12 col-md-11" id="pw" placeholder="请输入密码">
</div>
<small id="emailHelp" class="form-text text-muted">建议:密码为6~11位,用字母和数字</small>
<div class="form-group row">
<label class="col-sm-12 col-md-1" for="name">姓名:</label>
<input type="text" class="form-control col-sm-12 col-md-11" id="name" aria-describedby="emailHelp" placeholder="请输入姓名">
</div>
<div class="form-group row">
<label class="col-sm-12 col-md-1" for="sf">身份:</label>
<select class="form-control col-sm-12 col-md-11" id="sf" >
<option>老师</option>
<option>学生</option>
</select>
</div>
<div class="form-group row">
<label class="col-sm-12 col-md-1" for="email">邮箱:</label>
<input type="email" class="form-control col-sm-12 col-md-11" id="email" aria-describedby="emailHelp" placeholder="请输入邮箱">
</div>
<div class="form-group row">
<label class="col-sm-12 col-md-1" for="exampleFormControlFile1">头像:</label>
<input type="file" class="form-control-file col-sm-12 col-md-11" id="exampleFormControlFile1">
</div>
<button type="submit" class="btn btn-success form-control ">Submit</button>
</form>
<body>
</body>
</html>