Skip to content

Instantly share code, notes, and snippets.

@stevesohcot
Created November 14, 2021 19:23
Show Gist options
  • Select an option

  • Save stevesohcot/a3a777319b6484c2c7fe24c017049428 to your computer and use it in GitHub Desktop.

Select an option

Save stevesohcot/a3a777319b6484c2c7fe24c017049428 to your computer and use it in GitHub Desktop.
PHP Query
<?php
$params = [];
$params[':first_name'] = $first_name;
$sql = "INSERT INTO Users (first_name) VALUES (:first_name)";
return $db->runSQL($sql, $params); // will return true or display an error
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment