Got something specific you'd like to learn? Click here to suggest a tutorial!

Learn PHP
Archive | php RSS feed for this section

PHP Functions Video Tutorial: array_diff_assoc

In this video, you’ll learn about the array_diff_assoc PHP function. This function calculates the difference between an original (“primary”) array and any number of comparison arrays. It returns an array containing an values from the original array that do NOT exist in any of the comparison arrays. The big difference between this PHP function and [...]

Read full story · Comments { 1 }

PHP Functions Video Tutorial: array_count_values

In this video, you’ll learn about the array_count_values PHP function. This function lets you count how many times a certain value occurs in an array. It returns an array where the values of the original array are now the keys and the occurrence of each key in the original array are the values. Here’s how [...]

Read full story · Comments { 0 }

PHP Functions Video Tutorial: array_combine

In this video, we’ll cover the array_combine PHP function. This function lets you specify an array of keys and an array of values and combine the two into a single array. The resulting array contains the values specified in the keys arrays as keys and the values specified in the values array as values. Here’s [...]

Read full story · Comments { 0 }

PHP Functions Video Tutorial: array_chunk

In this video, you’ll learn how to use the array_chunk PHP function. This handy function lets you break an array into smaller chunks of a size you specify. The resulting array is a multi-dimensional array containing your chunked arrays. Here’s how to use it: You can also read more about this function in the PHP [...]

Read full story · Comments { 0 }

PHP Functions Video Tutorial: array_change_key_case

In this video, you’ll learn about the array_change_key case PHP function. This function lets you change the case off all the keys in an array to either upper or lower case. Here’s what it is and how to use it: You can also learn more about this function in the PHP Manual.

Read full story · Comments { 0 }

Top 5 PHP Tutorials You Probably Don’t Know About

Being a fully self-taught PHP developer, I’ve spent a LOT of time searching for and perusing online tutorials. Some are awesome. Others… not so much. So, I figured I’d take a moment to help you separate the wheat from the chaffe. Here’s my top 5 PHP tutorials in no particular order: 1. Tizag.com PHP Tutorial [...]

Read full story · Comments { 0 }

How to Loop Results Into an Array in PHP

This is one of those little tricks in PHP that can save you a ton of time. Reality is, when you’re dealing with MySQL results… you’ll almost always have to loop through an array of results to grab what you want and put THOSE results back into an array. If you don’t know how to [...]

Read full story · Comments { 0 }
Install a LAMP Web Server on Ubuntu

Install a LAMP Web Server on Ubuntu

Installing a web server using the Ubuntu operating system is not too difficult because most of the required packages don’t need a lot of configurations. In this tutorial we create a (power) user, we install Apache, PHP and MySQL, phpMyAdmin and several other services needed to run a powerful and secure web server. via web-development-blog.com [...]

Read full story · Comments { 0 }
Creating an HTML Select Box From a MySQL Results Array Using PHP

Creating an HTML Select Box From a MySQL Results Array Using PHP

This is a question I get quite a bit, so I figured I’d write a post on it: How do I create an HTML select box with options from data in my database? Here’s how: The Query First, let’s look at our query. Yours might look something like this: <?php $sql = "SELECT * FROM [...]

Read full story · Comments { 9 }
How to Write Your Own Easy-Administration WordPress Plugin

How to Write Your Own Easy-Administration WordPress Plugin

WordPress’s popularity owes much to it’s easy administration panels. Unfortunately, it can still be daunting for non-technical users such as your clients. At best they’ll require a little training, hand-holding and support. At worst, they’ll play around with plugin installation, edit some theme code, then expect you to clear up the mess. I’ve written a [...]

Read full story · Comments { 0 }
Sorting Multi-Dimensional Arrays in PHP

Sorting Multi-Dimensional Arrays in PHP

Every time I need to sort a multi-dimensional array in PHP, I have to look it up. It’s not quite as quick and easy to look up as most things, so I’m going to blog a quick example. via shiflett.org This is super handy! I’m the same way. I always used to end up looking [...]

Read full story · Comments { 0 }
Dealing with shortcode madness

Dealing with shortcode madness

At some point in the past year, a disturbing movement has been growing in the WordPress theme development community. If you’ve ever looked at a few themes from Theme Forest, you might have noticed this horrible trend. This isn’t just a Theme Forest issue though; it’s a problem that’s growing in the theme development community [...]

Read full story · Comments { 1 }
PHP Tutorial – Arrays

PHP Tutorial – Arrays

If this is your first time seeing an array, then you may not quite understand the concept of an array. Imagine that you own a business and you want to store the names of all your employees in a PHP variable. How would you go about this? It wouldn’t make much sense to have to [...]

Read full story · Comments { 0 }

How to USE the Data You Collect With Your Forms

In this lesson, you’ll learn the basics of displaying data stored in a database… allowing you to actually use the data you collect with your forms… because that’s the point, right?

Read full story · Comments { 11 }