Undefined property: App\Controllers\Signup::$input - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Using CodeIgniter (https://forum.codeigniter.com/forumdisplay.php?fid=5) +--- Forum: General Help (https://forum.codeigniter.com/forumdisplay.php?fid=24) +--- Thread: Undefined property: App\Controllers\Signup::$input (/showthread.php?tid=76869) |
Undefined property: App\Controllers\Signup::$input - newbiecoder - 06-28-2020 Can't pass form data from view to SignUp controller. home.php <?php helper('form'); echo form_open('Signup'); echo form_input('user_email','',['placeholder'=>'Email Address'],'email'); echo form_input('user_password','',['placeholder'=>'Password'],'password'); echo form_submit('mysubmit','SignUp'); ?> Signup.php <?php namespace App\Controllers; use CodeIgniter\Controller; class Signup extends Controller { public function index() { if($this->input->post('mysubmit')!=NULL) { $mailids=$this->input->post('user_email'); echo $mailids; } } } ?> RE: Undefined property: App\Controllers\Signup::$input - jreklund - 06-28-2020 That's CodeIgiter 3 code. You are using CodeIgniter 4 correct? https://codeigniter.com/user_guide/incoming/incomingrequest.html#retrieving-input $this->request->getPost('user_email'); RE: Undefined property: App\Controllers\Signup::$input - newbiecoder - 06-29-2020 (06-28-2020, 07:39 AM)jreklund Wrote: That's CodeIgiter 3 code. You are using CodeIgniter 4 correct? Thanks bro.. |