Forum Discussion

FICO's avatar
FICO
Community Manager
14 years ago

Rule Template, Display Format, HTML Table

Rule Template, Display Format, HTML Table

When using <table>...</table> tags within the Display Format of a Rule Template (possibly other templates too) there is a large amount of space (20+ lines) at the top of the displayed page, both in the Builder instance view and the deployed RMA. 

When I remove the <table> tags and use other types of formatting, the lines disappear, but I want to use HTML table formatting for this view.  I tried embedding the <table> between <div> and <span> tags, but nothing seems to eliminate the spacing.

Why does the line spacing occur when using <table> tags within the Display Format for Rule Templates and is there a workaround for this?

Thanks,

Alan

5 Replies

  • FICO's avatar
    FICO
    Community Manager

    put your html all on one line. then when you work with it you have to put the returns back in there but this should fix your problem.

  • FICO's avatar
    FICO
    Community Manager

    Thank you Spar, your suggestion fixed the problem.  

    I am wondering if this would ever be addressed as a bug fix?  While compressing the HTML into one line solves the problem, it does make it inconvenient for maintaining complex displays.  Anyway, thanks!

  • FICO's avatar
    FICO
    Community Manager

    Hi,

    The problem is that any newline characters typed into the display box are converted to <BR> by the editor.  The solution that an HTML guy showed me is to redefine the formatting of the <BR> tag.  Unfortunately, I am drawing a blank as to what the actual CSS syntax of the command is but it is something along the lines of :

    <style  type="text/css">BR {display:none;} </style>  

    This will turn all of the automatically generated <br> tags into "no op" instructions.  The problem is that it means that you cannot use the <br> tags in your formatting at all, so you will need to use something else (like using all css styles to do your formatting.  Please note that technically this belongs inside the <head> tag but many browsers (including IE) will honor it anyway.

    Tom Sheckells

    Business Rules Consulting, Inc.

  • FICO's avatar
    FICO
    Community Manager

    Tas, thank you for your additional information.  Yes, I seem to remember running across this problem in my early HTML authoring days with something unrelated.  I would think that by 2012 we would have figured out how to embed formatted HTML without this issue, but I digress. 

    I am using <br> tags extensively in my formatting, so I probably won't do the style override, but thanks for the refresher and perhaps I will pursue it later.  I could change my formatting to use paragraphs (<p>) or use CSS like you stated, but for now I will probably just put everything on one line and be done with it.

    Thanks again for your input,

    Alan

  • FICO's avatar
    FICO
    Community Manager

    You can try adding the comments like below:

    <table><!--

    --></table>