Skip to content

Instantly share code, notes, and snippets.

@Repox
Created March 12, 2014 11:05
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 Repox/9504795 to your computer and use it in GitHub Desktop.
Save Repox/9504795 to your computer and use it in GitHub Desktop.
<?php
function issetOr(&$first, $alternative = NULL)
{
$output = '';
if (isset($first)) {
$output = $first;
} else {
$output = $alternative;
}
return $output;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment