jQuery – set am/pm format using jQuery timepicker Plugin with example
In this post we will give you information about jQuery – set am/pm format using jQuery timepicker Plugin with example. Hear we will give you detail about jQuery – set am/pm format using jQuery timepicker Plugin with exampleAnd how to use it also give you demo for it if it is necessary.
In this tutorial, you will know how to use Timepicker with AM/PM dropdown using jQuery timepicker plugin.
jQuery timepicker is very lightweight timepicker plugin and you can easily use option given in timepicker method.
Passing option is not required with timepicker method is an optional parameters.
It’s very easy to set up 12 hours time format with AM/PM using this timepicker plugin.
Following example will tell you how to use timepicker with am/pm dropdown option :
- <htmllang="en">
- <head>
- <title>jQuery - set am/pm format using jQuery timepicker Plugin with example</title>
- <scriptsrc="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.1.1/jquery.min.js"></script>
- <linkrel="stylesheet"href="https://cdnjs.cloudflare.com/ajax/libs/jquery-timepicker/1.10.0/jquery.timepicker.min.css">
- <scriptsrc="https://cdnjs.cloudflare.com/ajax/libs/jquery-timepicker/1.10.0/jquery.timepicker.min.js"></script>
- </head>
- <body>
- <divclass="container">
- <strong>Select Time : </strong>
- <inputclass="form-control"type="text"placeholder="click to show timepicker"id="example1">
- </div>
- <scripttype="text/javascript">
- $(document).ready(function () {
- $('#example1').timepicker();
- });
- </script>
- </body>
- </html>
<html lang="en"> <head> <title>jQuery - set am/pm format using jQuery timepicker Plugin with example</title> <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.1.1/jquery.min.js"></script> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/jquery-timepicker/1.10.0/jquery.timepicker.min.css"> <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery-timepicker/1.10.0/jquery.timepicker.min.js"></script> </head> <body> <div > <strong>Select Time : </strong> <input type="text" placeholder="click to show timepicker" id="example1"> </div> <script type="text/javascript"> $(document).ready(function () { $('#example1').timepicker(); }); </script> </body> </html>
Hope this code and post will helped you for implement jQuery – set am/pm format using jQuery timepicker Plugin with example. if you need any help or any feedback give it in comment section or you have good idea about this post you can give it comment section. Your comment will help us for help you more and improve us. we will give you this type of more interesting post in featured also so, For more interesting post and code Keep reading our blogs