MyBB Community Forums

Full Version: How to indent text within forum posts?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I've looked around for a solution for this, but I can't seem to figure out how to indent text in forum post in MyBB.

I've tried [indent] and other options but it seems it won't work. Does anyone know of a method for indenting text? Thanks

BTW, did anyone ever figure out how to avoid the page flicker I posted about a few days ago? It happens when clicking on links with forum posts, because MyBB's default is opening a new page for a link. I wanted to avoid that because I have a dark forum skin and clicking download links jolts my eyes and brain every time I click on a link. Confused

Thanks!
Indentation only works within the code/php bbcode. I don't know any editor that supports indentation in posts though. Whenever I have to use indentation, I use my Programmer's Notepad and copy&paste the text in MyBB's editor.
If you've tried &nbsp; and '& # 1 6 0 ;' <-remove spaces and ' ' 
you may be able to get <pre> to work or use a table.
OR <Img> with a transparent image... with the height you are using for your font size and width you want for your indentation. Load the image on site forum so it will nearly guarantee load. Now if someone is Zooming your site or doing something weird.. the transparent image trick may not work.
OR
Cascading Style Sheet it. Read up on CSS via w3schools.com and edit your theme so there's an indentation. I'd say this is the most reliable method.
I made a Mycode to make indented paragraphs.

Regular Expression:
\[p\](.*?)\[/p\]

Replacement:
<p style="text-indent: 20px;">$1</p>

To write an indented paragraph, you would write:

[p]Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam enim eros, viverra ac placerat sed, luctus eget orci. Integer eget justo at lorem porta accumsan. Cras in quam iaculis lectus dignissim rutrum vel eu lectus. Phasellus ligula felis, scelerisque vitae volutpat at, eleifend eget nibh.[/p]

Of course, if you don't want a code that needs to be closed, you can use a MyCode to replace with like 5 &nbsp;
Thanks for all the replies on this, I'm going to have to figure out how to do this Smile

I guess I got spoiled having used XenForo for a while, they have indent as part of the posting tools by default (they've got that rich text editor option that is on by default).
(2012-04-27, 11:27 PM)brad-t Wrote: [ -> ]I made a Mycode to make indented paragraphs.

Regular Expression:
\[p\](.*?)\[/p\]

Replacement:
<p style="text-indent: 20px;">$1</p>

To write an indented paragraph, you would write:

[p]Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam enim eros, viverra ac placerat sed, luctus eget orci. Integer eget justo at lorem porta accumsan. Cras in quam iaculis lectus dignissim rutrum vel eu lectus. Phasellus ligula felis, scelerisque vitae volutpat at, eleifend eget nibh.[/p]

Of course, if you don't want a code that needs to be closed, you can use a MyCode to replace with like 5 &nbsp;

This only indents the first line of my paragraph...
Also nested doesn't seem to work :/
Of course it only indents the first line. That's how paragraph indentation is supposed to be.
(2013-06-26, 09:34 PM)brad-t Wrote: [ -> ]Of course it only indents the first line. That's how paragraph indentation is supposed to be.

While that is true there are times you want to properly indent full paragraphs, what I did was simply use a <div style="left-padding=2em">$1</div> instead of your <p> html... also, in order to get multiple levels of indentation I passed a second value through the regex to the html... not elegant but nesting multiple [indent]s inside eachother doesn't seem to work.