ElearningWorld.org

For the online learning world

AccessibilityMoodle

Moodle Markdown editing – hidden treasure Part 9

Part 9 of our using Markdown in Moodle series, this time we look at line breaks and horizontal rules.

Previous posts in this series

Line breaks

In some texts, for instance in poetry and verse, it is often necessary to insert line breaks. Trying to do so with the return key will not give the intended effect as by default the lines will be run together to create a paragraph.

Little baby Oh so small 
One day you will be big and tall
I watch you while you laugh and play 
My love for you grows everyday ...

The above input, using the enter key to insert line breaks will give the following output because breaks are ignored:

Little baby Oh so small One day you will be big and tall I watch you while you laugh and play My love for you grows everyday ...

But by ending each line with two spaces you can force line breaks as follows:

Little baby Oh so small 
One day you will be big and tall
I watch you while you laugh and play 
My love for you grows everyday ...

Horizontal rules

Horizontal rules are a standard HTML method of creating a visual divider on the page. It’s not used so much these days, but can still be useful.

Horizontal rules can be created by placing three or more asterisks (*), hyphens (-) or underscores (_) on a line by themselves.

The following will work:

***

However, you can add spaces or further characters to make it more obvious it’s a section break – remember, one aim of Markdown is to make the text and it’s formatting easy to read by humans. All the following will give a horizontal rule.

* * * * *
-------------------------

_ _ _ _ _

Now you can control the layout of your Markdown more easily with line breaks and horizontal rules 🙂

More cool Markdown next post!

Stuart Mealor
Latest posts by Stuart Mealor (see all)

Stuart Mealor

Stuart is interested in all things e-learning, with specific interests in Moodle, e-learning strategy, and business development. His experience in education over 30 years, MBA in International Business, and knowledge of e-learning systems implementation, together with graphic design background, give him a unique skill set for e-learning projects.

Add a reply or comment...