I have become a recent fan of WordPress and GitHub having seen the Gist feature recently on a blog I wanted to put it on this site. I need to embed github gist WordPress so that I can present my code well to users and readers. I use GitHub, and they provide an awesome feature called the Gist.
There are a number of plugins to enable this functionality however I went with the GistHub Gist WordPress Plugin by Jingwen Owen Ou
It is compatible up to WordPress 3.0.5 but no update since late 2010. It is however pretty simple code, so I decided to give it a run and get it updated.
After install I was getting one of two errors:
This was caused by the script looking at http instead of the https Gist now requires.
This one was because I didn’t read the instructions! Ensure you have the filename there too as a Gist can contain multiple code snippets – called files.
So I updated the http to https and pushed the php file back into the /wp-content/plugins/github-gist/ directory and reloaded. The result is what you see on this page.
Here is the result:
So there you go, a simple and quick plugin that will bring your code on to a blog post by embed GitHub Gist WordPress via this simple but effective plugin.
Let us know in the comments where you have used it!
Comments are closed.
1 Comment
Reliable information. Actually useful and not a great deal of filler.
It would be impressive if more webpages had this level of content, then maybe google could loosen
up on their strict guidelines!