function flag_flag::get_title in Flag 5
Same name and namespace in other branches
- 6.2 flag.inc \flag_flag::get_title()
- 6 flag.inc \flag_flag::get_title()
- 7.3 includes/flag/flag_flag.inc \flag_flag::get_title()
- 7.2 flag.inc \flag_flag::get_title()
A convenience method for getting the flag title.
`$flag->get_title()` is shorthand for `$flag->get_label('title')`.
1 call to flag_flag::get_title()
- flag_flag::form_input in ./
flag.inc - Update the flag with settings entered in a form.
File
- ./
flag.inc, line 560 - Implements various flags. Uses object oriented style inspired by that of Views 2.
Class
- flag_flag
- This abstract class represents a flag, or, in Views 2 terminology, "a handler".
Code
function get_title($content_id = NULL, $reset = FALSE) {
static $titles = array();
if ($reset) {
$titles = array();
}
$slot = intval($content_id);
// Convert NULL to 0.
if (!isset($titles[$this->fid][$slot])) {
$titles[$this->fid][$slot] = $this
->get_label('title', $content_id);
}
return $titles[$this->fid][$slot];
}