add profile picture to a form in html and css
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
<div id="profile-container">
<image id="profileImage" src="http://lorempixel.com/100/100" />
</div>
<input id="imageUpload" type="file"
name="profile_photo" placeholder="Photo" required="" capture>
4.2
5
#imageUpload
{
display: none;
}
#profileImage
{
cursor: pointer;
}
#profile-container {
width: 150px;
height: 150px;
overflow: hidden;
-webkit-border-radius: 50%;
-moz-border-radius: 50%;
-ms-border-radius: 50%;
-o-border-radius: 50%;
border-radius: 50%;
}
#profile-container img {
width: 150px;
height: 150px;
}
Thank you!
5
0
3.83
6
<div class="signup-w3ls">
<div class="signup-agile1">
<form action="#" method="post">
<div class="form-control">
<label class="header">Profile Photo:</label>
<input id="image" type="file" name="profile_photo" placeholder="Photo" required="" capture>
</div>
<div class="form-control">
<label class="header">Store Name :</label>
<input type="text" id="store_name" name="store_name" placeholder="Store Name" title="Please enter your First Name" required="">
</div>
<div class="form-control">
<label class="header">Store Type :</label>
<input type="text" id="store_type" name="store_type" placeholder="Store Type" title="Please enter your Last Name" required="">
</div>
<div class="form-control">
<label class="header">Owner Type :</label>
<input type="text" id="owner_type" name="owner_type" placeholder="Owner Type" title="Please enter a valid email" required="">
</div>
<div class="form-control">
<label class="header">Website :</label>
<input type="url" id="website" name="website" placeholder="Website" id="password1" required="">
</div>
<div class="form-control">
<label class="header">Contact Number :</label>
<input type="text" id="contact_number" name="contact_number" placeholder="Contact Number" required="">
</div>
<div class="form-control">
<label class="header">Contact Email :</label>
<input type="email" id="contact_email" name="contact_email" placeholder="Contact Email" required="">
</div>
<input type="submit" class="register" value="Register">
</form>
</div>
</div>
Thank you!
6
0
Are there any code examples left?
New code examples in category CSS
-
CSS 2022-03-27 22:50:16 make text bigger html5
-
CSS 2022-03-27 21:40:08 move list item to left css
-
CSS 2022-03-27 21:35:05 reduce image size css
-
CSS 2022-03-27 21:30:21 css image background center horizontally in div
-
CSS 2022-03-27 21:05:02 css button styles
-
CSS 2022-03-27 18:50:09 compass font awesome
-
CSS 2022-03-27 18:50:06 modal in materialize css
-
CSS 2022-03-27 17:55:12 box round corner css
-
CSS 2022-03-27 17:45:12 jquery add css
-
CSS 2022-03-27 17:45:01 css image fit in div with aspect ratio