Back to [[step_5_-_change_the_main_index_page|previous page]]\\

Next we split the body into one large column and one narrower column for the //weekly ministries//\\
<code html>
        <div class="row">
            <div class="col-sm-8">

            </div>
            <div class="col-sm-4">

            </div>
        </div>
</code>

Put the ''weekly ministries'' table in the narrow column //i.e. second div//\\
<code php>
                <table class="table table-responsive">
                    <thead><tr><td colspan="2" class="ministries">Weekly Ministries</td></tr></thead>
                    <tbody class="text-left">
                    <?php
                        $dname='';
                        
                        foreach ($ministries[0] as $model){
                            if ($model['day']!=$dname) {
                                $dname = $model['day'];
                                echo '<tr class="bg-success"><td width="66%"><strong>'.$dname.'</strong></td><td width="34%"></td></tr>'.PHP_EOL;
                                echo '<tr><td>'.$model['title'];
                                if ($model['content']!=''){
                                    echo '<br />'.$model['content'].'</td>';
                                    } else {
                                    echo '</td>';
                                }
                            }else{
                                echo '<tr><td>'.$model['title'];
                                if ($model['content']!=''){
                                    echo '<br />'.$model['content'].'</td>';
                                    } else {
                                    echo '</td>';
                                }
                            };
                            if ($model['starttime']==NULL) {
                                echo '<td>&nbsp;</td>'.PHP_EOL;
                                } else {
                                echo '<td>'.date('h:i A',strtotime($model['starttime']));
                                if ($model['endtime']!='') {
                                    echo '-'.date('h:i A',strtotime($model['endtime'])).'</td>';
                                    } else { echo '</td>'; }
                                }
                                echo '</tr>'.PHP_EOL;
 
                        }; 
                    ?>
                    </
</code>

Now to fill up the main column.\\
Put in the font page banner
<code html>
 <!-- the normal image was http://wmck.org/media/isaiah40-8.jpg -->
 <p class="text-center"><img alt="Big graphic at center of webpage" class="img-responsive img-thumbnail" src="<?= $dataProvider->models[0]['fpbanner']; ?>" /><br /><br /><br /
</code>
and rest of the church info
<code html>
 <p class="text-center"><strong class="highlight">OUR VISION</strong></p>
 <p class="text-center slogan"><?= $dataProvider->models[0]['vision'] ?></p>
 <p class="text-center"><strong class="highlight"><?= $dataProvider->models[0]['themetitle'] ?></strong></p>
 <p class="text-center slogan"><?= $dataProvider->models[0]['theme'] ?></p>p>
</code>

Followed by the church info
<code html>
<hr />
 <p class="infoheader mark">CHURCH OFFICE CORRESPONDENCE</p>
 <ul class="none">
  <li class='mono'><strong><?= $dataProvider->models[0]['address'] ?></strong></li>
  <li>Email : <strong class='mono'><?= $dataProvider->models[0]['email'] ?></strong></li>
  <li>Office Phone/Fax : <strong class='mono'><?= $dataProvider->models[0]['phone'] ?></strong></li>
  <li>Lay Leader : <strong class='mono'><?= $dataProvider->models[0]['layleader'] ?></strong></li>
  <li>LCEC Chairman : <strong class='mono'><?= $dataProvider->models[0]['lcecchairman'] ?></strong></li>
 </ul>
<hr />
</code>

Next the directions
<code html>
<p class="text-center"><strong class="infoheader mark">Directions to our Church</strong></p>
<p class="text-center"><a href="<?= $dataProvider->models[0]['biggermap'] ?>" target="_blank"><img alt="Church Map" src="<?= $dataProvider->models[0]['churchmap'] ?>"></a></p>
<p class="text-center">Click <a href="<?= $dataProvider->models[0]['biggermap'] ?>" target="_blank">here</a> for <strong>bigger map</strong></p>
<p class="text-center">Click <a href="<?= $dataProvider->models[0]['gmapscreen'] ?>" target="_blank">here</a> for a <strong>Google Map screenshot</strong></p>
<p class="text-center">A <a href="<?= $dataProvider->models[0]['goostreetview'] ?>"><strong>Google Street View</strong></a> of the entrance to the <strong>Kepong Industrial Park</strong></p>
<p class="text-center">GPS Co-ordinates : <strong class='mono'><?= $dataProvider->models[0]['gps'] ?></strong></p>
</code>

Go to the [[step_7_-_change_the_main_index_page_part_3|next step]]

Back to [[yii|Yii Main Index]]