Recent searches
No recent searches
Inline code formatting in Zendesk communities
Posted Aug 09, 2017
Code blocks are highlighted HTML <pre> blocks in Zendesk community forums posts and comments, but it always comes with a line break.
Would it be possible to support <pre> without a line break (aka inline pre) from Zendesk side? If we copy-paste the inline pre from some other place, it works great, but no way to add it in Zendesk's editor.
Thanks!
13
28
28 comments
Tom
As discussed here: https://support.zendesk.com/hc/en-us/community/posts/222554808-Help-Center-Formatting?page=1#community_comment_115005136628
6
Matt Bailey
+1 Please implement this.
2
Chun Lee
+100, this works in support tickets, why can't it work in the help centre
1
Greg Williams
+100 Absolutely
1
Thomas
Yes, definitely. This is blocking us from migrating to help center
1
Maria McDowell
+1 as this is a major blocker for us using ZD Guide.
0
Nicole Saunders
Hi all -
Are you all looking at this functionality specifically for the Community platform, as indicated in the original post, or more broadly for Knowledge Base articles?
1
Thomas
For KB articles
0
Maria McDowell
Sorry, in KB articles. Is there a separate feedback thread for adding code snippets to KB?
0
Nicole Saunders
Hey Thomas and Maria -
One solution for how to do this is via Github Gists. How to use them is explained in this Community thread:
Putting code into articles
The appropriate Product Feedback thread for you to add your comments and votes to is this one:
Help Center article editor needs to support (easy) source code formatting
0
Maria McDowell
I am aware of this method. However, this it is labor intensive and really only makes sense for large blocks of code. As a technical company, we use code snippets and 'preformatted' text all throughout our docs. Adding a gist for each one of these is simply a poor use of time. We simply need a button for preformatted, and ideally, one for longer code blocks.
0
Tyler Regas
Not to be entirely salty here, but how can so much time pass and even the most basic of documentation formatting functionality remain unactivated in TinyMCE, a web-based editor that is WELL KNOWN to support these features? You've got a number of people here who are asking that a minor change is made to the ZD Guides editor interface (count me among them) to surface functionality that TinyMCE offers already! How can you just ignore that?
Please. I've got a ton of documentation that I need to migrate into ZD and it's gotta be readable and functional, and so far, the less-than-minimal formatting options available just won't cut it. I'm using Gist to get code blocks and there's just NOTHING else!!
The only reason someone doesn't do something that would benefit others is that NOT doing it benefits them.
I truly hope that this isn't true.
0
Nicole Saunders
Hey Tyler -
If you're looking for this functionality for Community posts, it is not planned to be implemented. If you're looking for it for Knowledge Base posts, you should contribute to this thread:
Help Center article editor needs to support (easy) source code formatting
0
Omri
I simply edited the html to add this style to code blocks:
style="background-color: #eee;border: 1px solid #999;display: block;padding: 20px;"
0
Peter Watt
Adding my request to this chain. We are setting up developer documentation and the ability to add code blocks would help immensely.
1
Nicole Saunders
Hi Peter -
Are you looking for code blocks in your Community or in your Knowledge Base?
If you're looking for it in the Community, no further developments are planned for the Communities platform.
If you're looking for it for your Knowledge Base, please contribute to this thread:
Help Center article editor needs to support (easy) source code formatting
1
Adam
Hi Nicole,
We just migrated our Discourse forum into help center community, we are a technical company and have noticed that we and our customers need code blocks within the community GUI.
Do you know if there is anything on the roadmap to make community a more robust platform?
0
Nicole Saunders
Hi Adam -
Yes, there are several things on the roadmap around improving the community. I can't speak to code blocks specifically, but I will check in with the product managers to see if this is something under consideration for the near future.
0
Joakim Eide
Hi Nicole,
Would also like to request Code Blocks / Inline Code Blocks for the text editor in the Knowledge Base. We're also a tech company and not being able to easily add some inline code block using say ```This``` has become a huge hassle for us.
0
Nicole Saunders
Thanks for adding your voice and vote to this request, Joakim!
0
Kasper Sørensen
Hi all,
As of today we have made code blocks available in the community content editor. See the new icon in the toolbar. Here's a code block for ya, which might also help locate the icon :-)
1
Maggie Ungerboeck
That's great news Kasper! Thanks for the update!
0
Matthias Miltenberger
Thanks for the update, Kasper! It seems that the button just moved from within the "T" submenu to the main toolbar, right? While this is nice and all, you seem to have forgotten to add the new top level button to the "edit" form:
Now, there is no way to add the code format to existing posts. Please fix this.
Thanks, Matthias.
0
Matthias Miltenberger
Apparently, this has been fixed in the meantime and the code blocks button also appears in the edit dialog. Thanks!
0
Matthias Miltenberger
Has there been any progress regarding the inline code formatting? It's a shame that this is still not possible with the only (lackluster) workaround being to use LaTeX math mode and specify the "code" in typewriter font to distinguish this from normal text.
\(\texttt{this is not code}\)
edit: oh, it seems you also still don't support LaTeX/MathJax by default...
1
Hiedi Kysther
I'm afraid that we are currently not able to support this functionality However, I do agree that it would be a nice feature to have, and I'm happy to pass your feedback to our Voice of the Customer team for further discussion.
Please feel free to let me know if I can help with anything else!
Cheers,
0
Tannaz Sassooni
Just a plus-one to this request. It's been six years since the original request, and it's an extremely common need for technical documentation to be able to have inline code formatting. As others have mentioned, it's notable that it's available in tickets (via markdown, single backticks), but in Help Center, arguably a more formal communication platform where formatting is even more important, this simple functionality is not supported.
I know we can create a style in our template to support this, but it's *extremely* tedious to have to modify html every time we stick a file or folder name in our documentation, and that comes with the limitation that the formatting wouldn't show up in the WISIWYG editor, only the published article, which is super confusing.
0
Mario
Another vote for this feature.
Right now, I'm copying and pasting the inline code formatting from other articles when I need it, but it's a hassle.
1