<?php $this->load->view('patch');?>
    <section class="content-header">
                    <h1>
                 Affiliate Signup           </h1>
</section>


                <div class="register-box" style="border-top-color:#acb5b1">

    <div class="register-box-body">
        <form id="adv_form" action="/offer/affiliate" method="post" data-toggle="validator" role="form">
       <div class="row">
            <div class="col-sm-6 col-md-6 col-lg-3">
                <div class="form-group has-feedback">
                                        <label class="control-label" for="afn">First Name</label>
                                        <input type="text" id="afn" class="form-control" name="afn" maxlength="50" required >

                                        <p class="help-block help-block-error"></p>
                                </div>
                                </div>
            <div class="col-sm-6 col-md-6 col-lg-3">
                <div class="form-group has-feedback">
                                        <label class="control-label" for="aln">Last Name</label>
                                        <input type="text" id="aln" class="form-control" name="aln" maxlength="50" required>

                                        <p class="help-block help-block-error"></p>
                                </div>
                        </div>
            <div class="col-sm-6 col-md-6 col-lg-3">
                                <div class="form-group has-feedback required">
                                        <label class="control-label" for="aemail">Email <i class="fa fa-question-circle" data-toggle="tooltip" data-html="true" title="Advertiser’s email address, which will also be used to received system notifications."></i></label>
                                        <input type="text" id="aemail" class="form-control" name="aemail" maxlength="50" required>

                                        <p class="help-block help-block-error"></p>
                                </div>
                        </div>

            <div class="col-sm-6 col-md-6 col-lg-3">
                <div class="form-group has-feedback">
                                        <label class="control-label" for="amobile">Mobile No.</label>
                                        <input type="text" id="amobile" class="form-control" name="amobile" required>

                                        <p class="help-block help-block-error"></p>
                                </div>
                        </div>
        </div>

        <div class="row">
            <div class="col-sm-6 col-md-6 col-lg-3">
                <div class="form-group has-feedback">
                                        <label class="control-label" for="aim">IM</label>
                                        <select id="aim" class="form-control select2-hidden-accessible" name="aim" required>
                                        <option value="">IM</option>
                                        <option value="0">Other</option>
                                        <option value="1">Skype</option>
                                        <option value="2">GTalk</option>
                                        <option value="3">QQ</option>
                                        <option value="4">Yahoo</option>
                                        <option value="5">Facebook</option>
                                        <option value="6">WeChat</option>
                                        <option value="7">Twitter</option>
                                        </select>

                                        <p class="help-block help-block-error"></p>
                                </div>
                        </div>
            <div class="col-sm-6 col-md-6 col-lg-3">
                <div class="form-group has-feedback">
                                        <label class="control-label" for="aimid">IM Account</label>
                                        <input type="text" id="aimid" class="form-control" name="aimid" maxlength="50" required>

                                        <p class="help-block help-block-error"></p>
                                </div>
                        </div>
            <div class="col-sm-6 col-md-6 col-lg-3">
                <div class="form-group has-feedback">
                                        <label class="control-label" for="acountry">Country</label>
                                        <select id="acountry" class="form-control select2-hidden-accessible" name="acountry" required>
                                        <option value="">Country</option>
                                        <?php
                                        foreach($country_arr as $cvalue)
                                        {
                                                echo "<option value='$cvalue'>$cvalue</option>";
                                        }
                                        ?>
                                        </select>

                                        <p class="help-block help-block-error"></p>
                                </div>

                        </div>
                        <?php if($this->session->userdata('ROLE')==1){ ?>


            <div class="col-sm-6 col-md-6 col-lg-3">
                                <div class="form-group field-advertiser-manager_id required">
                                        <label class="control-label" for="amanager">Manager <i class="fa fa-question-circle" data-toggle="tooltip" data-html="true" title="Advertiser Manager who manages this advertiser account."></i></label>
                                        <select id="amanager" class="form-control select2-hidden-accessible" name="amanager" required>
                                        <option value="">Manager</option>
                                        <?php foreach($manager as $value){
                                                echo "<option value='$value'>$value</option>";
                                        }?>
                                        </select>

                                        <p class="help-block help-block-error"></p>
                                </div>
                        </div>
                </div>
                        <?php }?>
        <div class="row">
            <div class="col-sm-6 col-md-6 col-lg-6">
                                <div class="form-group has-feedback required">
                                <label class="control-label" for="acompany">Company</label>
                                <input type="text" id="acompany" class="form-control" name="acompany" maxlength="500" required>


                                </div>
                        </div>
            <div class="col-sm-6 col-md-6 col-lg-6">
                                <div class="form-group has-feedback">
                                <label class="control-label" for="awebsite">Website</label>
                                <input type="text" id="awebsite" class="form-control" name="awebsite" maxlength="255" value=""   required>

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

        <div class="row">
                         <?php if($this->session->userdata('ROLE')==1){ ?>
            <div class="col-sm-6 col-md-6 col-lg-2">
                <div class="form-group field-advertiser-status required">
                                        <label class="control-label" for="astatus">Status</label>
                                        <select id="astatus" class="form-control select2-hidden-accessible" name="astatus"  tabindex="-1" aria-hidden="true" required>
                                        <option value="">Status</option>
                                        <option value="1">Active</option>
                                        </select>

                                        <p class="help-block help-block-error"></p>
                                </div>
                        </div><?php } ?>
            <div class="col-sm-6 col-md-6 col-lg-4">
                <div class="form-group has-feedback required ">
                                        <label class="control-label" for="apassword">Password</label>
                                        <div class="kv-password"><table class="kv-strength-container"><tbody><tr>
                                        <td><div class="input-group">
                                        <input type="password" id="apassword" class="form-control" name="apassword" maxlength="60" value="" required>

                                        </div></td>
                                        </tr></tbody></table><input type="hidden" value="50"></div>

                                        <p class="help-block help-block-error"></p>
                                </div>
                        </div>

        </div>





        <div class="row">
            <div class="col-sm-2">
                <div class="form-group">

                                        <button type="submit" class="btn btn-info btn-block" style="background-color:#007AFF">Submit</button>
                                        </div>
            </div>
        </div>

        </form>
    </div>
</div>

