[ create a new paste ] login | about

Link: http://codepad.org/IgT3j4If    [ raw code | output | fork ]

PHP, pasted on May 29:
<div class="contentRow">
    <h2>Title</h2>
    <div id="frame">
        <?php
        $i = 0;
        for($j = 0; $j < 12; $j++)
        {
            $i++;
            ?>
            <?php if (($i % 4 == 0) OR ($i == 1)) { ?>
                <div class="jobsContainer">
            <?php } ?>

            <div class="jobContainer">
                               content + table + form
            </div>

            <?php if ($i % 4 == 2) { ?>
                <div class="jobSeperator">&nbsp;</div>
            <?php } ?>

            <?php if ($i % 4 == 0) { ?>
                </div>
            <?php } ?>

            <?php 
        }
        ?>
    </div>

    <div class="clear"></div>
</div>


Output:
<div class="contentRow">
    <h2>Title</h2>
    <div id="frame">
                                    <div class="jobsContainer">
            
            <div class="jobContainer">
                               content + table + form
            </div>

            
            
                        
            <div class="jobContainer">
                               content + table + form
            </div>

                            <div class="jobSeperator">&nbsp;</div>
            
            
                        
            <div class="jobContainer">
                               content + table + form
            </div>

            
            
                                        <div class="jobsContainer">
            
            <div class="jobContainer">
                               content + table + form
            </div>

            
                            </div>
            
                        
            <div class="jobContainer">
                               content + table + form
            </div>

            
            
                        
            <div class="jobContainer">
                               content + table + form
            </div>

                            <div class="jobSeperator">&nbsp;</div>
            
            
                        
            <div class="jobContainer">
                               content + table + form
            </div>

            
            
                                        <div class="jobsContainer">
            
            <div class="jobContainer">
                               content + table + form
            </div>

            
                            </div>
            
                        
            <div class="jobContainer">
                               content + table + form
            </div>

            
            
                        
            <div class="jobContainer">
                               content + table + form
            </div>

                            <div class="jobSeperator">&nbsp;</div>
            
            
                        
            <div class="jobContainer">
                               content + table + form
            </div>

            
            
                                        <div class="jobsContainer">
            
            <div class="jobContainer">
                               content + table + form
            </div>

            
                            </div>
            
                </div>

    <div class="clear"></div>
</div>


Create a new paste based on this one


Comments: