
Explore how CodeIgniter 4 helps you build fast, secure web applications using PHP and MySQL. Learn to create controllers, templates, models, and implement validation, authentication, and deployment.
Identify and install essential system dependencies for CodeIgniter 4, including MySQL, PHP 7, and composer, to support your project on Windows and Linux environments.
Install XAMPP on Windows to get Apache, MySQL, and PHP in one package, then proceed to install Composer to set up a CodeIgniter 4 project.
Install and configure composer on Windows, then create a new CodeIgniter 4 project with composer create-project. Enable the missing extension in PHP and start a development server with spark.
Install MySQL on a Debian-based system, update the package cache, install mysql-server, run mysql_secure_installation to set the root password, and verify the service and version.
Add the ondrej/php ppa, update apt, and install php 7.4 with essential libraries such as mbstring and mysqli. Verify the PHP version to proceed to installing composer.
Install composer, create a new CodeIgniter project with composer create-project, and run a development server with Spark to view localhost:8080.
Master dependency management with composer, initialize a new project using composer create-project with your project name, and review the project structure to begin coding.
Explore CodeIgniter 4 for building PHP and MySQL apps, and learn by creating a store with products and prices, a catalogue page, controllers, models, forms, email helpers, and deployment.
Learn the CodeIgniter 4 application structure, focusing on the app and public folders, the index.php loader, and supporting files like vendor, composer.json, environment variables, and spark.
Discover the app folder structure in CodeIgniter 4, including config, controllers, database migrations and seeds, filters, libraries, language, modals, and views.
Create a hello world in code ignitor by using spark to make an app/controllers controller named karak with a public index function that returns hello, world, then run the server.
Learn to integrate kint, a debugging tool, with a CodeIgniter 4 app to inspect variable types, classes, and methods during development.
Review key takeaways by launching the app at localhost:8080, creating a new controller under app/controllers, and rendering a view with the view function by passing an associative array of variables.
Create a reusable main template for the CodeIgniter 4 web app by adding a simple HTML markup to the views catalog, replacing the hello world output.
Create and extend a main template in CodeIgniter 4 by adding a view file, updating comments, extending the main layout, and defining a content section for multiple groups.
Apply bootstrap styles to the CodeIgniter 4 app by linking Bootstrap CSS and JS via CDN, updating the template views, and verifying that styles load correctly.
Integrate the bootstrap pricing template into your CodeIgniter 4 app by updating views and rendering the catalog content.
Learn how to generate test data with faker in CodeIgniter 4, build product fields (title, description, price), pass data to templates, and prepare models to seed MySQL data for development.
Create a MySQL database named game store, set up a new user at localhost with a password, grant all rights on the database, and verify the connection by logging in.
Configure CodeIgniter 4 environment to connect to a MySQL database using localhost, game store, Kelvinator, and the generated password. Validate the connection by querying databases and preparing models for products.
Seed product database by migrating catalog logic to a seed script, create a populated products class, generate 100 products with faker, insert into the products table, and run the seed.
Create the first CodeIgniter 4 migration for the products table with spark, define an up and down schema using Forge, and run migrations to build the table.
Create a products model in CodeIgniter 4 for a PHP and MySQL app, configuring validation, callbacks, timestamps, and allowed fields, then fetch and render recent products on the pricing page.
Change the controller logic by removing unused top statements, call the products model find all, and add order by and limit to fetch six rules from the database for display.
Configure the database and environment file, set hostname, database, username, password, and driver; create and migrate migrations, seed data, and generate models with php spark commands in CodeIgniter 4.
Explore implementing pagination in CodeIgniter 4 to display a products table, enabling create, read, update, and delete actions through a dedicated products controller and model, with data passed to templates.
Explain frontend pagination by rendering the current page of products and the pager links, organize the view in a products index, and test the list at localhost/products.
Extend the product list with a Bootstrap-styled table. Render each row with title and price using a for-each loop, and keep the pager for pagination.
Finish pagination in CodeIgniter 4 by creating a custom pagination template and configuring vendor/config templates. Apply bootstrap styles in the views and add navigation buttons in the product index.
Add routes for adding, editing, and deleting items in the product controller. Create product views and prepare add and edit logic for the next video.
Route and implement add/edit actions for products, load the form helper into memory for template use, then add and test a link in the products index to access the form.
Create a CodeIgniter 4 form using current URL and method, with title, price, and description fields, styled by Bootstrap, plus a submit button and closing the form.
Learn how to validate form data in CodeIgniter 4, intercept submissions in the products controller, and save valid data to the database or display meaningful errors.
Demonstrate validating form data with CodeIgniter's validation framework, setting rules for title (min length 10), description (min 250), and price (required, decimal), and testing inputs to produce true or false.
Implement validation scenarios in CodeIgniter 4 by saving validated products to the database and redirecting to the products index, while returning with validation errors and displaying them on the form.
Refactor the add method by decoupling validation from the controller. Add a validation rules array in the product model and enable custom error messages for description, price, and other fields.
Implement the edit method in CodeIgniter 4 by loading the edit form, locating the existing entity with find, handling not found errors, and updating the entity with validation.
Implement the delete method in the products controller, reuse logic to find and delete an item, update the products index to replace edit with delete, and redirect.
Implement user authentication in CodeIgniter 4 by creating a user model and controller, adding registration, session logic, and using fotos to verify login status.
Add another migration to create a users table using the forge tool, defining login, password, and created_at fields, with a down function to drop the table, then migrate and verify.
Learn how CodeIgniter 4 uses sessions to persist data between requests, starting a session, storing variables in a global associative array, and clearing or accessing session data with built-in methods.
Define a user model in CodeIgniter 4, after creating the users table with login and password fields, set validation rules, and hash passwords before insert or update.
Create a registration controller and corresponding views in CodeIgniter 4, including a dedicated login template, a simple login form with login and password fields, and test locally.
Check the session to see if the user is logged in and redirect if so; on registration data, load the user model, save it, and redirect to login on success.
Create a login controller and its templates by copying the register templates, set up the login form, and prepare to implement the login logic in the next video.
Implement login logic by verifying the user from the repository, checking the hashed password, redirecting on error, and creating a session to access the products page.
Implement flash messages in a CodeIgniter 4 app by using a shared template, reading errors and messages from the session, and displaying them across templates for a single request cycle.
Implement a logout function in a CodeIgniter 4 PHP app by destroying the user session in a controller and redirecting, then test and preview next steps with controller filters.
Implement authentication using CodeIgniter 4 filters by creating an authentication filter that runs before controllers to block unauthenticated users, redirecting them to login while allowing login and register routes.
Implement a user created event in CodeIgniter 4 to dispatch an account creation notification email using a configured email service and a test SMTP setup.
Trigger the email-dispatching event from the register flow in CodeIgniter 4, firing a user created event with the login as an argument and testing the email with Mantrap.
Configure a CodeIgniter 4 app for deployment, install required packages, and verify the setup by hitting localhost to display the welcome message.
Configure a replicable Debian deployment by pointing the server to the app's public directory, adjusting index and location blocks, enabling fastcgi/cgi, and starting the service on localhost.
Hello! In this course I'd like to introduce you to CodeIgniter 4, a web application framework you can use to build a web application in an easy way.
I'm a PHP developer by trade and I build web applications everyday. I think that CodeIgniter is a good tool that will help programmers in their job, making it easier and speeding it up. CodeIgniter gives access to various tools which make it easy for you to build your web apps and get them published as fast as possible.
In this course I will teach you how to use this framework by creating an example store. I will demonstrate each process step by step, how we can implement each of the functionalities.
Inside the course, you will find easily digestible chapters made to make you proficient with the framework as fast as possbile. First, we will discuss how we can setup the work environment, which we will use to develop our application. Then, we will create a new CodeIgniter project and we will install PHP dependencies within. Finally, we will create our very first "Hello World" using a CodeIgniter controller.
In the following chapters we will discuss the basics - how to use templates, how to connect to our database and then how to model data. We will also create forms and validate data before saving it into our database. Finally, we will discuss how to authenticate our users, how to use events and mailer component.
If you are a web application developer or would like to become one with the help of CodeIgniter and PHP and you need a course that will quickly make you proficient at using this framework, then this course is made for you.
I look forward to work with you to make you a better programmer! See you in the course! Best wishes.