protected function context_reaction_block::json_decode in Context 6.3
Same name and namespace in other branches
- 6 plugins/context_reaction_block.inc \context_reaction_block::json_decode()
- 7.3 plugins/context_reaction_block.inc \context_reaction_block::json_decode()
Compatibility wrapper around json_decode().
2 calls to context_reaction_block::json_decode()
- context_reaction_block::editor_form_submit in plugins/
context_reaction_block.inc - Submit handler context editor form.
- context_reaction_block::options_form_submit in plugins/
context_reaction_block.inc - Options form submit handler.
File
- plugins/
context_reaction_block.inc, line 499
Class
- context_reaction_block
- Expose blocks as context reactions.
Code
protected function json_decode($json, $assoc = FALSE) {
// Requires PHP 5.2.
if (function_exists('json_decode')) {
return json_decode($json, $assoc);
}
else {
watchdog('context', 'Please upgrade your PHP version to one that supports json_decode.');
}
}