Skip to content

Instantly share code, notes, and snippets.

@grant
Last active January 15, 2020 03:29
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 grant/431874891e7183317084fcd1bea5c6ce to your computer and use it in GitHub Desktop.
Save grant/431874891e7183317084fcd1bea5c6ce to your computer and use it in GitHub Desktop.
PHP HTTP Function
<?php
use Symfony\Component\HttpFoundation\Request;
function helloHttp(Request $request)
{
return sprintf("Hello %s from PHP HTTP function!" . PHP_EOL,
$request->query->get('name') ?: 'World'
);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment