Get the App
SLTechnology News&Howtos  ›  Development  › 

How to use the time component of the amazeui framework in html5

Shulou Source: shulou.com Published: 2022-06-01 13:10:57 10月04日 Update

This article focuses on "how to use the time components of the amazeui framework in html5". Interested friends may wish to take a look. The method introduced in this paper is simple, fast and practical. Let's let the editor learn how to use the time components of the amazeui framework in html5.

I. Summary

To sum up in a word:

1. The icon is a font style: the font icon on the right side of input is a font style, so if you want to introduce a font file, find any project to get the font file inside and ok it.

2. Take a look at the official documentation: what js,css needs to be introduced into this time component, how to call the function, and how to initialize the event can hardly be given in more detail in the official documentation.

II. Amazeui time component testing

Code

Title .datetimeTest {width: 400px; margin:100px auto; border: 5px ridge # 95a283;} .datetimeTest2 {width: 400px; margin:100px auto; border: 5px ridge # 95a283 } $('# datetimepicker'). Datetimepicker ({format: 'yyyy-mm-dd hh:ii'}); $(' # datetimepicker2'). Datetimepicker ('update', new Date ()); $(' .form _ datetime-3') .datetimepicker ('update', new Date ())

Third, the download address and detailed description of the official website

Https://github.com/amazeui/datetimepicker

Instructions for use:

Get Amaze UI Datetime Picker

Download directly

Introduce Datetime Picker style (under the css directory) and Amaze UI style:

Import jQuery related files and Datetime Picker JS files (download package js directory):

Initialize Datetime Picker:

('# datetimepicker') .datetimepicker ({format: 'yyyy-mm-dd hh:ii'})

Call method

Set time format: format option:

('# datetimepicker') .datetimepicker ({format: 'yyyy-mm-dd hh:ii'})

You can also format the time through data-date-format:

('# datetimepicker'). Datetimepicker ()

IV. Plug-in introduction project does not work

1. Go to the F12 console more often to check the error message. I just don't have this consciousness in js, and I'm still messing around for a long time.

2. If js is not working, check the console.

You will find that it is caused by the introduction of jquery after the time plug-in js.

At this point, I believe you have a deeper understanding of "how to use the time components of the amazeui framework in html5". You might as well do it in practice. Here is the website, more related content can enter the relevant channels to inquire, follow us, continue to learn!

Tags: Time components fonts files styles frames content icons official console plug-ins documents methods formats directories projects learning work control utility Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno NVidia Linux Apple MariaDB Shulou Technology