You can use HTML blocks to quickly access and edit complex HTML code in your content blocks and articles. HTML blocks let you work with blocks of code that would otherwise not be editable within the editor, and display them in a safe manner within your help center.
About HTML blocks
With HTML blocks, you can copy and paste unsupported code for HTML elements into the source code editor. The code is then wrapped in an HTML block and displayed within the article or content block. You can click the HTML block to open a source code editor that displays only the code for that block. You can use this focused view to manipulate the HTML for your selected content without scrolling through the source code for the entire content block or article.
When you update the content block or article, HTML elements associated with the HTML block appear in all published articles or content blocks that contain the HTML block. You can use HTML blocks for any block of unsupported HTML code, including complex HTML scripts or elements such as tables of contents, accordions, tabs, or steppers.
Creating HTML blocks
- In help center or Knowledge admin, create or edit a content block.
- In the content block editor, click HTML on the toolbar.
- In the source code editor, create or edit the unsupported source code you want to use.
- Click Apply to save the code and return to the content block editor. The
unsupported code appears as an HTML block within the editor. You can click the HTML
block to display additional options, or you can click and drag the block around the
editor to move the element to a new location.
- In the help center or Knowledge admin, create or edit an article.
- Click the Article components button (
) on the article editor toolbar, then select HTML block.
- In the HTML block editor, create or edit the unsupported source code you want to use.
- Click Insert to save the code and return to the article editor.
The unsupported code appears as an HTML block within the editor.
You can click the HTML block to display additional options or you can click and drag the block around the editor to move the element to a new location.
Editing HTML blocks
HTML blocks let you easily locate and work with the source code for that block. Instead of scrolling through the source code, you can access and edit the source code for the HTML block directly from the content block or article editor.
- Open the article or content block that contains the HTML block you want to edit in Edit mode.
- Click the HTML block you want to edit to display the option icons, then select the
edit icon (
).
The HTML block editor opens in edit mode.
- Make any necessary changes in the HTML block editor.
- Click Apply.
Your updates are saved and visible in all articles and content blocks that contain the HTML block. You do not need to republish the articles for the changes in content blocks to appear.
Unlinking HTML blocks
You can unlink HTML blocks to inline the HTML block and remove any unsupported markup from the content. You can preview the code that will be removed prior to unlinking it.
- Open the article or content block that contains the HTML block you want to edit in Edit mode.
- Click the HTML block you want to delete to expose the option icons, then select the
unlink icon (
).
-
Review the code that will be unlinked to make sure you understand what will be removed. To continue, click Unlink.
The HTML block is unlinked and unsupported code is removed.
- Click Update (for content blocks) or Save (for articles).
The HTML block is unlinked in all content blocks and articles.
Deleting HTML blocks
Deleting HTML blocks removes the block, including the text and code within that block, from the article. When you delete an HTML block, the block is immediately removed, without confirmation, and can't be undone.
- Open the article or content block that contains the HTML block you want to edit in Edit mode.
- Click the HTML block you want to delete to expose the option icons, then select the
delete icon (
).
The HTML block is removed, without confirmation.
- Click Update (for content blocks) or Save (for articles).
The HTML block is deleted in all articles in which the content block appears.
10 comments
C.W. Holeman III
This is Really Quite Unacceptable!
I was super excited for this update, until I started using it. The forced HTML code blocks are utterly atrocious. Every single one of my agents has complained about it! It's terrible!
As numerous others have already stated above:
Most of my people don't know HTML! Forcing my agents to learn a new language is just not going to happen. Every single one of them is back to the legacy editor.
I have already seen a sharp decline in the quantity and quality of articles that are being produced since this editor update was released. I can already see the wasted hours.
Whoever was in charge of this design decision needs to take a good long look at how they're making choices. This is a case of one step forward, three steps backward! The ability to add an <hr> is the best part of this update. And that's a pretty sad statement.
We often have to pull content from other sources, such as an old knowledge base that we're migrating into Zendesk, or other files from a wide assortment of places. If anything that we copy and paste into the editor has any kind of styles or unsupported anything in it it now renders the entire page utterly uneditable! The only workaround is to do a paste-as-unformatted which completely strips out all the important formatting like headers, lists, and italics. At which point my agents have to completely rebuild every line of pasted content one by one.
In summary: FIX THIS FAST! You are costing us money!
0
Brooke
+1 to everyone else's negative feedback. I go into the HTML to create admonition / callout boxes, and up until the new editor, I've always been able to quickly modify the copy inside the admonition box by editing it in the WYSIWYG editor.
With this new update, I now have to go into the HTML view every single time I need to see what the original text inside the box is, and to make edits. This is very frustrating and time consuming every time I need to edit the article. Not to mention, if I need to format the text inside the box, I now have to write this out as HTML rather than using the options available in the WYSIWYG editor / keyboard shortcuts.
This feature is a huge step back in making things more efficient for myself and other writers, and I like to consider myself a Zendesk Guide power user. Please allow all text to be visible like it was with the legacy editor while in the WYSIWYG editor.
1
Rob R
I agree with some of the other complaints. It's ridiculous to force ALL the plain text into one of these blocks simply because one word or element has basic HTML applied to it.
For example, I have a series of 10 steps in an article. In step 1, I have an inline icon image that I applied a class to. Because of that, all 10 steps get automatically jammed into an HTML block. And as a result, we can no longer perform basic texts edits on the steps - we now need to go into the HTML editor to update the text, manually add new steps (<li>), etc. This is absurd and opens the door to wasting MORE time that it's saving.
One of our help centers is internal with a large group of non-savvy contributors. We can't expect them to suddenly all know HTML if someone needs to add some very basic code to a single element in a section.
And on top of that, it doesn't even seem necessary. I found that if I unlink an HTML block, it says it will remove certain code but it doesn't. It does, however, remove the HTML block from the editor while leaving everything else intact. So this seemed like a decent workaround at least - the HTML I entered worked just fine and the content appeared as it normally does in the editor. Until I found that the next time I went into the full HTML editor, made any other unrelated change and clicked Apply, those HTML blocks came right back.
Please don't force this feature on us in its current state. It's going to require us to either remove / go without all the simple HTML we've been using up to this point without issue or keep it and resort to much more manual and labor-intensive editing.
2
Summer Polacek
This is a very frustrating feature. It's putting simple html, such as markup-bullet points, into an HTML block. Then I am forced to do simple text edits within the code editor intead of the front end wysiwyg.
I can't seem to find a way to turn it off, or remove it, or make it STOP inserting in my articles.
I was excited about some other features that were added, but this one was so frustrating that I am going to make sure i use the legacy editor. I cannot stand this.
7
David Wexelblat
This isn't correct with the new editor, is it? It should be applicable (for Articles) for any with Guide, right?
0
Molly Exten
HTML blocks are wreaking havoc on my code blocks. I use an LMS to manage translations for Zendesk articles, and every time I import a translation back to Zendesk now, code blocks that use angle brackets get swallowed up by an HTML block.
Really not a fan of this feature.
2
Katarzyna Karpinska
Hi 4594924564378 ,
Thank you for this question. At the moment the HTML blocks are only available in Content blocks, which are an enterprise feature (we have updated the banner at the top of the article). Later this year they'll be available also on lower plans in the article editor.
0
Mario Guisado
Is this available in the Professional Plan? I don't have the ability to add a content block in Professional but the header to this article shows that this is available in all plans?
How do we use this if we can't create content blocks?
0
Patrick Morgan
I tried to edit the HTML code in a content block (only trying to add two special characters not supported by the WYSIWYG editor). After saving, all the content in the content block was converted into the HTML block and is no longer editable in the WYSIWYG editor. Is this expected behavior? I have no control over what content gets put in the HTML block.
1
David Bjorgen
Thank you for adding this feature. Very helpful.
0
Sign in to leave a comment.