How to Retrieve MySQL Last Insert ID in CodeIgniter 4

I use CodeIgniter 4 a great deal for learning, personal projects, and application development. In this post, I cover 2 different methods you can use and retrieve the MySQL Last Insert ID value after executing an INSERT statement in CodeIgniter. Continue reading for more information…

(more…)

Medium Cross-post: CodeIgniter 4 CRUD – Create

I’m studying and beginning to use CodeIgniter 4 in ‘real-world‘ projects and want to share what I learn, as I pick up on concepts of the framework. I’m posting a series of CRUD-related posts over on Medium and resharing them here for any readers who are interested…

(more…)

MySQL Aggregate Query using CodeIgniter’s Query Builder

CodeIgniter’s Query Builder ORM has class methods for nearly any kind of database access/operation you can think of. In this post, I’ll cover some of the available methods for retrieving aggregate-level query results. The examples in this post map out Query Builder method chaining to produce results you would get from a raw MySQL query. Continue reading to see more…

(more…)

CodeIgniter Form Helper library – at a glance

Working with forms is common for anyone in the web development field. Forms are used to capture information for one purpose or another. Be it user login credentials, or customer order details, forms are at the heart of interaction in websites and applications across the Internet. The CodeIgniter PHP framework comes with several built-in helper libraries, that assist in rapid web development. One of them is the form helper. In this post, I’ll cover some of the common methods available from the form helper library…

[Keep reading for more SQL database and PHP/Python-centric content >>>]

PHP strtoupper() and strtolower() string functions

Manipulating text or string data is such a common task that most all programming languages provide built-in functions for this specific purpose. PHP is no different in that regard. The language comes chock-full of different string manipulating functions. If you need string data in all capitalized or upper-cased letters, you can use strtoupper(). What about all lower-case strings? The strtolower() function takes of that. In this post, we visit some rudimentary examples and gain a feel for how these 2 functions operate.

[Keep reading for more SQL database and PHP/Python-centric content >>>]