3

I'd like to do something like embed Gists in a Tumblr blog; but embedded things like that won't function for users browsing on their dashboards.

I'd like to include the actual raw source-code, for users on the Dashboard; but also have it hilight / Gist-ify / something like that, for visitors to the website.

Has anybody achieved this? What is your approach?

1

Unfortunately, the Tumblr Dashboard is rather selective as far as what types of raw code it parses. Generally, it will only parse basic HTML, such as text-formatting tags and hyperlinks. Anything else is ignored.

However, if visitors actually read the post on your blog rather than their Dashboards, they will find that far more—if not all—code is parsed. As such, if you wish to embed a Gist, you might wish to include a note directing readers to use the post's permalink to view the post on your blog.

As far as highlighting source code, the <pre> HTML tag should serve you well. Again, however, this may not parse on users' Dashboards.

And as a reminder: whenever you are inserting any code into a Tumblr post or page that you want parsed, make sure that the text editor is set to "edit source" or "HMTL" rather than "Rich Text," "Plain Text," or "Markdown."

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.