function _flashnode_php_flashvars in Flash Node 6.3
Same name and namespace in other branches
- 5.6 flashnode.module \_flashnode_php_flashvars()
- 5.2 flashnode.module \_flashnode_php_flashvars()
- 5.3 flashnode.module \_flashnode_php_flashvars()
- 6.2 flashnode.module \_flashnode_php_flashvars()
Check to see if PHP is allowed in this format, and if it is process the flashvars string through the PHP filter in case there is some code to be handled. Then the string for safe handling, but turn & back in to & as that is what flash needs to define the variables in a flashvars string. Return the result.
2 calls to _flashnode_php_flashvars()
- flashnode_content in ./
flashnode.module - Given a flash node nid and option parameters return the HTML string required to generate the required flash content (this is used by the macro system)
- flashnode_view in ./
flashnode.module - Implementation of hook_view
File
- ./
flashnode.module, line 811
Code
function _flashnode_php_flashvars($flashvars, $format = -1) {
// Get the list of filters for this node
$filters = filter_list_format($format);
// Look for module == php to see if we have PHP allowed for this node
foreach ($filters as $filter) {
if ($filter->module == 'php') {
$flashvars = module_invoke($filter->module, 'filter', 'process', $filter->delta, $format, $flashvars);
}
}
// Encode flashvars to make it safe for inclusion on the page
$flashvars = check_plain($flashvars);
// But we need to undo conversion of & to &
$flashvars = str_replace('&', '&', $flashvars);
return $flashvars;
}