![]() |
where to put the css in a CI3 generated form? - 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: where to put the css in a CI3 generated form? (/showthread.php?tid=79081) |
where to put the css in a CI3 generated form? - richb201 - 04-17-2021 I have a form I am trying to create and instead of using HTML I am creating (and validating) with the built in form helper. Where do I put the css in this case? PHP Code: public function index() PHP Code: <style> RE: where to put the css in a CI3 generated form? - InsiteFX - 04-17-2021 It should go with all your other css files in assets/css RE: where to put the css in a CI3 generated form? - richb201 - 04-17-2021 Instead of using the CI3 generated form, I switched over to include the form in a template. Now I can get the nice form I wanted. Now I am battling with the $_POST and also validation. I'd like to use CI3's form validation rules. Not sure if I can in this "bastardized" form. I have set the submit to go to a method in the controller: <form action="/index.php/Users_start_login/get_email" method="post"> and i do see the $_POST. I'd like to make sure it is a valid form of an email with: $this->form_validation->set_rules('email', 'Email', 'required|valid_email); before I check to see if it is sent to my authentication tool. One idea is to use: if (!filter_var($email, FILTER_VALIDATE_EMAIL)) { $emailErr = "Invalid email format"; } |