Copied to clipboard

Flag this post as spam?

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


  • Nathan Grumbine 7 posts 77 karma points
    Jun 06, 2019 @ 15:38
    Nathan Grumbine
    0

    Rich TExt Tiny MCE dropping my h1 and classes on save

    I'm currently using the Rich Text editor in my grid layout for content.

    When I edit the code and place a <h1>Harrisburg Wedding and Portrait Photographer</h1> tag hit submit and then save my page it converts my h1 to a p. also in the code editor i've added classes for gtm tag triggers, but yet again when i hit save the class attribute is dropped.

    <h2 class="headerprice">Pricing and Information</h2> on save becomes <h2>Pricing and Information</h2>

    here is my mce config....

    <?xml version="1.0" encoding="utf-8"?>
    <tinymceConfig>
        <commands>
            <command alias="ace" name="Source code editor" mode="Insert" />
            <command alias="removeformat" name="Remove format" mode="Selection"/>
            <command alias="undo" name="Undo" mode="Insert" />
            <command alias="redo" name="Redo" mode="Insert" />
            <command alias="cut" name="Cut" mode="Selection"/>
            <command alias="copy" name="Copy" mode="Selection"/>
            <command alias="paste" name="Paste" mode="All" />
            <command alias="styleselect" name="Style select" mode="Insert" />
            <command alias="bold" name="Bold" mode="Selection" />
            <command alias="italic" name="Italic" mode="Selection" />
            <command alias="underline" name="Underline" mode="Selection" />
            <command alias="strikethrough" name="Strikethrough" mode="Selection" />
            <command alias="alignleft" name="Justify left" mode="Selection" />
            <command alias="aligncenter" name="Justify center" mode="Selection" />
            <command alias="alignright" name="Justify right" mode="Selection" />
            <command alias="alignjustify" name="Justify full" mode="Selection" />
            <command alias="bullist" name="Bullet list" mode="All" />
            <command alias="numlist" name="Numbered list" mode="All" />
            <command alias="outdent" name="Decrease indent" mode="All" />
            <command alias="indent" name="Increase indent" mode="All" />
            <command alias="link" name="Insert/edit link" mode="All" />
            <command alias="unlink" name="Remove link" mode="Selection" />
            <command alias="anchor" name="Anchor" mode="Selection" />
            <command alias="umbmediapicker" name="Image" mode="Insert" />
            <command alias="umbmacro" name="Macro" mode="All" />
            <command alias="table" name="Table" mode="Insert" />
            <command alias="umbembeddialog" name="Embed" mode="Insert" />
            <command alias="hr" name="Horizontal rule" mode="Insert" />
            <command alias="subscript" name="Subscript" mode="Selection" />
            <command alias="superscript" name="Superscript" mode="Selection" />
            <command alias="charmap" name="Character map" mode="Insert" />
            <command alias="rtl" name="Right to left" mode="Selection" />
            <command alias="ltr" name="Left to right" mode="Selection" />        
        </commands>
        <plugins>
            <plugin>paste</plugin>
            <plugin>anchor</plugin>
            <plugin>charmap</plugin>
            <plugin>table</plugin>
            <plugin>lists</plugin>
            <plugin>advlist</plugin>
            <plugin>hr</plugin>
            <plugin>autolink</plugin>
            <plugin>directionality</plugin>
            <plugin>tabfocus</plugin>
            <plugin>searchreplace</plugin>
        </plugins>
        <validElements>
            <![CDATA[+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],iframe[*]]]>
        </validElements>
        <invalidElements>font</invalidElements>
    
        <!-- this area is for custom config settings that should be added during TinyMCE initialization -->
        <customConfig>
            <!--    <config key="myKey">mySetting</config>-->
            <config key="entity_encoding">raw</config>        
        </customConfig>
    </tinymceConfig>
    

    Am I just missing something obvoius... I didn't have these issues in v7 I'm realtively new to the v8 umbraco.

Please Sign in or register to post replies

Write your reply to:

Draft