Category : codeigniter

i`m using codeigniter 4 and try to use a controller from other controller i have 2 controllers in Controllers folder, Home.php dan Shop.php Home.php <?php namespace AppControllers; class Home extends BaseController { public function index() { return view(‘welcome_message’); } function validation() { $shop = new Shop(); echo $shop->product(‘laptop’, ‘brand’); } } and Shop.php <?php namespace ..

Read more

class Data_barang extends CI_Controller{ public function index(){ $data[‘barang’] = $this->model_barang->tampil_data()->result(); $this->load->view(‘templates_admin/Header’); $this->load->view(‘templates_admin/Sidebar’); $this->load->view(‘admin/data_barang, $data’); $this->load->view(‘templates_admin/footer’); } Sourc..

Read more

I am following this document. https://www.codexworld.com/codeigniter-rest-api-user-login-registration/ One I send request from POSTMAN if I remove ‘x-api-key’ & "Basic Auth" then also API is working. in application/config/rest.php I have below settings. $config[‘rest_auth’] = ‘basic’; $config[‘auth_source’] = ”; // I put this blank otherwise it’s saying ldap file is missing. $config[‘allow_auth_and_keys’] = TRUE; $config[‘rest_valid_logins’] = [‘admin’ => ..

Read more

I’m trying to encrypt and decrypt data between client (C#) and server PHP. i don’t understand encryption enough to work out so i need to convert C# to php thanks Any help is appreciated. here is my code: C#: private static readonly string PasswordHash = "[email protected]@Sw0rd"; private static readonly string SaltKey = "[email protected]&KEY"; private static ..

Read more

On my website Login is not working while my Codeigniter site loaded in iframe Chrome Browser and it’s working in firefox browser. I have debugged the issue and get that system authenticated the user successfully but once after redirect to another page the system does not get the user’s data into the session, as it’s ..

Read more