public function cf_dom::get_tag_markup in Common Functionality 7.2
Converts the selected tag into HTML markup.
Parameters
DOMNode $element: The element to convert.
bool $on_body: If TRUE, operate on body element. If FALSE, operate on head element. The supplied tag must be attached to the appropriate head or body. This defaults to TRUE.
Return value
string|bool The markup text that the object was converted from. FALSE on error.
File
- modules/
cf_dom/ classes/ cf_dom.php, line 301 - Provides the cf_dom handling class.
Class
- cf_dom
- The cf_dom class assists in setting up and managing the custom dom object.
Code
public function get_tag_markup($element, $on_body = TRUE) {
if ($on_body) {
if (!$this->body instanceof DOMNode) {
if (class_exists('cf_error')) {
cf_error::invalid_object('this->body');
}
return FALSE;
}
return $this
->p_get_markup(TRUE, $element);
}
if (!$this->head instanceof DOMNode) {
if (class_exists('cf_error')) {
cf_error::invalid_object('this->head');
}
return FALSE;
}
return $this
->p_get_markup(TRUE, $element);
}