Discussions

Expand all | Collapse all

Add leading or trailing space in rich text field

  • 1.  Add leading or trailing space in rich text field

    Posted 19 days ago
    Is it possible to add a leading or trailing space in a rich text field? For example:

    "<div style=\"background-color:#9d2cd1;Font-Size:14px;text-align:center;Color:Black\"><b>Text Here</b></div>" &
    "<div style=\"background-color:#9d2cd1;Font-Size:14px;text-align:center;Color:Black\"><b>Longer Text Here</b></div>"

    This shows both words, each on its own line centered with different background colors (I am making a color key). But the longer text stretches the width of the field. What I would like is something like:

    "<div style=\"background-color:#9d2cd1;Font-Size:14px;text-align:center;Color:Black\"><b>Text Here</b></div>" &
    "<div style=\"background-color:#6ca672;Font-Size:14px;text-align:center;Color:Black\"><b>   Longer Text Here   </b></div>"

    Notice the spaces in front of and at the end of 'longer text here'. Those spaces do not work. Is there a syntax to have leading and trailing spaces?

    ------------------------------
    Mike Tamoush
    ------------------------------


  • 2.  RE: Add leading or trailing space in rich text field

    Posted 19 days ago
    &nbsp;

    That is the code for a non break space in Rich Text

    So if you want 10 of them, put these inside the quotes

    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;

    ------------------------------
    Mark Shnier (YQC)
    Quick Base Solution Provider
    Your Quick Base Coach
    http://QuickBaseCoach.com
    mark.shnier@gmail.com
    ------------------------------



  • 3.  RE: Add leading or trailing space in rich text field

    Posted 19 days ago
    You can also change the style css and set the width of the resulting shape like this:

    "<div style='width:100px;background-color:#9d2cd1;Font-Size:14px;text-align:center;Color:Black'><b>Text Here</b></div>"​


    This will resolve your leading/trailing spaces issue and give you the additional benefit of keeping all of your images the same width.



    ------------------------------
    Blake Harrison
    bharrison@datablender.io
    DataBlender - Quick Base Solution Provider
    Atlanta GA
    404.800.1702 / http://datablender.io/
    ------------------------------