Inserting code blocks into a blog post

Topics: ASP.NET 2.0
May 31, 2010 at 5:03 PM

Hello,

Forgive me if this is a noob question, but I am just in the process of setting up my new blog. I attempted to write a test post about some code I had written. However when you try to insert code into the content of a blog post BlogEngine throws an error in fear of a XSS attack. Is there any way to insert blocks of formatted code into a post, so you can discuss that code in a post?

Thanks,

Michael

Coordinator
Jun 1, 2010 at 12:48 AM
You can try this extension: http://rtur.net/blog/post/2009/11/15/Syntax-Highlighter-extension-for-BlogEngine.aspx Windows Live Writer has several extensions for code insertion you can use with BlogEngine, too. Here is sort of a review on what you can do: http://rtur.net/blog/post/2007/11/14/Insert-Code-your-options.aspx
Jun 1, 2010 at 4:28 AM

Could this syntax highlighter (rtur) become par of the BlogEngine? After updating BlogEngine you always have to fix syntax highlighter. Making in default feature might better, let's say for 2.0 version.

Jun 1, 2010 at 8:00 AM

Great, thank you. I'll try plugging that extension in later this evening. Will post again if I have any further issues.

Excellent bit of software by the way. I managed to set it all up and hook it into my MSSQL database in a matter of minutes.