Created
September 16, 2014 14:06
-
-
Save drmmr763/3c3b6b8f0e6bdb9ebadd to your computer and use it in GitHub Desktop.
JRegistry Code-Around
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
public function getItem() | |
{ | |
$eventRegistry = new JRegistry(); | |
$eventRegistry->loadString($this->getEventBriteIds()); | |
$validEvent = true; | |
$eventRegistryIterator = 0; | |
// this will be a loop | |
while($validEvent) | |
{ | |
// check that key exists | |
if (!$eventRegistry[$eventRegistryIterator]) | |
{ | |
$validEvent = false; // break the loop otherwise | |
break; | |
} | |
// do stuff | |
} | |
return; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment