Google Sheets to PHP Array

This PHP function accepts a public Google Sheets URL and converts it into a PHP array. You can use the array to either display the... August 2021

PHP cURL Requests with JSON or XML

The following post will explain how to use PHP/cURL to retrieve data in JSON or XML and process it for using in your PHP application... March 2021

Global Payments: Strong Customer Authentication (SCA) and 3D Secure 2

The roll out of 3D Secure 2 has been a long drawn-out process not helped by the COVID–19 pandemic. Part of the update has included... February 2021

The latest update to PHP7 is here… 7.2.0

This month PHP released the latest update PHP7.2.0. While PHP 7.2 is an improvement, it is not groundbreaking as the jump from PHP5.6 to PHP7.0.... March 2018

PHP: glob

glob($string); Return an array of pathnames matching a specific pattern. // Find all CSV files in the /home/var/imports/ directory glob("/home/var/imports/hello-*.csv"); /home/var/imports/hello-world.csv – Returned /home/var/imports/hell-world.csv –... June 2017

PHP: header

header($string); Used to send a raw HTTP header, often used for page redirects. Must be called before any other output is sent. // Redirect the... May 2017

PHP: str_replace

str_replace($search,$replace,$subject) All instances of $search are replaced with $replace in $subject. // Will print to screen: "Why is the sky blue?". echo str_replace("red","blue","Why is the... May 2017

How to use PHP to submit a cURL request with HTTP Post data

Straight forward script to POST an array of fields to a given URL. // First, set the URL you want to POST the data to... October 2016

Block access based on Client IP using PHP

Block access based on Client IP The opposite requires a simple exclamation mark before in_array() to change the script so that only those listed in... June 2015