Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
Advanced Search
  • 0

Creating a colored box around text, other blocks and/or multiple blocks?



I'm looking to to add a colored square around blocks of text to act as a border for those sections. Is there any custom CSS/MarkDown script that could achieve this? If possible, it would be great to have this happen around multiple blocks as well (for pairing a description with a video, etc).


Edited by marshallf
Initial Revision
Link to post
  • Answers 2
  • Created
  • Last Reply

Top Posters For This Question

Top Posters For This Question

Posted Images

2 answers to this question

Recommended Posts

  • 1

The easiest way to do that would be to add a Code Block, which you can then style in the CSS Editor.

Try adding something like this to a Code Block, replacing


with your own class name:

<div class = "class-name">
This is the text inside the code block.

alt text

Then, you can style it in the CSS Editor by going to Design > Custom CSS and entering something like this:

.class-name {
   text-align: center;
   font-family: arial;
   font-size: 20px;
   padding: 20px;
   border: 3px solid red;

You can replace the values in this as appropriate, but this would give you something along the lines of:

alt text

To set up multiple Code Blocks this way, just give each one the same class name.

In terms of the CSS, these links are also good for reference:

Hope this helps!



Edited by Guest
Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

  • Create New...