Last active
June 2, 2016 13:50
-
-
Save jonleverrier/30d1130bf9dda129c524d8ebed563616 to your computer and use it in GitHub Desktop.
MODX: List all context keys but exclude the manager
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 | |
$contexts = $modx->getCollection('modContext', array('key:!=' => 'mgr')); | |
foreach($contexts as $context) | |
{ | |
$context_keys[] = $context->get('key'); | |
} | |
return implode(',', $context_keys); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment