Skip to main content

Notifications

Customer experience | Sales, Customer Insights,...
Suggested answer

Default style setting för h1 28px

Posted on by 10

Hi and thanks for excellent info. I am developing an email template and struggling with CSS. In my style-section I have the following for h1: h1 { font-size: 45px; font-family: Georgia; font-weight: normal; } But when I add some new content and choose h1 from the Dynamics UI it gets font-size 28px as inline CSS. H2 gets size 22px in the same manner etc. Where does this style-setting come from and how do I get rid of it without having to edit html manually every time? Weight and font works fine from the CSS-code. Regards, Per

  • PerHj Profile Picture
    PerHj 10 on at
    RE: Default style setting för h1 28px

    ElineB, tested now again in two different installations (prod and test) but no mysteriuos inline style setting anymore. Both p, h1 and h2 works fine and gets their style only from CSS in html top style section.

    I browsed through the monthly news including bug fixes, updated today actually, but nothing there about this what I can see: docs.microsoft.com/.../whats-new-marketing

  • ElineB Profile Picture
    ElineB 272 on at
    RE: Default style setting för h1 28px

    Hi PerHj, I still have this issue also. It is still solved at your site?

  • PerHj Profile Picture
    PerHj 10 on at
    RE: Default style setting för h1 28px

    Hi again. Now this strange behaviour suddenly stopped. When I now use the toolbar Heading 1 it only sets the h1 tag without font-aize: 28px and so my CSS-seetings in the top style section works as they should. Did you change anything? Rgds, Per

  • PerHj Profile Picture
    PerHj 10 on at
    RE: Default style setting för h1 28px

    Yes, my idea is to create an email template to make it possible for users without html-knowledge to create marketing emails using the non-html designer including heading settings and all other easy to use tools.

    1. My style section looks like above.

    2. I add a text element to my email from the normal (non html) designer

    3. I add some text

    4. I select the added element and choose Heading 1 from the toolbar - that results in the code above.

    I understand that it adds the h1-tag, but back to my question: Why does it add the style=font-size 28px and where does that come from? It doesn't add another font or another weight. I want all my h1 settings from the top style section to be valid, but here comes size 28px from somewhere and I don't want that, I want to decide what size my h1 headings should have in the same manner as font and weight in this example.

    How can I make the toolbar Heading 1 only add the h1 tag and not add the style=font-size 28px? Same goes for h2 but with 22px. Etc.

    Kindly, Per

  • Suggested answer
    Nya Profile Picture
    Nya 29,056 on at
    RE: Default style setting för h1 28px

    Hi Per,

    Do you set the format of the heading via the options in the toolbar?

    pastedimage1636076236616v1.png

    The formatting contained in this option is not affected by changes made in the HTML.

    You have to change the format in HTML designer.

  • PerHj Profile Picture
    PerHj 10 on at
    RE: Default style setting för h1 28px

    Thanks, but I think you have to read my question again. I am changing HTML in the top style section in my template and I have set both size, font and weight for the h1. Font and weight works fine, but size is still overridden by 28px that mysteriously gets added as inline css.

    This is what my settings in the top style part looks like:

    msedge_5F00_OjqOm6RFoH.png

    And the content further down looks like this:

    msedge_5F00_rq7TgkiTHF.png

    The question is: Why does my h1-content get 28px when I set 45px in the style section above? The other settings for font and weight doesn't behave like that?

    Regards, Per

  • Suggested answer
    Nya Profile Picture
    Nya 29,056 on at
    RE: Default style setting för h1 28px

    Hi Per,

    Unfortunately, you have to edit the HTML.

    The <h1> to <h6> tags are used to define HTML headings.

    <h1> defines the most important heading. <h6> defines the least important heading.

    Ref: HTML h1 to h6 tag (w3schools.com)

    And They all have the default properties if you do not re-defined them.

    In Marketing Email, the HTML designer only contains h1-h4 by default.

    pastedimage1636017770363v1.png

    You can change one of the HTML for the email and save it as a template so that it will save you some repetitive edit operations.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Community AMA December 12th

Join us as we continue to demystify the Dynamics 365 Contact Center

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,240 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,149 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans