How do I create a vB code for horizontal lines?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Brian Cruz
    Senior Member
    • Apr 2001
    • 164
    • 3.8.x

    How do I create a vB code for horizontal lines?

    Is it possible to create a vB code that allows users to insert horizontal lines in their posts? In HTML the code is <hr>, but since it has no closing tag, I'm not sure how to add it in the custom codes area of the control panel.

    Also, is it possible to add size options to the code? Like typing in [hr size=5] to acheive what <hr size="5"> does?
    Brian Cruz
    www.toonzone.net
  • tubedogg
    Senior Member
    • Feb 2001
    • 13602

    #2
    If you want to do an HR without a size, you can do it very easily. Go to Replacement variables > Add and use this info:
    Replacement Set: usually Default but if you use multiple style sets you'll need to set this appropriately.
    Code to Find: [hr]
    Code to Insert: <hr>

    The second one is also possible however you will have to do a tag in the style of
    [tag]size[/tag]
    but it's certainly possible. Just go to Custom BB Codes > Add and use this:
    vB Code Tag: hr
    vB Code Replacement: <hr size="{param}">
    vB Code Example:
    5

    vB Code Explanation: This adds a horizontal rule, with the size as specified by the number in between the tags.

    Comment

    widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
    Working...