Find this useful? Enter your email to receive occasional updates for securing PHP code.

Signing you up...

Thank you for signing up!

PHP Decode

<?php class Brand extends CI_Controller { function __construct() { parent::__construct()..

Decoded Output download

<?php 
 class Brand extends CI_Controller { function __construct() { parent::__construct(); check_not_login(); $this->load->model(array("items", "brands", "groupaccess", "transaksisales")); $this->load->library("form_validation"); } public function index() { $validation = $this->groupaccess->checkChildName($this->fungsi->user_login()->group_level, "Brand")->row(); $delete_button = $this->groupaccess->checkChildName($this->fungsi->user_login()->group_level, "Hapus Brand")->num_rows(); if ($validation) { $data["judul"] = "Sub Kategori"; $data["row"] = $this->brands->get(); $data["delete_button"] = $delete_button; $this->template->load("template", "product/brand/brand_data", $data); } else { echo "\xa\x9		<script>
\x9\x9\x9	alert('Anda tidak punya akses untuk Modul ini!');\xa\x9		\x9window.location='" . base_url("home") . "';\xa\x9\x9\x9</script>\xa\x9	\x9"; } } public function add() { $validation = $this->groupaccess->checkChildName($this->fungsi->user_login()->group_level, "Tambah Brand")->row(); if ($validation) { $this->form_validation->set_rules("brand_name", "Brand Name", "required|is_unique[brand.brand_name]"); $this->form_validation->set_message("required", "%s masih kosong"); $this->form_validation->set_message("is_unique", "{field} ini sudah ada, silahkan pilih {field} lain."); $this->form_validation->set_error_delimiters("<span class="help-block">", "</span>"); if ($this->form_validation->run() == FALSE) { $data["judul"] = "Add Brand"; $this->template->load("template", "product/brand/brand_add", $data); } else { $post = $this->input->post(null, TRUE); $this->brands->add($post); if ($this->db->affected_rows() > 0) { $this->session->set_flashdata("success", "Brand baru berhasil disimpan."); } redirect("brand"); } } else { echo "
\x9	\x9<script>
\x9\x9		alert('Anda tidak punya akses untuk Modul ini!');
			\x9window.location='" . base_url("brand") . "';\xa\x9\x9\x9</script>
	\x9\x9"; } } public function del() { $validation = $this->groupaccess->checkChildName($this->fungsi->user_login()->group_level, "Tambah Brand")->row(); if ($validation) { $id = $this->input->post("brand_id"); $this->brands->del($id); if ($this->db->affected_rows() > 0) { $this->session->set_flashdata("success", "Brand berhasil dihapus."); } redirect("brand"); } else { echo "\xa\x9\x9\x9<script>\xa				alert('Anda tidak punya akses untuk Modul ini!');\xa		\x9\x9window.location='" . base_url("brand") . "';
\x9\x9	</script>\xa	\x9	"; } } public function edit($id) { $validation = $this->groupaccess->checkChildName($this->fungsi->user_login()->group_level, "Edit Brand")->row(); if ($validation) { $this->form_validation->set_rules("brand_name", "Brand Name", "required"); $this->form_validation->set_message("required", "%s masih kosong"); $this->form_validation->set_error_delimiters("<span class="help-block">", "</span>"); if ($this->form_validation->run() == FALSE) { $query = $this->brands->get($id); if ($query->num_rows() > 0) { $query_brand = $this->brands->get(); $data = array("judul" => "Edit Brand", "brand" => $query_brand, "row" => $query->row()); $this->template->load("template", "product/brand/brand_edit", $data); } else { echo "
                    <script>
                        alert('Data tidak ditemukan.');                        
                        window.location='" . base_url("brand") . "';
                    </script>\xa                    "; } } else { $post = $this->input->post(null, TRUE); $this->brands->edit($post); if ($this->db->affected_rows() > 0) { echo "\xa                    <script>
                        alert('Brand berhasil diupdate.');                        
                    </script>
                    "; } echo "\xa                <script>          \xa                    window.location='" . base_url("brand") . "';\xa                </script>\xa                "; } } else { echo "\xa		\x9<script>\xa				alert('Anda tidak punya akses untuk Modul ini!');
				window.location='" . base_url("brand") . "';
\x9\x9\x9</script>\xa		\x9"; } } } ?>

Did this file decode correctly?

Original Code

<?php
 class Brand extends CI_Controller { function __construct() { parent::__construct(); check_not_login(); $this->load->model(array("\x69\164\x65\155\163", "\142\162\x61\156\x64\x73", "\x67\162\x6f\x75\x70\x61\x63\x63\x65\163\x73", "\x74\x72\141\x6e\163\x61\153\x73\x69\163\141\154\145\x73")); $this->load->library("\146\157\x72\x6d\x5f\166\141\154\x69\x64\x61\164\151\x6f\x6e"); } public function index() { $validation = $this->groupaccess->checkChildName($this->fungsi->user_login()->group_level, "\102\x72\141\x6e\144")->row(); $delete_button = $this->groupaccess->checkChildName($this->fungsi->user_login()->group_level, "\110\141\160\165\163\40\102\162\x61\x6e\144")->num_rows(); if ($validation) { $data["\x6a\165\x64\x75\154"] = "\x53\165\x62\40\x4b\141\164\x65\x67\x6f\162\151"; $data["\x72\157\x77"] = $this->brands->get(); $data["\x64\x65\x6c\x65\x74\x65\137\x62\165\x74\x74\x6f\156"] = $delete_button; $this->template->load("\x74\x65\155\160\154\141\164\145", "\160\162\x6f\144\165\143\164\x2f\142\162\141\156\x64\x2f\x62\162\141\156\144\137\144\x61\164\141", $data); } else { echo "\xa\x9\11\11\74\163\x63\x72\151\160\x74\76\12\x9\x9\x9\11\x61\x6c\x65\x72\x74\x28\x27\x41\156\x64\141\40\164\151\x64\141\153\x20\160\165\x6e\171\x61\40\141\x6b\163\x65\x73\x20\165\x6e\x74\x75\153\40\115\x6f\x64\165\x6c\40\151\156\151\41\47\x29\73\xa\x9\11\11\x9\167\151\x6e\x64\157\x77\56\x6c\x6f\143\x61\x74\x69\157\156\75\x27" . base_url("\150\x6f\x6d\x65") . "\47\73\xa\x9\x9\x9\x3c\57\163\143\x72\151\160\164\x3e\xa\x9\11\x9"; } } public function add() { $validation = $this->groupaccess->checkChildName($this->fungsi->user_login()->group_level, "\124\x61\x6d\x62\x61\x68\x20\x42\162\141\x6e\x64")->row(); if ($validation) { $this->form_validation->set_rules("\x62\x72\x61\156\x64\x5f\x6e\141\155\145", "\102\x72\x61\156\x64\x20\x4e\x61\x6d\145", "\x72\145\x71\x75\x69\162\x65\x64\x7c\151\163\137\x75\156\151\161\x75\x65\133\x62\162\x61\156\144\x2e\x62\162\x61\x6e\x64\x5f\156\x61\x6d\145\x5d"); $this->form_validation->set_message("\x72\145\161\x75\151\162\x65\144", "\x25\x73\40\x6d\x61\x73\x69\150\x20\x6b\157\163\157\156\x67"); $this->form_validation->set_message("\151\x73\137\x75\156\151\x71\x75\145", "\173\x66\x69\x65\x6c\x64\175\x20\x69\x6e\x69\40\163\x75\144\x61\x68\x20\141\144\x61\x2c\x20\x73\151\154\x61\x68\x6b\x61\x6e\x20\160\x69\154\x69\150\x20\x7b\x66\x69\x65\x6c\x64\175\x20\154\x61\x69\x6e\56"); $this->form_validation->set_error_delimiters("\x3c\x73\160\x61\x6e\40\143\154\x61\163\x73\x3d\x22\150\x65\x6c\x70\x2d\x62\154\157\x63\153\x22\76", "\74\x2f\x73\x70\141\x6e\x3e"); if ($this->form_validation->run() == FALSE) { $data["\152\x75\144\165\x6c"] = "\101\x64\144\40\x42\x72\x61\x6e\144"; $this->template->load("\x74\145\155\x70\154\141\164\145", "\160\x72\157\144\x75\143\x74\57\x62\162\141\156\144\x2f\142\x72\141\156\x64\137\141\144\144", $data); } else { $post = $this->input->post(null, TRUE); $this->brands->add($post); if ($this->db->affected_rows() > 0) { $this->session->set_flashdata("\163\165\143\143\x65\x73\163", "\x42\x72\x61\156\144\x20\142\141\x72\165\x20\142\145\x72\x68\141\x73\151\x6c\x20\144\151\163\151\155\160\x61\156\x2e"); } redirect("\x62\162\x61\x6e\144"); } } else { echo "\12\x9\11\x9\74\163\143\x72\151\x70\164\x3e\12\x9\x9\11\11\141\x6c\145\x72\x74\50\47\x41\156\x64\x61\40\164\x69\144\x61\153\40\x70\x75\156\171\x61\x20\x61\153\163\145\163\40\165\156\164\x75\x6b\x20\x4d\x6f\144\x75\154\40\x69\156\x69\x21\47\51\73\12\11\11\11\x9\x77\151\156\144\x6f\167\x2e\x6c\x6f\x63\141\x74\151\157\156\x3d\x27" . base_url("\142\x72\x61\x6e\144") . "\47\x3b\xa\x9\x9\x9\74\57\x73\x63\162\x69\x70\x74\x3e\12\11\x9\x9"; } } public function del() { $validation = $this->groupaccess->checkChildName($this->fungsi->user_login()->group_level, "\x54\x61\155\x62\x61\x68\x20\x42\162\141\x6e\x64")->row(); if ($validation) { $id = $this->input->post("\x62\x72\x61\x6e\x64\137\x69\144"); $this->brands->del($id); if ($this->db->affected_rows() > 0) { $this->session->set_flashdata("\163\x75\x63\x63\145\x73\x73", "\x42\x72\141\x6e\144\x20\x62\145\x72\150\141\163\x69\x6c\x20\144\x69\x68\x61\160\x75\x73\56"); } redirect("\x62\162\x61\x6e\x64"); } else { echo "\xa\x9\x9\x9\x3c\163\143\x72\x69\160\164\x3e\xa\11\11\11\11\x61\154\x65\x72\x74\x28\x27\x41\156\144\141\x20\164\151\144\141\153\x20\x70\x75\x6e\171\141\40\x61\x6b\163\x65\163\x20\x75\x6e\x74\x75\x6b\40\x4d\157\x64\165\x6c\40\x69\x6e\x69\41\47\x29\x3b\xa\11\11\x9\x9\167\x69\156\x64\x6f\x77\x2e\154\157\143\x61\164\x69\x6f\x6e\75\x27" . base_url("\x62\x72\141\x6e\144") . "\x27\73\12\x9\x9\11\74\57\x73\x63\162\x69\x70\x74\76\xa\11\x9\11"; } } public function edit($id) { $validation = $this->groupaccess->checkChildName($this->fungsi->user_login()->group_level, "\x45\144\151\164\x20\102\x72\x61\x6e\x64")->row(); if ($validation) { $this->form_validation->set_rules("\142\162\141\x6e\x64\137\156\x61\x6d\x65", "\102\x72\x61\x6e\144\x20\x4e\141\155\145", "\x72\x65\x71\x75\151\162\145\x64"); $this->form_validation->set_message("\162\145\161\x75\x69\x72\x65\144", "\x25\163\40\155\x61\163\x69\x68\x20\153\157\x73\157\156\x67"); $this->form_validation->set_error_delimiters("\x3c\x73\x70\x61\156\x20\x63\154\x61\163\x73\75\42\x68\x65\154\160\55\x62\x6c\x6f\x63\153\42\x3e", "\74\57\x73\x70\141\156\x3e"); if ($this->form_validation->run() == FALSE) { $query = $this->brands->get($id); if ($query->num_rows() > 0) { $query_brand = $this->brands->get(); $data = array("\x6a\x75\144\x75\x6c" => "\105\144\151\x74\40\x42\x72\141\x6e\x64", "\142\162\x61\x6e\144" => $query_brand, "\x72\x6f\x77" => $query->row()); $this->template->load("\164\x65\155\160\x6c\x61\164\x65", "\x70\162\157\x64\x75\x63\x74\57\142\x72\x61\156\x64\x2f\142\162\141\x6e\144\137\x65\144\x69\x74", $data); } else { echo "\12\x20\40\x20\x20\40\40\x20\x20\40\x20\x20\40\x20\x20\40\x20\40\x20\40\x20\74\x73\143\162\x69\x70\164\x3e\12\40\x20\x20\x20\x20\40\x20\x20\x20\x20\x20\40\x20\x20\x20\x20\40\40\40\40\40\40\x20\x20\x61\x6c\145\x72\x74\x28\47\x44\x61\164\141\40\x74\151\x64\141\153\x20\x64\x69\164\x65\155\x75\x6b\x61\x6e\x2e\47\51\73\40\x20\x20\40\x20\40\x20\x20\x20\40\x20\40\x20\x20\40\x20\40\40\40\x20\x20\x20\x20\x20\12\x20\40\40\x20\x20\x20\40\x20\x20\40\x20\x20\40\40\x20\x20\x20\40\x20\40\40\40\x20\x20\167\x69\156\x64\157\x77\x2e\x6c\x6f\143\x61\164\x69\x6f\x6e\x3d\x27" . base_url("\142\162\x61\x6e\x64") . "\47\73\12\x20\40\x20\40\x20\x20\x20\40\40\x20\x20\40\x20\x20\x20\40\x20\40\x20\x20\x3c\x2f\163\x63\x72\151\x70\164\76\xa\40\x20\40\40\40\x20\40\40\40\40\40\40\40\x20\40\x20\x20\40\x20\40"; } } else { $post = $this->input->post(null, TRUE); $this->brands->edit($post); if ($this->db->affected_rows() > 0) { echo "\xa\x20\x20\40\x20\40\x20\40\40\40\40\x20\40\40\x20\40\40\40\x20\40\x20\x3c\163\x63\162\151\x70\x74\x3e\12\40\40\40\40\40\x20\40\40\40\40\40\40\40\40\40\40\40\x20\40\40\40\x20\40\40\x61\x6c\145\162\x74\50\47\102\162\141\156\144\x20\142\145\162\150\x61\163\151\154\40\x64\x69\165\160\144\141\x74\x65\x2e\47\51\x3b\x20\x20\x20\40\x20\40\x20\40\x20\40\40\40\x20\40\x20\x20\x20\x20\40\40\40\40\x20\40\12\x20\x20\x20\40\x20\40\x20\x20\x20\40\40\x20\x20\40\40\40\x20\40\40\x20\74\x2f\x73\x63\x72\x69\160\x74\76\12\x20\40\x20\40\x20\x20\x20\40\40\x20\40\40\40\x20\x20\40\x20\40\40\40"; } echo "\xa\x20\40\x20\x20\40\40\40\x20\x20\x20\x20\40\x20\x20\40\40\74\x73\143\x72\x69\x70\x74\x3e\x20\40\x20\x20\40\x20\x20\x20\x20\x20\xa\x20\40\x20\x20\40\40\x20\40\x20\40\x20\x20\x20\x20\40\40\40\x20\x20\x20\x77\x69\156\x64\157\x77\56\154\x6f\x63\x61\x74\151\x6f\156\x3d\47" . base_url("\142\x72\141\x6e\x64") . "\x27\73\xa\x20\x20\x20\x20\x20\x20\x20\x20\40\x20\40\40\40\40\40\x20\74\x2f\x73\x63\x72\x69\160\x74\x3e\xa\x20\x20\x20\40\x20\40\x20\40\x20\40\x20\40\x20\40\40\x20"; } } else { echo "\xa\11\11\x9\x3c\163\143\162\151\x70\x74\x3e\xa\11\11\11\11\x61\154\145\x72\164\50\47\x41\156\144\141\40\164\x69\144\141\153\x20\160\x75\156\171\x61\40\x61\x6b\x73\145\163\40\x75\156\x74\165\153\x20\115\157\144\165\154\x20\151\x6e\151\x21\47\x29\73\12\11\11\11\11\167\x69\x6e\x64\x6f\167\56\x6c\157\143\x61\164\x69\x6f\156\75\47" . base_url("\x62\162\141\x6e\144") . "\x27\x3b\12\x9\x9\x9\x3c\57\163\x63\162\151\x70\x74\76\xa\11\11\x9"; } } } ?>

Function Calls

None

Variables

None

Stats

MD5 2c10aa2af2379edeac4f8e7560a4b3a2
Eval Count 0
Decode Time 62 ms