Skip to content

3. Create a blog post

Mark Downie edited this page Apr 19, 2021 · 19 revisions

After configuring DasBlog Core you can start creating, editing and publishing blog posts!

Create a post

Dasblog Core supports a basic in browser blogging experience by logging in and navigating to post creation page (...post/create).

Dasblog Core supports:

  • Adding new categories
  • Future post dates
  • Uploading and inserting images
  • Disallowing comments

You can choose between several Web post edit controls (TinyMCE, NiceEdit, Froala and a Html Text Area control) defined in the Site Admin page (.../admin/settings).

Using Open Live Writer

Of course you can also use a blogging tool like Open Live Writer to create and edit blog posts.

alt text alt text

The credentials required when adding a blog are the same ones used when logging into the site. Account setup instructions can be found here.

Publishing Code Snippets

If you are publishing multi line code snippets (xml, html, c#, etc.) or some other text that needs a strict syntax and/or specific formatting we strongly suggest using the <pre> tag .

The content of the <pre> tag will need to be HTML-escaped for each of the following characters & < >.

&   &amp;
<   &amp;lt;
>   &amp;gt;

XML code snippet

In this first example I want my blog to display the HTML code snippet exactly as shown here but it contains multiple instances of < >:

<div>
   <h1>Details</h1>
</div>

This is the literal HTML source code I would need to make that happen:

<pre>
&amp;lt;div&amp;gt;
   &amp;lt;h1&amp;gt;Details&amp;lt;h1&amp;gt;
&amp;lt;/div&amp;gt;
</pre>

C# code snippet

I have C# sample code that has the following characters & < >:

List<string> val = null;
if(val != null && val.Count() > 0)
{
    Console.WriteLine("Problem detected");
}

I will need to encode as follows for it to display correctly:

<pre>
List&amp;lt;string&amp;gt; val = null;
if(val != null &amp;&amp; val.Count() &amp;gt; 0)
{
    Console.WriteLine("Problem detected");
}
</pre>

Finally, if you also want code coloring or numbering I would suggest a code highlighter. My preferred code highlighter is EnlighterJS, an open source syntax highlighter written in pure JavaScript.

Additional questions?

If you have additional questions or concerns please submit an issue.