-
Notifications
You must be signed in to change notification settings - Fork 0
/
form.html
940 lines (913 loc) · 66.2 KB
/
form.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
<!DOCTYPE html>
<html class="rd-template-admin">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Form | Rundiz template for admin</title>
<link rel="stylesheet" href="assets/css/sanitize/sanitize.css?npm-v=github%3Acsstools%2Fsanitize.css%23main">
<link rel="stylesheet" href="assets/css/sanitize/typography.css?npm-v=github%3Acsstools%2Fsanitize.css%23main">
<link rel="stylesheet" href="assets/css/sanitize/forms.css?npm-v=github%3Acsstools%2Fsanitize.css%23main">
<link rel="stylesheet" href="assets/font-awesome/css/all.min.css?npm-v=6.0.0">
<link rel="stylesheet" href="assets/css/smartmenus/sm-core-css.css?npm-v=1.1.1">
<link rel="stylesheet" href="assets/css/smartmenus/sm-rdta/sm-rdta.css?v=3ef227ffe8516995345c01c6f1a9b9a2">
<link rel="stylesheet" href="assets/css/rdta/typo-and-form/typo-and-form.css?v=782df4c386eb481a46cf4c87aeeb7d40">
<link rel="stylesheet" href="assets/css/rdta/rundiz-template-admin.css?v=c4af81a435d9eb76bbce005b24a0154d">
<link rel="stylesheet" href="assets/css/rdta-demo-pages.css?v=5c5a3502c8c15fba309fc170b49e4583">
<link class="exclude-preview" rel="stylesheet" href="assets/css-preview/view-source.css?v=856c7087abf9e79c34c08320f05131ce"><!-- preview source css excluded. -->
</head>
<body>
<header class="rd-navbar">
<button class="rd-sidebar-toggler" data-target=".rd-page-wrapper" title="Toggle side bar menu"><i class="fa-solid fa-bars fa-fw"></i><span class="screen-reader-only" aria-hidden="true">Toggle side bar menu</span></button>
<div class="rd-site-brand"><a href="./">Admin Dashboard</a></div><!--.rd-site-brand-->
<nav class="nav-right">
<ul class="sm sm-rdta navbar">
<li><a href="#" onclick="return false;"><i class="fa-solid fa-globe fa-fw"></i></a>
<ul>
<li><a href="javascript:alert('link clicked');">Thai</a></li>
<li class="is-active"><a href="javascript:alert('link clicked');">English</a></li>
</ul>
</li>
<li><a href="#" onclick="return false;"><i class="fa-solid fa-bell fa-fw"></i> <span class="rd-notification-badge tiny">3</span></a>
<ul>
<li><a href="#" onclick="return false;">Approve new comments</a></li>
<li><a href="#" onclick="return false;">Approve new posts</a></li>
<li><a href="#" onclick="return false;">There are new contact messages</a></li>
</ul>
</li>
<li class="user"><a href="#" onclick="return false;"><i class="fa-regular fa-circle-user"></i></a>
<ul>
<li><a>Hello, user name</a></li>
<li><a href="#" onclick="return false;">Edit your account</a></li>
<li><a href="#" onclick="return false;">Logout</a></li>
</ul>
</li>
</ul>
</nav><!--.nav-right-->
</header><!--.rd-navbar-->
<div class="rd-page-wrapper">
<div class="rd-sidebar-back"></div>
<section class="rd-sidebar">
<h2 class="screen-reader-only">Sidebar menus</h2>
<div class="rd-sidebar-inner">
<ul class="rd-sidebar-item-list sm sm-vertical sm-rdta">
<li><a href="#" onclick="return false;" title="Admin home"><i class="sidebar-icon fa-solid fa-gauge-high fa-fw"></i> <span class="rd-sidebar-menu-text">Admin home</span></a>
<ul>
<li><a href="./">Admin dashboard</a></li>
<li><a href="javascript:alert('link clicked');">Update</a></li>
</ul>
</li>
<li><a href="#" onclick="return false;" title="Components"><i class="sidebar-icon fa-solid fa-boxes-stacked fa-fw"></i> <span class="rd-sidebar-menu-text">Components</span></a>
<ul>
<li class="sub-menu-heading"><a>Typography & getting started</a></li>
<li><a href="typography.html">Typography & reset</a></li>
<li><a href="basic-layout.html">Basic layout (getting started)</a></li>
<li class="divider"></li>
<li class="sub-menu-heading"><a>More components</a></li>
<li><a href="accordion.html">Accordion</a></li>
<li><a href="alert-box.html">Alert box</a></li>
<li><a href="alert-dialog.html">Alert dialog</a></li>
<li><a href="badge.html">Badge</a></li>
<li><a href="button.html">Button</a></li>
<li><a href="columns-flex.html">Columns flex</a></li>
<li><a href="datatable.html">Data table</a></li>
<li><a href="datatables-js.html">DataTables JS</a></li>
<li><a href="dialog.html">Dialog</a></li>
<li><a href="embeds.html">Embeds</a></li>
<li><a href="form.html">Form</a></li>
<li><a href="helpers.html">Helpers</a></li>
<li><a href="pagination.html">Pagination</a></li>
<li><a href="tabs.html">Tabs</a></li>
<li><a href="text.html">Text</a></li>
<li><a href="tooltips.html">Tooltips</a></li>
</ul>
</li>
<li><a href="#" onclick="return false;" title="Examples"><i class="sidebar-icon fa-solid fa-laptop-code"></i> <span class="rd-sidebar-menu-text">Examples</span></a>
<ul>
<li><a href="example-login.html">Login page</a></li>
<li><a href="example-logout.html">Logout page</a></li>
</ul>
</li>
<li><a href="#" onclick="return false;" title="Tools & guide"><i class="sidebar-icon fa-solid fa-code fa-fw"></i> <span class="rd-sidebar-menu-text">Tools & guide</span></a>
<ul>
<li><a href="credits.html">Credits</a></li>
<li><a href="https://css-tricks.com/snippets/css/complete-guide-grid/" target="tools_cssgrid">CSS grid</a></li>
<li><a href="https://css-tricks.com/snippets/css/a-guide-to-flexbox/" target="tools_cssflex">CSS flex box</a></li>
<li><a href="https://www.w3.org/wiki/HTML_structural_elements" target="tools_html5structural">HTML 5 structural elements</a></li>
<li><a href="http://pxtoem.com/" target="pxtoemconverter">Pixel / <code>em</code> converter</a></li>
</ul>
</li>
<li class="divider"></li>
<li class="sub-menu-heading"><a onclick="return false;" title="Experiments"><i class="sidebar-icon fa-solid fa-vial fa-fw"></i> <span class="rd-sidebar-menu-text">Experiments</span></a></li>
<li><a href="#" onclick="return false;" title="Sticky menu"><i class="sidebar-icon fa-solid fa-thumbtack fa-fw"></i> <span class="rd-sidebar-menu-text">Stickey menu</span></a>
<ul>
<li><a href="stickymenu-long-content.html">Sticky menu (long content)</a></li>
<li><a href="stickymenu-long-menu.html">Sticky menu (long menu)</a></li>
<li><a href="stickymenu-long-content-menu.html">Sticky menu (long content & menu)</a></li>
</ul>
</li>
<li><a href="#" onclick="return false;" title="Sub menus"><i class="sidebar-icon fa-solid fa-folder-tree fa-fw"></i> <span class="rd-sidebar-menu-text">Sub menus</span></a>
<ul>
<li><a href="javascript:alert('link clicked');">1</a>
<ul>
<li><a href="javascript:alert('link clicked');">1.1</a>
<ul>
<li><a href="javascript:alert('link clicked');">1.1.1</a>
<ul>
<li><a href="javascript:alert('link clicked');">1.1.1.1</a></li>
<li><a href="#" onclick="return false;">1.1.1.2</a></li>
<li><a href="#" onclick="return false;">1.1.1.3</a></li>
<li><a href="#" onclick="return false;">1.1.1.4</a></li>
<li><a href="#" onclick="return false;">1.1.1.5</a></li>
</ul>
</li>
<li><a href="#" onclick="return false;">1.1.2</a></li>
<li><a href="#" onclick="return false;">1.1.3</a></li>
<li><a href="#" onclick="return false;">1.1.4</a></li>
<li><a href="#" onclick="return false;">1.1.5</a></li>
</ul>
</li>
<li><a href="#" onclick="return false;">1.2</a></li>
<li><a href="#" onclick="return false;">1.3</a></li>
<li><a href="#" onclick="return false;">1.4</a></li>
<li><a href="#" onclick="return false;">1.5</a></li>
</ul>
</li>
<li><a href="#" onclick="return false;">2 (Deep sub menus)</a>
<ul>
<li><a href="#" onclick="return false;">2.1</a></li>
<li><a href="#" onclick="return false;">2.2</a>
<ul>
<li><a href="#" onclick="return false;">2.2.1</a></li>
<li><a href="#" onclick="return false;">2.2.2</a>
<ul>
<li><a href="#" onclick="return false;">2.2.2.1</a></li>
<li><a href="#" onclick="return false;">2.2.2.2</a>
<ul>
<li><a href="#" onclick="return false;">2.2.2.2.1</a></li>
<li><a href="#" onclick="return false;">2.2.2.2.2</a>
<ul>
<li><a href="#" onclick="return false;">2.2.2.2.2.1</a></li>
<li><a href="#" onclick="return false;">2.2.2.2.2.2</a></li>
<li><a href="#" onclick="return false;">2.2.2.2.2.3</a></li>
</ul>
</li>
<li><a href="#" onclick="return false;">2.2.2.2.3</a></li>
</ul>
</li>
<li><a href="#" onclick="return false;">2.2.2.3</a></li>
</ul>
</li>
<li><a href="#" onclick="return false;">2.2.3</a></li>
</ul>
</li>
<li><a href="#" onclick="return false;">2.3</a></li>
</ul>
</li>
<li><a href="#" onclick="return false;">3 (Very long sub menus)</a>
<ul>
<!-- it is recommended that you should not have more than 15 items per sub menu, or you have to modify options in `rdtaSidebarSmartMenus()` function -->
<li><a href="#" onclick="return false;">3.1</a></li>
<li><a href="#" onclick="return false;">3.2</a></li>
<li><a href="#" onclick="return false;">3.3</a></li>
<li><a href="#" onclick="return false;">3.4</a></li>
<li><a href="#" onclick="return false;">3.5</a></li>
<li><a href="#" onclick="return false;">3.6</a></li>
<li><a href="#" onclick="return false;">3.7</a></li>
<li><a href="#" onclick="return false;">3.8</a></li>
<li><a href="#" onclick="return false;">3.9</a></li>
<li><a href="#" onclick="return false;">3.10</a></li>
<li><a href="#" onclick="return false;">3.11</a></li>
<li><a href="#" onclick="return false;">3.12</a></li>
<li><a href="#" onclick="return false;">3.13</a></li>
<li><a href="#" onclick="return false;">3.14</a></li>
<li><a href="#" onclick="return false;">3.15</a></li>
<li><a href="#" onclick="return false;">3.16</a></li>
<li><a href="#" onclick="return false;">3.17</a></li>
<li><a href="#" onclick="return false;">3.18</a></li>
<li><a href="#" onclick="return false;">3.19</a></li>
<li><a href="#" onclick="return false;">3.20</a></li>
<li><a href="#" onclick="return false;">3.21</a></li>
<li><a href="#" onclick="return false;">3.22</a></li>
<li><a href="#" onclick="return false;">3.23</a></li>
<li><a href="#" onclick="return false;">3.24</a></li>
<li><a href="#" onclick="return false;">3.25</a></li>
<li><a href="#" onclick="return false;">3.26</a></li>
<li><a href="#" onclick="return false;">3.27</a></li>
<li><a href="#" onclick="return false;">3.28</a></li>
<li><a href="#" onclick="return false;">3.29</a></li>
<li><a href="#" onclick="return false;">3.30</a></li>
<li><a href="#" onclick="return false;">3.31</a></li>
<li><a href="#" onclick="return false;">3.32</a></li>
<li><a href="#" onclick="return false;">3.33</a></li>
<li><a href="#" onclick="return false;">3.34</a></li>
<li><a href="#" onclick="return false;">3.35</a></li>
<li><a href="#" onclick="return false;">3.36</a></li>
<li><a href="#" onclick="return false;">3.37</a></li>
<li><a href="#" onclick="return false;">3.38</a></li>
<li><a href="#" onclick="return false;">3.39</a></li>
<li><a href="#" onclick="return false;">3.40</a></li>
<li><a href="#" onclick="return false;">3.41</a></li>
<li><a href="#" onclick="return false;">3.42</a></li>
<li><a href="#" onclick="return false;">3.43</a></li>
<li><a href="#" onclick="return false;">3.44</a></li>
<li><a href="#" onclick="return false;">3.45</a></li>
<li><a href="#" onclick="return false;">3.46</a></li>
<li><a href="#" onclick="return false;">3.47</a></li>
<li><a href="#" onclick="return false;">3.48</a></li>
<li><a href="#" onclick="return false;">3.49</a></li>
<li><a href="#" onclick="return false;">3.50</a></li>
</ul>
</li>
<li><a href="#" onclick="return false;">4</a></li>
<li><a href="#" onclick="return false;">5</a></li>
<li><a href="#" onclick="return false;">6</a></li>
<li><a href="#" onclick="return false;">7</a></li>
<li><a href="#" onclick="return false;">8</a></li>
<li class="divider"><a href="#" onclick="alert('Nothing works here!'); return false;">Nothing here will be display.</a></li>
<li><a href="#" onclick="return false;">The above is <code>li.divider</code></a></li>
<li class="sub-menu-heading"><a href="#" onclick="return false;">This is <code>li.sub-menu-heading</code></a></li>
<li><a href="#" onclick="return false;">9 (Sub menu components)</a>
<ul>
<li><a href="#" onclick="return false;">1</a></li>
<li><a href="#" onclick="return false;">2</a></li>
<li><a href="#" onclick="return false;">3</a></li>
<li class="divider"><a href="#" onclick="alert('Nothing works here!'); return false;">Nothing here will be display.</a></li>
<li><a href="#" onclick="return false;">Divider in sub menus</a></li>
<li class="sub-menu-heading"><a>Deeper sub menu heading</a></li>
<li><a href="#" onclick="return false;">4</a></li>
<li><a href="#" onclick="return false;">5</a></li>
</ul>
</li>
<li><a href="#" onclick="return false;">10</a></li>
</ul>
</li>
<li><a href="#" onclick="return false;" title="Long menu text"><i class="sidebar-icon fa-solid fa-greater-than-equal fa-fw"></i> <span class="rd-sidebar-menu-text">Longggggggggggggggggg menu text</span></a>
<ul>
<li><a href="#" onclick="return false;">longggggggggggggggggggggggggggggggggggggggggggg submenu item 1</a>
<ul>
<li><a href="#" onclick="return false;">longggggggggggggggggggggggggggggggggggggggggggg submenu item 1.1</a></li>
<li><a href="#" onclick="return false;">longggggggggggggggggggggggggggggggggggggggggggg submenu item 1.2</a></li>
<li><a href="#" onclick="return false;">longggggggggggggggggggggggggggggggggggggggggggg submenu item 1.3</a></li>
</ul>
</li>
<li><a href="#" onclick="return false;">longggggggggggggggggggggggggggggggggggggggggggg submenu item 2</a>
<ul>
<li><a href="#" onclick="return false;">longggggggggggggggggggggggggggggggggggggggggggg submenu item 2.1</a>
<ul>
<li><a href="#" onclick="return false;">longggggggggggggggggggggggggggggggggggggggggggg submenu item 2.1.1</a></li>
<li><a href="#" onclick="return false;">longggggggggggggggggggggggggggggggggggggggggggg submenu item 2.1.2</a></li>
<li><a href="#" onclick="return false;">longggggggggggggggggggggggggggggggggggggggggggg submenu item 2.1.3</a></li>
</ul>
</li>
<li><a href="#" onclick="return false;">longggggggggggggggggggggggggggggggggggggggggggg submenu item 2.2</a></li>
<li><a href="#" onclick="return false;">longggggggggggggggggggggggggggggggggggggggggggg submenu item 2.3</a></li>
</ul>
</li>
<li><a href="#" onclick="return false;">longggggggggggggggggggggggggggggggggggggggggggg submenu item 3</a></li>
<li><a href="#" onclick="return false;">longggggggggggggggggggggggggggggggggggggggggggg submenu item 4</a></li>
<li><a href="#" onclick="return false;">longggggggggggggggggggggggggggggggggggggggggggg submenu item 5</a></li>
</ul>
</li>
</ul>
<ul class="rd-sidebar-item-list rd-sidebar-expand-collapse-controls">
<li>
<a data-target=".rd-page-wrapper" title="Expane/collapse menu"><i class="sidebar-icon faicon fa-solid fa-chevron-left fa-fw" data-toggle-icon="fa-chevron-left fa-chevron-right"></i> <span class="screen-reader-only" aria-hidden="true">Expane/collapse menu</span></a>
<hr>
</li>
</ul>
</div><!--.rd-sidebar-inner-->
</section><!--.rd-sidebar-->
<main>
<nav>
<ul class="rd-breadcrumb">
<li><a href="./">Home</a></li>
<li class="current"><a href="#" onclick="return false;">Form</a></li>
</ul>
</nav>
<div class="rd-page-content">
<h1>Form</h1>
<p>The form controls</p>
<hr>
<h2>Examples</h2>
<h3>Input box types</h3>
<form class="rd-form code-sample-form-inputboxtypes rd-block-level-margin-bottom">
<div class="form-group">
<label class="control-label" for="input-type-color">Input Color</label>
<div class="control-wrapper">
<input id="input-type-color" type="color" name="demo-input-color">
</div>
</div>
<div class="form-group">
<label class="control-label" for="input-type-date">Input Date</label>
<div class="control-wrapper">
<input id="input-type-date" type="date" name="demo-input-date">
</div>
</div>
<div class="form-group">
<label class="control-label" for="input-type-datetime-local">Input Datetime-local</label>
<div class="control-wrapper">
<input id="input-type-datetime-local" type="datetime-local" name="demo-input-datetime-local">
</div>
</div>
<div class="form-group">
<label class="control-label" for="input-type-email">Input Email</label>
<div class="control-wrapper">
<input id="input-type-email" type="email" name="demo-input-email">
</div>
</div>
<div class="form-group">
<label class="control-label" for="input-type-file">Input File</label>
<div class="control-wrapper">
<input id="input-type-file" type="file" name="demo-input-file">
</div>
</div>
<div class="form-group">
<label class="control-label" for="input-type-month">Input Month</label>
<div class="control-wrapper">
<input id="input-type-month" type="month" name="demo-input-month">
</div>
</div>
<div class="form-group">
<label class="control-label" for="input-type-number">Input Number</label>
<div class="control-wrapper">
<input id="input-type-number" type="number" name="demo-input-number">
</div>
</div>
<div class="form-group">
<label class="control-label" for="input-type-password">Input Password</label>
<div class="control-wrapper">
<input id="input-type-password" type="password" name="demo-input-password">
</div>
</div>
<div class="form-group">
<label class="control-label" for="input-type-range">Input Range</label>
<div class="control-wrapper">
<input id="input-type-range" type="range" name="demo-input-range">
</div>
</div>
<div class="form-group">
<label class="control-label" for="input-type-search">Input Search</label>
<div class="control-wrapper">
<input id="input-type-search" type="search" name="demo-input-search">
</div>
</div>
<div class="form-group">
<label class="control-label" for="input-type-tel">Input Tel</label>
<div class="control-wrapper">
<input id="input-type-tel" type="tel" name="demo-input-tel">
</div>
</div>
<div class="form-group">
<label class="control-label" for="input-type-text">Input Text</label>
<div class="control-wrapper">
<input id="input-type-text" type="text" name="demo-input-text">
</div>
</div>
<div class="form-group">
<label class="control-label" for="input-type-time">Input Time</label>
<div class="control-wrapper">
<input id="input-type-time" type="time" name="demo-input-time">
</div>
</div>
<div class="form-group">
<label class="control-label" for="input-type-url">Input Url</label>
<div class="control-wrapper">
<input id="input-type-url" type="url" name="demo-input-url">
</div>
</div>
<div class="form-group">
<label class="control-label" for="input-type-week">Input Week</label>
<div class="control-wrapper">
<input id="input-type-week" type="week" name="demo-input-week">
</div>
</div>
<fieldset>
<legend>With attributes</legend>
<div class="form-group">
<label class="control-label" for="input-type-text-readonly">Input text readonly</label>
<div class="control-wrapper">
<input id="input-type-text-readonly" type="text" readonly="">
</div>
</div>
<div class="form-group">
<label class="control-label" for="input-type-text-disabled">Input text disabled</label>
<div class="control-wrapper">
<input id="input-type-text-disabled" type="text" disabled="">
<div class="form-description">The help message about this form input.</div>
</div>
</div>
<div class="form-group">
<label class="control-label" for="input-type-text-invalid">Input text invalid</label>
<div class="control-wrapper">
<input id="input-type-text-invalid" class="rd-input-invalid" type="text">
<div class="form-description">Add <code>rd-input-invalid</code> class to the input.</div>
</div>
</div>
</fieldset>
</form>
<h4>Source</h4>
<pre class="preview-source" data-target-src=".code-sample-form-inputboxtypes" data-target-src-remove-first-space="20" data-remove-classes="rd-block-level-margin-bottom"></pre>
<h3>Input file</h3>
<form class="rd-form code-sample-form-inputfile rd-block-level-margin-bottom" method="post" enctype="multipart/form-data">
<div class="form-group">
<label class="control-label" for="rd-inputfile_single">Input single file</label>
<div class="control-wrapper">
<span class="rd-button info small rd-inputfile" tabindex="0">
<span class="label">Choose file</span>
<input id="rd-inputfile_single" type="file" name="rd-inputfile1" tabindex="-1">
</span>
<span class="rd-input-files-queue"></span>
<template class="rd-inputfile-reset-button">
<button class="rd-button tiny" type="button" onclick="return RundizTemplateAdmin.resetInputFile(this);" title="Remove files"><i class="fa-solid fa-xmark"></i><span class="screen-reader-only">Remove files</span></button>
</template>
</div>
</div>
<div class="form-group">
<label class="control-label" for="rd-inputfile_multiple">Input multiple files</label>
<div class="control-wrapper">
<span class="rd-button info small rd-inputfile" tabindex="0">
<span class="label">Choose files</span>
<input id="rd-inputfile_multiple" type="file" name="rd-inputfile_multiple[]" multiple="" tabindex="-1">
</span>
<span class="rd-input-files-queue"></span>
<template class="rd-inputfile-reset-button">
<button class="rd-button tiny" type="button" onclick="return RundizTemplateAdmin.resetInputFile(this);" title="Remove files"><i class="fa-solid fa-xmark"></i><span class="screen-reader-only">Remove files</span></button>
</template>
</div>
</div>
<div class="form-group">
<label class="control-label" for="rd-inputfile_disabled">Input file disabled</label>
<div class="control-wrapper">
<span class="rd-button info small disabled rd-inputfile" tabindex="0">
<span class="label">Choose file</span>
<input id="rd-inputfile_disabled" type="file" name="rd-inputfile-disabled" disabled="" tabindex="-1">
</span>
<span class="rd-input-files-queue"></span>
<template class="rd-inputfile-reset-button">
<button class="rd-button tiny" type="button" onclick="return RundizTemplateAdmin.resetInputFile(this);" title="Remove files"><i class="fa-solid fa-xmark"></i><span class="screen-reader-only">Remove files</span></button>
</template>
<div class="form-description">The help message about this form input.</div>
</div>
</div>
<div class="form-group">
<label class="control-label" for="rd-inputfile_invalid">Input file invalid</label>
<div class="control-wrapper">
<span class="rd-button info small rd-input-invalid rd-inputfile" tabindex="0">
<span class="label">Choose file</span>
<input id="rd-inputfile_invalid" type="file" name="rd-inputfile-invalid" tabindex="-1">
</span>
<span class="rd-input-files-queue"></span>
<template class="rd-inputfile-reset-button">
<button class="rd-button tiny" type="button" onclick="return RundizTemplateAdmin.resetInputFile(this);" title="Remove files"><i class="fa-solid fa-xmark"></i><span class="screen-reader-only">Remove files</span></button>
</template>
<div class="form-description">Add <code>rd-input-invalid</code> class to the input.</div>
</div>
</div>
<button class="rd-button primary" type="button" onclick="rdtaGetFormData(this);">Submit (see console)</button>
</form>
<h4>Source</h4>
<pre class="preview-source" data-target-src=".code-sample-form-inputfile" data-target-src-remove-first-space="20" data-remove-classes="rd-block-level-margin-bottom"></pre>
<h3>Dynamically insert/update input file</h3>
<form class="rd-form rd-block-level-margin-bottom" method="post" enctype="multipart/form-data">
<div id="demo-custom-inputfile-placeholder" style="border: 1px dashed #ccc; padding: 0.625rem;"></div>
<button type="button" onclick="rdtaAddCustomInputFile('demo-custom-inputfile-placeholder');">Click here to add an input file</button>
<h4>Custom input file events</h4>
<table class="rd-datatable">
<thead>
<tr>
<th>Event type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td>rdta.custominputfile.addedfilesqueue</td>
<td>This event is fired when files queue were added.</td>
</tr>
<tr>
<td>rdta.custominputfile.change</td>
<td>This event is fired when input file has changed.</td>
</tr>
</tbody>
</table>
<div id="demo-custom-inputfile-events-placeholder" style="border: 1px dashed #ccc; padding: 0.625rem;"></div>
</form>
<h4>Source</h4>
<pre>document.addEventListener('rdta.custominputfile.change', (event) => {console.log(event);}));
document.addEventListener('rdta.custominputfile.addedfilesqueue', (event) => {console.log(event);}));</pre>
<h3>Checkbox/radio</h3>
<form class="rd-form rd-block-level-margin-bottom code-sample-form-checkboxradio">
<div class="form-group">
<label class="control-label">Input radio</label>
<div class="control-wrapper">
<label><input type="radio" name="input-radio" value="1"> Input radio option 1</label><br>
<label><input type="radio" name="input-radio" value="2"> Input radio option 2</label><br>
<label class="disabled"><input type="radio" name="input-radio" value="3" disabled=""> Input radio option 3 disabled</label><br>
<label><input class="rd-input-invalid" type="radio" name="input-radio" value="invalid"> Input radio option 3 invalid</label>
<div class="form-description">The help message about this form input.</div>
</div>
</div>
<div class="form-group">
<label class="control-label">Input radio inline</label>
<div class="control-wrapper">
<label><input type="radio" name="input-radio-inline" value="1"> 1</label>
<label><input type="radio" name="input-radio-inline" value="2"> 2</label>
<label class="disabled"><input type="radio" name="input-radio-inline" value="3" disabled=""> 3 disabled</label>
</div>
</div>
<div class="form-group">
<label class="control-label">Input checkbox</label>
<div class="control-wrapper">
<label><input type="checkbox" name="checkbox[]"> Input checkbox 1</label><br>
<label><input type="checkbox" name="checkbox[]"> Input checkbox 2</label><br>
<label class="disabled"><input type="checkbox" name="checkbox[]" disabled=""> Input checkbox 3 disabled</label><br>
<label><input class="rd-input-invalid" type="checkbox" name="checkbox[]"> Input checkbox 3 invalid</label>
</div>
</div>
<div class="form-group">
<label class="control-label">Input checkbox inline</label>
<div class="control-wrapper">
<label><input type="checkbox" name="checkbox-inline[]"> 1</label>
<label><input type="checkbox" name="checkbox-inline[]"> 2</label>
<label class="disabled"><input type="checkbox" name="checkbox-inline[]" disabled=""> 3</label>
<div class="form-description">The help message about this form input.</div>
</div>
</div>
</form>
<h4>Source</h4>
<pre class="preview-source" data-target-src=".code-sample-form-checkboxradio" data-target-src-remove-first-space="20" data-remove-classes="rd-block-level-margin-bottom"></pre>
<h3>Select box</h3>
<form class="rd-form rd-block-level-margin-bottom code-sample-form-selectbox">
<div class="form-group">
<label class="control-label" for="input-select">Select box</label>
<div class="control-wrapper">
<select id="input-select" name="demo-selectbox">
<optgroup label="Group1">
<option>1</option>
<option>2</option>
<option>3</option>
</optgroup>
<optgroup label="Group2">
<option>1</option>
<option>2</option>
<option>3</option>
</optgroup>
<option>out of optgroup</option>
</select>
</div>
</div>
<div class="form-group">
<label class="control-label" for="input-select-multiple">Select box multiple</label>
<div class="control-wrapper">
<select id="input-select-multiple" multiple="" name="demo-selectbox-multiple">
<optgroup label="Group1">
<option>1</option>
<option>2</option>
<option>3</option>
</optgroup>
<optgroup label="Group2">
<option>1</option>
<option>2</option>
<option>3</option>
</optgroup>
<option>out of optgroup</option>
</select>
</div>
</div>
<div class="form-group">
<label class="control-label" for="input-select-disabled">Select box disabled</label>
<div class="control-wrapper">
<select id="input-select-disabled" disabled="" name="demo-selectbox-disabled">
<option>1</option>
<option>2</option>
<option>3</option>
</select>
</div>
</div>
<div class="form-group">
<label class="control-label" for="input-select-invalid">Select box invalid</label>
<div class="control-wrapper">
<select id="input-select-invalid" class="rd-input-invalid" name="demo-selectbox-invalid">
<option>1</option>
<option>2</option>
<option>3</option>
</select>
</div>
<div class="form-description">Add <code>rd-input-invalid</code> class to the select box.</div>
</div>
</form>
<h4>Source</h4>
<pre class="preview-source" data-target-src=".code-sample-form-selectbox" data-target-src-remove-first-space="20" data-remove-classes="rd-block-level-margin-bottom"></pre>
<h3>Text area</h3>
<form class="rd-form rd-block-level-margin-bottom code-sample-form-textarea">
<div class="form-group">
<label class="control-label" for="input-textarea">Textarea</label>
<div class="control-wrapper">
<textarea id="input-textarea" name="demo-textarea"></textarea>
</div>
</div>
<div class="form-group">
<label class="control-label" for="input-textarea-disabled">Textarea disabled</label>
<div class="control-wrapper">
<textarea id="input-textarea-disabled" disabled="" name="demo-textarea-disabled"></textarea>
</div>
</div>
<div class="form-group">
<label class="control-label" for="input-textarea-invalid">Textarea invalid</label>
<div class="control-wrapper">
<textarea id="input-textarea-invalid" class="rd-input-invalid" name="demo-textarea-invalid"></textarea>
</div>
</div>
</form>
<h4>Source</h4>
<pre class="preview-source" data-target-src=".code-sample-form-textarea" data-target-src-remove-first-space="20" data-remove-classes="rd-block-level-margin-bottom"></pre>
<hr>
<h3>Horizontal form</h3>
<p>To make form fields display horizontal, just add <code>horizontal</code> class to the <code>form</code> element.</p>
<form class="rd-form horizontal rd-block-level-margin-bottom code-sample-form-horizontal">
<div class="form-group">
<label class="control-label" for="input-type-text2">Input text</label>
<div class="control-wrapper">
<input id="input-type-text2" type="text">
<div class="form-description">The help message about this form input.</div>
</div>
</div>
<fieldset>
<legend>Input checkbox/radio</legend>
<div class="form-group">
<label class="control-label">Input radio</label>
<div class="control-wrapper">
<label><input type="radio" name="input-radio" value="1"> Input radio option 1</label><br>
<label><input type="radio" name="input-radio" value="2"> Input radio option 2</label><br>
</div>
</div>
<div class="form-group">
<label class="control-label">Input radio inline</label>
<div class="control-wrapper">
<label><input type="radio" name="input-radio-inline" value="1"> 1</label>
<label><input type="radio" name="input-radio-inline" value="2"> 2</label>
</div>
</div>
<div class="form-group">
<label class="control-label">Input checkbox</label>
<div class="control-wrapper">
<label><input type="checkbox"> Input checkbox 1</label><br>
<label><input type="checkbox"> Input checkbox 2</label><br>
</div>
</div>
<div class="form-group">
<label class="control-label">Input checkbox inline</label>
<div class="control-wrapper">
<label><input type="checkbox"> 1</label>
<label><input type="checkbox"> 2</label>
</div>
</div>
</fieldset>
<div class="form-group">
<label class="control-label" for="input-select2">Select box</label>
<div class="control-wrapper">
<select id="input-select2">
<optgroup label="Group1">
<option>1</option>
<option>2</option>
<option>3</option>
</optgroup>
<optgroup label="Group2">
<option>1</option>
<option>2</option>
<option>3</option>
</optgroup>
<option>out of optgroup</option>
<option>The super very long option.
Donec varius laoreet purus in mollis. Ut ut nisi in metus elementum sollicitudin vel eu eros.
Aliquam varius velit libero, a ornare ligula posuere a.
Ut posuere sapien vel nisi porta, eu facilisis ex egestas.
Curabitur pharetra nisi vel condimentum tempor.
Donec vestibulum blandit risus, ac porttitor mi tempor nec. Quisque ac nunc risus.
</option>
</select>
</div>
</div>
<div class="form-group">
<label class="control-label" for="input-textarea2">Textarea</label>
<div class="control-wrapper">
<textarea id="input-textarea2"></textarea>
</div>
</div>
<div class="form-group">
<label class="control-label"></label>
<div class="control-wrapper">
<button class="rd-button primary" type="button">Save</button>
<button class="rd-button" type="button">Cancel</button>
</div>
</div>
</form>
<h4>Source</h4>
<pre class="preview-source" data-target-src=".code-sample-form-horizontal" data-target-src-remove-first-space="20" data-remove-classes="rd-block-level-margin-bottom"></pre>
<hr>
<h3>Sizes</h3>
<form class="rd-form">
<div class="form-group">
<label class="control-label">Input</label>
<div class="control-wrapper code-sample-form-inputsizes">
<input type="text" placeholder="normal">
<input class="input-small" type="text" placeholder="small">
<input class="input-large" type="text" placeholder="large">
</div>
</div>
<h4>Source</h4>
<pre class="preview-source" data-target-src=".code-sample-form-inputsizes" data-target-src-remove-first-space="32" data-remove-classes="control-wrapper" data-inner-html="true"></pre>
<div class="form-group">
<label class="control-label">Select box</label>
<div class="control-wrapper code-sample-form-selectsizes">
<select>
<option>normal</option>
</select>
<select class="input-small">
<option>small</option>
</select>
<select class="input-large">
<option>large</option>
</select>
</div>
</div>
<h4>Source</h4>
<pre class="preview-source" data-target-src=".code-sample-form-selectsizes" data-target-src-remove-first-space="32" data-remove-classes="control-wrapper" data-inner-html="true"></pre>
</form>
<form class="rd-form horizontal">
<div class="form-group">
<label class="control-label">Input</label>
<div class="control-wrapper">
<input type="text" placeholder="normal">
<div class="form-description">The help message about this form input.</div>
</div>
</div>
<div class="form-group">
<label class="control-label small">Input small</label>
<div class="control-wrapper">
<input class="input-small" type="text" placeholder="small">
<div class="form-description">The help message about this form input.</div>
</div>
</div>
<div class="form-group">
<label class="control-label large">Input large</label>
<div class="control-wrapper">
<input class="input-large" type="text" placeholder="large">
<div class="form-description">The help message about this form input.</div>
</div>
</div>
</form>
<hr>
<h3>Input group</h3>
<p>The input group must be use with form class <code>rd-form</code> and elements with classes <code>form-group</code> <code>control-wrapper</code></p>
<form class="rd-form">
<div class="form-group">
<div class="control-wrapper code-sample-form-inputgroup">
<div class="rd-input-group rd-content-level-margin-bottom">
<input class="rd-input-control" type="number">
<div class="rd-input-group-block append">
<span class="rd-input-group-block-text">฿</span>
</div>
</div>
<div class="rd-input-group rd-content-level-margin-bottom">
<div class="rd-input-group-block prepend">
<span class="rd-input-group-block-text">Price</span>
</div>
<div class="rd-input-group-block prepend">
<span class="rd-input-group-block-text">$</span>
</div>
<input class="rd-input-control" type="number">
<div class="rd-input-group-block append">
<span class="rd-input-group-block-text">.00</span>
</div>
<div class="rd-input-group-block append">
<span class="rd-input-group-block-text">each</span>
</div>
</div>
<div class="rd-input-group rd-content-level-margin-bottom">
<textarea class="rd-input-control"></textarea>
<div class="rd-input-group-block append">
<span class="rd-input-group-block-text">Textarea</span>
</div>
</div>
<div class="rd-input-group rd-content-level-margin-bottom">
<div class="rd-input-group-block prepend">
<span class="rd-input-group-block-text">@</span>
</div>
<input class="rd-input-control rd-input-invalid" type="text" placeholder="invalid">
</div>
</div>
</div>
<h4>Source</h4>
<pre class="preview-source" data-target-src=".code-sample-form-inputgroup" data-target-src-remove-first-space="32" data-remove-classes="control-wrapper" data-inner-html="true"></pre>
<h4>Sizes</h4>
<div class="form-group">
<div class="control-wrapper code-sample-form-inputgroup-sizes">
<div class="rd-input-group rd-content-level-margin-bottom">
<div class="rd-input-group-block prepend">
<span class="rd-input-group-block-text">normal</span>
</div>
<input class="rd-input-control" type="number">
</div>
<div class="rd-input-group rd-input-group-sm rd-content-level-margin-bottom">
<div class="rd-input-group-block prepend">
<span class="rd-input-group-block-text">small</span>
</div>
<input class="rd-input-control" type="number">
</div>
<div class="rd-input-group rd-input-group-lg rd-content-level-margin-bottom">
<div class="rd-input-group-block prepend">
<span class="rd-input-group-block-text">large</span>
</div>
<input class="rd-input-control" type="number">
</div>
</div>
</div>
<h5>Source</h5>
<pre class="preview-source" data-target-src=".code-sample-form-inputgroup-sizes" data-target-src-remove-first-space="32" data-remove-classes="control-wrapper" data-inner-html="true"></pre>
<h4>With button</h4>
<div class="form-group">
<div class="control-wrapper code-sample-form-inputgroup-sizes-withbtn">
<div class="rd-input-group rd-content-level-margin-bottom">
<input class="rd-input-control" type="number">
<div class="rd-input-group-block append">
<button class="rd-button" type="button">Button</button>
</div>
</div>
<div class="rd-input-group rd-content-level-margin-bottom">
<input class="rd-input-control" type="number">
<div class="rd-input-group-block append">
<div class="rd-button-group">
<button class="rd-button dropdown-toggler" type="button" data-placement="bottom right">Dropdown <i class="fa-solid fa-caret-down"></i></button>
<ul class="rd-dropdown">
<li><a href="#" onclick="return false;">Save</a></li>
<li><a href="#" onclick="return false;">Save & Publish</a></li>
<li><a href="#" onclick="return false;">Cancel</a></li>
</ul>
</div>
</div>
</div>
</div>
</div>
<h5>Source</h5>
<pre class="preview-source" data-target-src=".code-sample-form-inputgroup-sizes-withbtn" data-target-src-remove-first-space="32" data-remove-classes="control-wrapper" data-inner-html="true"></pre>
</form>
</div><!--.rd-page-content-->
</main>
<footer>
<div class="rd-page-footer-left"><a href="http://rundiz.com" target="_blank">Rundiz</a> template for admin</div>
<div class="rd-page-footer-right">My app version n.n.</div>
</footer>
</div><!--.rd-page-wrapper-->
<script src="//code.jquery.com/jquery-3.4.1.min.js"></script>
<script src="assets/js/smartmenus/jquery.smartmenus.min.js?npm-v=1.1.1"></script>
<script src="assets/js/popper.js/umd/popper.min.js?npm-v=2.11.2"></script>
<script src="assets/js/sticky-sidebar/jquery.sticky-sidebar.min.js?npm-v=3.3.1"></script>
<script src="assets/js/resize-sensor/ResizeSensor.js?v=8652505c23e8fdc8016445c5e13bee64"></script><!-- use with sticky sidebar js, manual update. -->
<script src="assets/js/rdta/rundiz-template-admin.js?v=da4ea17f9a3341bc37d653a0fa05aaed"></script>
<script class="exclude-preview" src="assets/js-preview/view-target-source.js?v=5d8e14607272d449d23384736d9e83c0"></script>
<script class="exclude-preview" src="assets/js-preview/view-source.js?v=8921f78eb4b62617fff7cd24b9329802"></script>
<script>
function rdtaGetFormData(thisObj) {
let thisForm = thisObj.closest('form');
let formData = new FormData(thisForm);
console.log('Showing form values -------------------------');
for (var value of formData.values()) {
if (value) {
console.log(value);
}
}
}// rdtaGetFormData
function rdtaAddCustomInputFile(targetId) {
let customInputFile = '<span class="rd-button info small rd-inputfile" tabindex="0">\
<span class="label">Choose file</span>\
<input id="rd-inputfile_single" type="file" name="rd-inputfile-dynamic" tabindex="-1">\
</span>\
<span class="rd-input-files-queue"></span>\
<template class="rd-inputfile-reset-button">\
<button class="rd-button tiny" type="button" onclick="return RundizTemplateAdmin.resetInputFile(this);" title="Remove files">\
<i class="fa-solid fa-xmark"></i>\
<span class="screen-reader-only">Remove files</span>\
</button>\
</template>';
document.getElementById(targetId).innerHTML = customInputFile;
}// rdtaAddCustomInputFile
function rdtaCustomInputFileEvents() {
let eventsPlaceholder = document.querySelector('#demo-custom-inputfile-events-placeholder');
const handlerChange = function(event) {
eventsPlaceholder.insertAdjacentHTML('beforeend', 'input changed (see details in console log).<br>');
console.log(event);
};
const handlerFilesQueue = function(event) {
eventsPlaceholder.insertAdjacentHTML('beforeend', 'added files queue (see details in console log).<br>');
console.log(event);
};
document.addEventListener('rdta.custominputfile.change', handlerChange);
document.addEventListener('rdta.custominputfile.addedfilesqueue', handlerFilesQueue);
}// rdtaCustomInputFileEvents
document.addEventListener('DOMContentLoaded', function() {
rdtaCustomInputFileEvents();
});
</script>
</body>
</html>