PHP Code Snippets

PHP Code Snippets
John Morris

Send PHP Email Using PHPMailer

PHPMailer is a popular open source, email-sending library used by applications like WordPress, Drupal, SugarCRM, Joomla and others. This tutorial will show you how to install PHPMailer, set up SMTP and send email in PHP using PHPMailer.

Read More »
PHP Code Snippets
John Morris

PHP Add To and Remove Elements From an Array

In this tutorial, I’ll show you eight different ways to add to, remove from and insert elements to/from an array in PHP. PHP array functions used include: array(), array_push(), array_unshift(), array_pop(), array_shift(), array_slice(), count(), array_diff() and array_splice().

Read More »
PHP Code Snippets
John Morris

What object-oriented programming is NOT

Object-oriented programming is MORE (much more) than knowing how to write a class. It’s about how you build your applications. I call it an “approach”… but it’s an approach *to application-building*.

Read More »