Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Pedro 3 posts 23 karma points
    20 days ago
    Pedro
    0

    In a rich text editor, I can't add parameters to a button - U14

    Hi. I'm using Umbraco 14 and I've encountered an issue where in a rich text editor, I can't add the following parameters to a simple button: type="button" id="openpreferencescenter".

    I try to add them, click on the 'view HTML' button, but they get lost.

    In the appsettings.json I have the following:

    "ValidElements": "[]",

    Thanks! Pedro.

  • Steffen Hornbæk Nielsen 54 posts 165 karma points
    18 days ago
  • Pedro 3 posts 23 karma points
    18 days ago
    Pedro
    0

    Hi Steffen, thanks for your response.

    I've tried several changes in the appsettings.json, but it's still not working.

    I've tried enabling this, and I still can't add a simple id to a button. Is there something I'm missing?

    "RichTextEditor": {
          "ValidElements": "+a[id|style|rel|data-id|data-udi|rev|charset|hreflang|dir|lang|tabindex|accesskey|type|name|href|target|title|class|onfocus|onblur|onclick|ondblclick|onmousedown|onmouseup|onmouseover|onmousemove|onmouseout|onkeypress|onkeydown|onkeyup],-strong/-b[class|style],-em/-i[class|style],-strike[class|style],-u[class|style],#p[id|style|dir|class|align],-ol[class|reversed|start|style|type],-ul[class|style],-li[class|style],br[class],img[id|dir|lang|longdesc|usemap|style|class|src|onmouseover|onmouseout|border|alt=|title|hspace|vspace|width|height|align|umbracoorgwidth|umbracoorgheight|onresize|onresizestart|onresizeend|rel|data-id],-sub[style|class],-sup[style|class],-blockquote[dir|style|class],-table[border=0|cellspacing|cellpadding|width|height|class|align|summary|style|dir|id|lang|bgcolor|background|bordercolor],-tr[id|lang|dir|class|rowspan|width|height|align|valign|style|bgcolor|background|bordercolor],tbody[id|class],thead[id|class],tfoot[id|class],#td[id|lang|dir|class|colspan|rowspan|width|height|align|valign|style|bgcolor|background|bordercolor|scope],-th[id|lang|dir|class|colspan|rowspan|width|height|align|valign|style|scope],caption[id|lang|dir|class|style],-div[id|dir|class|align|style],-span[class|align|style],-pre[class|align|style],address[class|align|style],-h1[id|dir|class|align|style],-h2[id|dir|class|align|style],-h3[id|dir|class|align|style],-h4[id|dir|class|align|style],-h5[id|dir|class|align|style],-h6[id|style|dir|class|align|style],hr[class|style],small[class|style],dd[id|class|title|style|dir|lang],dl[id|class|title|style|dir|lang],dt[id|class|title|style|dir|lang],object[class|id|width|height|codebase|*],param[name|value|_value|class],embed[type|width|height|src|class|*],map[name|class],area[shape|coords|href|alt|target|class],bdo[class],button[class|id|type],iframe[*],figure,figcaption,video[*],audio[*],picture[*],source[*],canvas[*],script[*]",
          "CustomConfig": {
            "entity_encoding": "raw",
            "force_br_newlines" : false,
            "force_p_newlines" : false,
            "forced_root_block": ""
          }
      },
    
Please Sign in or register to post replies

Write your reply to:

Draft