Skip to content

Instantly share code, notes, and snippets.

@objectivehtml
Created July 6, 2012 18:32
Show Gist options
  • Select an option

  • Save objectivehtml/3061874 to your computer and use it in GitHub Desktop.

Select an option

Save objectivehtml/3061874 to your computer and use it in GitHub Desktop.
// Results in this warning, "Creating default object from empty value"
$some_var = 'some_property';
$options = (object) array();
$options->$some_var = TRUE;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment