<link rel="stylesheet" href="<?php echo base_url();?>assets/js/validationEngine.jquery.css" type="text/css" />
<link rel="stylesheet" href="<?php echo base_url();?>assets/css/cust_paginition.css" type="text/css" />
<div id="addMagezine">
			<div class="modal-dialog">
				<div class="modal-content"> 
					<!-- Modal heading -->
					<div class="modal-header">
						<!--  <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>-->
						<h4 class="modal-title" align="center">Edit subscription Details for magazine - <?php echo ucwords($arrMagazineDetails['subscriber_name']); ?></h4>
					</div>
					<!-- // Modal heading END -->
					<!-- Modal body -->
					<div class="modal-body">
						<div class="innerAll">
							<div class="innerLR">
								<form class="form-horizontal" role="form" id = "edit_subscribed_magezine" method = "post" action = "" enctype="multipart/form-data">
								<?php $this->load->view('admin/flashdata_admin'); ?> 
									<table class="table table-white table-vertical-center margin-none table-striped footable">
                                        <tr>
                                            <td>
                                                <label  class="col-sm-4 control-label text-center">Select Magazine: </label>
                                                <div class="col-sm-7">
                                                    <input type="text" class="form-control validate[required] text-input" value="<?php echo $arrMagazineDetails['magazine_code'];?>" id="sub_magazine_camps" name = "magazine" readonly/>
                                                </div>
                                                <div style="clear: both"></div>
                                            </td>
                                        </tr>

                                        <tr>
                                            <td>
                                                <label  class="col-sm-4 control-label text-left">Start Issue: </label>
                                                <div class="col-sm-7">
                                                    <!-- <input class="form-control validate[required,custom[integer],min[1]] text-input" type="text" id="issue1s" name="start_issue" value="<?php echo $arrResultSet['start_issue'];?>" /> -->
                                                    <input class="form-control validate[required] text-input" type="text" id="issue1s" name="start_issue" value="<?php echo $arrResultSet['start_issue'];?>" />
                                                </div>
                                            </td>
                                        </tr>
                                        <tr>
                                            <td>
                                                <label  class="col-sm-4 control-label text-left">End Issue: </label>
                                                <div class="col-sm-7">
                                                    <input class="form-control validate[required] text-input" type="text" id="issue2s" name="end_issue" value="<?php echo $arrResultSet['end_issue'];?>" />
                                                </div>
                                            </td>
                                        </tr>
                                        <tr>
                                            <td>
                                                <label  class="col-sm-4 control-label text-left">Start Date: </label>
                                                <div class="col-sm-7">
                                                    <input class="form-control date" data-date-format="M-yyyy" type="text" id="camp_start_dates" name="start_date" value="<?php echo date("M Y",strtotime($arrResultSet['subscribed_on']));?>" readonly required="required"/>
                                                </div>
                                            </td>
                                        </tr>
                                        <tr>
                                            <td>
                                                <label  class="col-sm-4 control-label text-left">End Date: </label>
                                                <div class="col-sm-7">
                                                    <input class="form-control date" data-date-format="M-yyyy" type="text" id="camp_end_dates" name="end_date" value="<?php echo date("M Y",strtotime($arrResultSet['subscription_end_on']));?>" readonly required="required"/>
                                                </div>
                                            </td>
                                        </tr>
                                        <tr>
                                            <td>
                                                <label  class="col-sm-4 control-label text-left">Amount: </label>
                                                <div class="col-sm-7">
                                                    <input class="form-control validate[required,custom[integer],min[1]] text-input" type="text" id="amounts" name="amount" value="<?php echo $arrResultSet['amount'];?>" />
                                                </div>
                                            </td>
                                        </tr>
                                        <tr>
                                            <td>
                                                <label  class="col-sm-4 control-label text-left">Number Of Years subscription: </label>
                                                <div class="col-sm-7">
                                                    <select name="number_of_year" id="camp_number_yearss" class="form-control validate[required]">
                                                        <option value="">---Select Year---</option>
                                                        <?php for($intCounter=1; $intCounter <= 12; $intCounter++) {?>
                                                            <option value="<?php echo $intCounter; ?>"
                                                                <?php if($intCounter == $arrResultSet['period']) { ?>
                                                                    selected="selected"
                                                                <?php } ?>
                                                                ><?php echo $intCounter; ?></option>
                                                        <?php } ?>
                                                    </select>
                                                </div>
                                            </td>
                                        </tr>
                                        <tr>
                                            <td>
                                                <label  class="col-sm-4 control-label text-left">No of Issues: </label>
                                                <div class="col-sm-7">
                                                    <input type="text" value="<?php echo $arrResultSet['no_of_issue'];?>" class="form-control validate[required,custom[integer],max[999], min[1]] text-input" name = "no_issues" id = "no_issues" required="required"/>
                                                </div>
                                            </td>
                                        </tr>
                                    </table>
                                    <div id="promo_issue_error" align="center" style="margin-top: 10px;margin-bottom: 10px"></div>
									<div class="form-group">
										<div class="col-sm-offset-4 col-sm-8">
                                            <input type="hidden" name="subscriber_id" value="<?php echo base64_encode($arrResultSet['subscriber_id']);?>" />
                                            <input type="hidden" name="transaction_id" value="<?php echo base64_encode($intTransactionId);?>" />
											<button type="submit" class="btn btn-primary" id ="btnSubmit">Submit</button>
											<button type="submit" class="btn btn-primary">Cancel</button>
										</div>
									</div>
								</form>
							</div>
						</div>
					</div>
					<!-- // Modal body END --> 
				</div>
			</div>
		</div>
		<script src="<?php echo base_url();?>assets/js/main.js" type="text/javascript"></script>
        <script src="<?php echo base_url();?>assets/js/subscriber.js" type="text/javascript"></script>
        <script src="<?php echo base_url();?>assets/js/custom.js" type="text/javascript"></script>
		<script src="<?php echo base_url();?>assets/js/jquery.validationEngine-en.js" type="text/javascript"></script>
        <script src="<?php echo base_url();?>assets/plugins/forms_elements_bootstrap-datepicker/js/bootstrap-datepicker.js"></script>
		<script src="<?php echo base_url();?>assets/js/jquery.validationEngine.js" type="text/javascript"></script>
		
		
		<script>
		$(document).ready(function() {
			$("#edit_subscribed_magezine").validationEngine();
		});
		</script>
		
