Template:Clear: Difference between revisions

    From FeministWiki
    (Created page with "<div style="clear: {{{1|both}}};"></div>")
     
    (Add documentation.)
     
    Line 1: Line 1:
    <div style="clear: {{{1|both}}};"></div>
    <includeonly><div style="clear: {{{1|both}}};"></div></includeonly><noinclude>
    Use this template at the end of an article section to make sure that images or other media don't flow over to the next section.  Blank space will be added to the section to ensure this.
     
    Example:
     
    <pre>
    === Some section ===
     
    [[File:Some_image.jpg|thumb|right|200px|Look at this nice image at the right side of the page.]]
     
    Some text that isn't very long.
     
    {{clear}}
     
    === The next section ===
     
    Blah blah blah.
    </pre>
     
    In this example, there will be some blank space below the text "Some text that isn't very long" to ensure that the header "The next section" appears after the bottom of Some_image.jpg is reached.  If <code><nowiki>{{clear}}</nowiki></code> wasn't used, the header of the next section would appear right after the text of the previous section, and it wouldn't be clear what section the image belongs to.
     
    Note that this isn't always necessary or desired; sometimes it doesn't matter that much whether it's clear which section an image is in, or the image only slightly cuts into the next section which looks less bad than the blank space that would be caused by this template.  Choose freely whether to use it or not depending on what you think looks nicer and clearer for the reader.
     
    </noinclude>

    Latest revision as of 17:35, 6 May 2020

    Use this template at the end of an article section to make sure that images or other media don't flow over to the next section. Blank space will be added to the section to ensure this.

    Example:

    === Some section ===
    
    [[File:Some_image.jpg|thumb|right|200px|Look at this nice image at the right side of the page.]]
    
    Some text that isn't very long.
    
    {{clear}}
    
    === The next section ===
    
    Blah blah blah.
    

    In this example, there will be some blank space below the text "Some text that isn't very long" to ensure that the header "The next section" appears after the bottom of Some_image.jpg is reached. If {{clear}} wasn't used, the header of the next section would appear right after the text of the previous section, and it wouldn't be clear what section the image belongs to.

    Note that this isn't always necessary or desired; sometimes it doesn't matter that much whether it's clear which section an image is in, or the image only slightly cuts into the next section which looks less bad than the blank space that would be caused by this template. Choose freely whether to use it or not depending on what you think looks nicer and clearer for the reader.