Skip to content

Instantly share code, notes, and snippets.

@jonnybarnes
Last active September 11, 2018 20:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jonnybarnes/a82359a9f7a559819f7cddc5230d8705 to your computer and use it in GitHub Desktop.
Save jonnybarnes/a82359a9f7a559819f7cddc5230d8705 to your computer and use it in GitHub Desktop.
Embeds for my PHP 7.3 BuildEmpire blog post
<?php
// some class
// some method
// an if statement
$variable = <<<TOKEN
Hello
World!
TOKEN;
var_dump($variable);
<?php
// some class
// some method
// an if statement
$variable = <<<TOKEN
Hello
World!
TOKEN;
var_dump($variable);
<?php
try {
json_decode('{invalid{json', false, 512, JSON_THROW_ON_ERROR);
} catch (\JSONException $exception) {
Log::error($exception->getMessage());
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment