Early Bird Registration for DrupalCon Portland 2024 is open! Register by 23:59 UTC on 18 March 2024, to get $100 off your ticket.
The goal of these videos is to prepare those who are newer to programming with the tools they need to eventually code in Drupal.
Introduction and getting a simple development environment set up
- Welcome to PHP Programming Basics - About the full video collection
- What programming is and tips for following along
- Overview of the AMP stack (Apache, MySQL, and PHP)
- How to install Acquia Dev Desktop on a Mac
- How to install Acquia Dev Desktop on Windows
- How to import a default Drupal site on Dev Desktop
Working with basic scripts and coding concepts
- Setting up our example folder and creating our first web page
- Creating our first PHP script and the structure of a simple PHP statement
- What an IDE is and the benefits of using one
- How to identify and fix common syntax errors
- How to work with simple arrays and use var_dump()
- How to work with multi-dimensional arrays
- How to use an "if" control structure
- How to use a "foreach" loop
- Why separating data from logic is important
- How and why to create a simple custom function
- How to wrap existing code in a function
- Accidentally assigning a variable instead of comparing it
- Troubleshooting a missing closing bracket
- How to use array operators
Working with forms, sessions and file structure
- How to process a simple form with PHP
- How to use a switch statement and the $_POST variable
- How to use file comparison tools to see differences between files
- How use to sessions and the $_SESSION variable to store user information
- How to log out a user and pass variables through the URL
- Entering a command in our text adventure game, and using the eval() function
- The pros and cons of using .inc files, and a review of our new file structure
Working with SQL and Create, Read, Update and Delete (CRUD) functionality
- What SQL is and how to write a simple SELECT query
- How to connect to a MySQL database with PHP
- How to run a MySQL database query in PHP
- What an SQL injection attack is and how to create one
- What CRUD is (Create, Read, Update, Delete) and how to backup a database in PHPMyAdmin
- Why to validate forms, and a demo of validating numbers, usernames and empty inputs
- How to validate alphanumeric inputs and unique usernames
- Ways that our CRUD script could be refactored and improved
- How to create a header template file
- When to use unique identifiers (IDs) and what a universally unique ID is (UUID)
- How a .htaccess file works and how to set one up
- How to use the heredoc syntax to avoid escaping multiple quotes
- Why it's better to use a function for settings instead of direct variables
- Using a URL function to route all requests to the right location regardless of subfolder
- Why generalizing CRUD functionality makes so much sense
Comments
Broken links
All the examples link to broken pages.
Videos moved to YouTube
I believe the videos have been moved to a YouTube playlist here.
I've linked the first video from each section below:
I wasn't sure if it was appropriate to edit this in, but that might be helpful to do.