You are here

function _popup_php in Popup 6.x

Same name and namespace in other branches
  1. 8 includes/popup.api.inc \_popup_php()
  2. 7 includes/popup.api.inc \_popup_php()
  3. 7.x includes/popup.api.inc \_popup_php()

File

includes/popup.api.inc, line 441

Code

function _popup_php($attributes, $return = FALSE) {
  $title = $attributes['title'] ? $attributes['title'] : 'PHP';
  if ($return == 'title') {
    return $title;
  }
  $body = eval($attributes['php']);
  if ($return == 'body') {
    return $body;
  }
  return popup_element($title, $body, $attributes);
}