Skip to content

Commit 4ded1d1

Browse files
Daniel SheffieldDaniel Sheffield
authored andcommitted
apply only to textarea
1 parent a5e8664 commit 4ded1d1

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

sqlpage/templates/form.handlebars

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,6 @@
5353
{{~#if minlength}}minlength="{{minlength}}" {{/if~}}
5454
{{~#if maxlength}}maxlength="{{maxlength}}" {{/if~}}
5555
{{~#if required}}required="required" {{/if~}}
56-
{{~#if formenctype}}formenctype="{{formenctype}}" {{/if~}}
5756
{{~#if autofocus}}autofocus {{/if~}}
5857
>
5958
{{~#if value}}{{value}}{{/if~}}
@@ -62,7 +61,6 @@
6261
<select name="{{name}}" class="form-select"
6362
{{~#if id}} id="{{id}}" {{/if~}}
6463
{{~#if required}} required="required" {{/if~}}
65-
{{~#if formenctype}}formenctype="{{formenctype}}" {{/if~}}
6664
{{~#if autofocus}} autofocus {{/if~}}
6765
{{~#if multiple}} multiple {{/if~}}
6866
{{~#if (or dropdown searchable)}}
@@ -123,6 +121,10 @@
123121
{{#if (eq type "file")}}
124122
<!-- Change the form encoding type if this is a file input-->
125123
{{#delay}}formenctype="multipart/form-data"{{/delay}}
124+
{{else}}
125+
{{#if (and formenctype (eq type "textarea"))}}
126+
{{#delay}} formenctype="{{formenctype}}"{{/delay}}
127+
{{/if}}
126128
{{/if}}
127129
{{/each_row}}
128130
</div>

0 commit comments

Comments
 (0)