Sign in

Cannot add “minlength” tag to textarea in HTML mode

  • This topic has 3 replies, 2 voices, and was last updated 2 weeks, 1 day ago by .
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #5867
    Feriman

    Hi,

    I use WYSIWYG editor, and I’d like to add a “minlength” attribute to textarea in HTML mode, but the Publii remove it after I save changes.

    Reproduce the issue:

    1. Open a new post with WYSIWYG editor
    2. Switch to HTML mode
    3. Add this code:
      <form><textarea minlength="5"></textarea> <input type="submit" value="Check"></form>
    4. Press “Apply changes”
    5. Go back to HTML editor
    6. You will see the code without the minlength attribute:
      <form><textarea></textarea> <input type="submit" value="Check"></form>

       

    Is it a bug? How can I add “minlength” attribute to textarea?

     

    Thank you!

    Feriman

    #5875
    Bob

    Try to use the block editor for this post, it should work here.

    --
    Do you appreciate the support you've received today? If so, consider donating to the Publii team by clicking here; we'll be sure to use your donation to make Publii even better!

    #5886
    Feriman

    Thank you, it works in Block editor.

    #5894
    Tomasz Dziuda

    Feriman – since Publii 0.38 you can also go to Site settings -> Advanced options -> Editors and use option “Additional valid elements in the WYSIWYG editor” to allow missin attributes

    --
    Do you appreciate the support you've received today? If so, consider donating to the Publii team by clicking here; we'll be sure to use your donation to make Publii even better!

Viewing 4 posts - 1 through 4 (of 4 total)
  • The topic ‘Cannot add “minlength” tag to textarea in HTML mode’ is closed to new replies.