How can I show shade - coded Python fragments in my Tumblr blog site

I have a Tumblr-managed blog, on which I upload a great deal of Python - relevant blog posts. Just how do I make the Python fragments in my blog posts show shade - coded?

2019-05-18 22:14:49
Source Share
Answers: 3

You can make use of transforms your code fragments right into attractive - published HTML layout, conveniently embeddable right into post, e-mails and also websites.
Simply replicate the resource code to the left pane, select the language and also the color pattern, and also click "Highlight!". The HTML from the appropriate pane can currently be pasted to your blog site or e-mail, no exterior CSS or Javascript documents are called for.
2019-05-21 07:21:07

If you have way too many, I would certainly claim go with google-code-prettify.

All you need to do is to include some javascript, css and afterwards you are done.

Examine some examples and also below is the arrangement:

  1. Download a circulation
  2. Include the manuscript and also stylesheets in your record (you will certainly require to see to it the css and also js documents get on your web server, and also readjust the courses in the manuscript and also link tag)
    • <link href="prettify.css" type="text/css" rel="stylesheet"/>
    • <script type="text/javascript" src="prettify.js"></script>
  3. Add onload = "prettyPrint ()" to your record is body tag.
  4. Change the stylesheet to get the tinting you favor
2019-05-21 07:15:15

I make use of Github is gist to do this. Paste in and also create the idea and also you can after that install them in any kind of website consisting of tumblr.

2019-05-21 06:57:46