<link rel="stylesheet" href="<?php echo base_url();?>assets/css/cust_paginition.css" type="text/css" />
<div class="layout-app">
    <div class="container"><div class="row row-app">
            <div class="col-md-12">
                <div class="col-separator col-separator-first col-unscrollable bg-none">
                    <div class="col-table">
                        <div class="row" >
                            <div class="col-md-9" style="margin-left: 15%">
                                <div class="widget">
                                    <div class="widget-head">
                                        <h4 class="heading">Subscription Details</h4>
                                        <form name="sub_month" action="" method="get">
                                       <select name="month" id="month" class="pull-right cust_select" style="margin-top: 5px" onchange="this.form.submit()">
                                            <option value="">--All--</option>
                                            <?php foreach($arrMonthArray as $monthValue => $monthName) {?>
                                                <option value="<?php echo $monthValue; ?>"
                                                    <?php if ($intMonth == $monthValue) {?>selected="selected" <?php } ?>
                                                    ><?php echo $monthName; ?></option>
                                            <?php } ?>
                                        </select>
                                        </form>
                                        <label class="pull-right"> For Month: &nbsp;</label>
                                    </div>
                                    <div class="widget-body innerAll inner-2x">
                                        <table class="table table-white table-vertical-center margin-none table-striped footable">
                                            <thead>
                                            <tr>
                                                <th  data-class="highlight" class="text-center">Magazine Code</th>
                                                <th  class="text-center">Magazine Name</th>
                                                <th class="text-center">Number of copies</th>
                                            </tr>
                                            </thead>
                                            <tbody>
                                            <?php
                                            if (count($magazine_subscribers) > 0) {

                                            foreach($magazine_subscribers as $magazineSubscribers) {?>
                                            <tr>
                                                <td class="text-center" ><?php echo $magazineSubscribers['magazine_code']; ?></td>
                                                <td class="text-center" ><?php echo $magazineSubscribers['name']; ?></td>
                                                <td class="text-center" ><?php echo $magazineSubscribers['total']; ?></td>
                                            </tr>
                                            <?php } } else {?>
                                            <tr>
                                                <td class="text-center" colspan="3">Sorry, no subscription for this month</td>
                                            </tr>
                                            <?php } ?>
                                            </tbody>
                                        </table>
                                        <div class="col-separator-h clearfix"></div>
                                    </div>
                                    <!-- // END TRENDS -->
                                </div>

                                <div class="col-separator-h"></div>
                                
                            </div>
                        </div>
                        <div class="col-separator-h"></div>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
<script src="<?php echo base_url(); ?>assets/library/jquery/jquery.min.js"></script>

