Publishing Source Code to WordPress Using Windows Live Writer 2011

The SQL Guy

My previous blog post “Publishing Code Snippets on My WordPress Blog” explained how I used a read-only textarea to publish source code. Alas, WordPress has started stripping out <textarea> tags when you publish to their site or edit existing posts. They explain that this is for security reasons at http://en.support.wordpress.com/code/.

The above WordPress article also references another article at http://en.support.wordpress.com/code/posting-source-code/ which explains that they have a “sourcecode” “short code” available which can help with publishing source code blocks or code snippets. Unfortunately, that article is muddled in how it presents how to insert the short codes, and also it does not offer any help for Windows Live Writer 2011 users.

After experimenting a bit, I have discovered how to easily use the short codes from within Live Writer, in combination with the <PRE> tag, and what to expect when using it in this editor.

The basic way to include…

View original post 246 more words

Published by

G3n1k

just to remember what i had known :)

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s