Create the title

@param Infoset $info
329315
protected function createTitle(Infoset $info) {
		preg_match('/([0-9\.]+)/i', phpversion(), $matches);
		$title = 'PHP ' . $matches[1];
		
		if (extension_loaded('xdebug')) {
			$title .= ' / [alert]xdebug[/alert]';
		}
		
		if (extension_loaded('apc')) {
			$title .= ' / [success]apc[/success]';
		}
		
		if (extension_loaded('Zend OPcache')) {
			$title .= ' / [success]opcache[/success]';
		}
		
		$info->setTitle($title);
	}
265883
public static function create($title = '', $data = null, $type = ButtonType::WEB_URL)
    {
        return new static($title, $data, $type);
    }
528976
private function addTitle($title)
    {
        $this->seoPage->addTitle($title);
        $this->seoPage->addMeta('name', 'title', $title);
    }
567174
protected function setPageTitle($title) {

        $this->pageTitle = $title;

        $args = array('class' => 'title');
        $titleTag = \MUtil_Html::create('h3', $title, $args);

        $this->html->append($titleTag);
    }
414862
def set_title(self, title):
        """"""
        self.head.title.attr(content=title)
        return self
1158334
protected function createTable(Infoset $info) {
		$table = new Table();
		$table->addClass('content-table');
		
		if ($info instanceof InfosetTable) {
			if (($widths = $info->getColsWidths()) !== null) {
				$table->getColgroup()->addElements($widths);
			}
			
			if (($headRow = $info->getHeadContent()) !== null) {
				$table->getHead()->addElement($headRow);
			}
		}
		
		foreach ($info as $row) {
			if (! is_array($row) && ! $row instanceof Traversable) {
				throw new InvalidContent('Table row content must be an array or a Traversable implementation');
			}
			
			$cols = [];
			
			foreach ($row as $content) {
				if ($content instanceof Infoset) {
					$content = $this->createContent($content);
				}
				
				$content = $this->specialCharsHandle($content);
				
				if ($info->isContentBbCodes()) {
					$content = $this->bbCodesHandle($content);
				}
				
				$cols[] = $content;
			}
			
			if ($row instanceof Row && $row->isMarked()) {
				$cols['_class_'] = $row->getMark();
			}
			
			$table[] = $cols;
		}
		
		return $table->render();
	}
45951
protected function writeThemesDocumentation($info)
    {
        $header = '<!DOCTYPE html><html><head><meta charset="utf-8"><title>Overview</title>';
        $header .= '<link rel="stylesheet" href="../api/resources/style.css">';
        $header .= '</head><body><div id="content">';
        $content = '<h1>Project snapshot</h1>';
        $footer = '</div></body></html>';
        $htmlTpl = "<tr><td class=\"attributes\"><strong>%s</strong></td><td class=\"name\"><div><code>%s</code><div class=\"description short\">%s</div></div></td></tr>";

        foreach ($info["themes"] as $themeName => $theme) {
            $content .= "<h2>$themeName</h2>";
            $content .= '<table class="summary" id="templates" style="width:45%; float:left;">';
            $content .= "<caption>This theme defines " . count($theme["templates"]) . " template files.</caption><tbody>";

            foreach ($theme["templates"] as $template) {
                $content .= sprintf($htmlTpl,
                        empty($template["Template Name"]) ? 'Name not specified' : $template["Template Name"],
                        $template["filename"],
                        empty($template["Description"]) ? 'Missing description.' : $template["Description"]
                );
            }
            $content .= "</tbody></table>";

            $content .= '<table class="summary" id="libs" style="width:45%; margin-left:2%; float:left;">';
            $content .= "<caption>This theme uses " . count($theme["libs"]) . " obvious library files.</caption><tbody>";
            foreach ($theme["libs"] as $lib) {
                $content .= sprintf($htmlTpl,
                        empty($lib["Name"]) ? 'Name not specified' : $lib["Name"],
                        $lib["filename"],
                        empty($lib["Description"]) ? 'Missing description.' : $lib["Description"]
                );
            }
            $content .= "</tbody></table>";
        }

        $wpdocdir = $this->getWpdocDestination();
        if (!is_dir($wpdocdir)) {
            mkdir($wpdocdir);
        }

        return file_put_contents($wpdocdir . "/index.html", $header . $content . $footer, LOCK_EX);
    }
641047
public function setTitle($title = null)
    {
        if ($title === null) {
            $this->title = null;
        }
        else {
            $this->title = (string) $title;
        }
        return $this;
    }
907347
public function setTitle(string $title) {
        if($this->setModified('title', $title)->isModified()) {
            $this->title = $title;
        }

        return $this;
    }
492225
public function addInfo(Infoset $infoset) {
		if ($infoset->getLevel() > Infoset::LEVEL_ALERT) {
			$this->info[] = $infoset;
		} else {
			$this->info->unshift($infoset);
		}
	}
263380
protected function createContent(Infoset $info) {
		$this->includePathInfo($info);
		
		if (extension_loaded('apc')) {
			$apcInfo  = apc_cache_info();
			$apcFiles = [];
			
			foreach ($apcInfo['cache_list'] as $file) {
				$apcFiles[$file['filename']] = $file;
			}
			
			$this->apcInfo($info, $apcInfo);
		}
		
		$apcEnabled = ! empty($apcFiles);
		
		$groups = $this->includedFilesInfo($apcEnabled ? $apcFiles : null);
		
		foreach ($groups as $title => $group) {
			$table = $this->createTable();
			$table->setColsWidths([50, 50]);
			$table->setTitle($title);
			
			if ($apcEnabled) {
				$table->enableBbCodes();
			}
			
			foreach ($group as $file) {
				$table[] = $file;
			}
			
			$info[] = $table;
		}
	}
1107286
protected function apcInfo(Infoset $infoset, array $apcInfo) {
		$info = $this->createTable()
			->setColsWidths([50, 50])
			->setTitle('APC Info')
			->enableBbCodes();
		
		$infoset[] = $info;
		
		$info[] = ['Memory:', '[info]' . $this->formatMemory($apcInfo['mem_size']) . '[/info]'];

		if (isset($apcInfo['num_entries'])) {
			$info[] = ['Cache entries: ', '[success]' . $apcInfo['num_entries'] . '[/success]'];
		}
		else if (isset($apcInfo['nentries'])) {
			$info[] = ['Cache entries: ', '[success]' . $apcInfo['nentries'] . '[/success]'];
		}

		if (isset($apcInfo['num_hits'])) {
			$info[] = ['Cache hits: ', '[success]' . $apcInfo['num_hits'] . '[/success]'];
		}
		else if (isset($apcInfo['nhits'])) {
			$info[] = ['Cache hits: ', '[success]' . $apcInfo['nhits'] . '[/success]'];
		}

		if (isset($apcInfo['num_misses'])) {
			$info[] = ['Cache misses: ', '[success]' . $apcInfo['num_misses'] . '[/success]'];
		}
		else if (isset($apcInfo['nmisses'])) {
			$info[] = ['Cache misses: ', '[success]' . $apcInfo['nmisses'] . '[/success]'];
		}
	}
402973
public function setTitle( $title, $mode = 'set', $separator = ' | ' )
	{
		if( $mode == 'append' || $mode === 1 )
			$title	= $this->title.$separator.$title;
		else if( $mode == 'prepend' || $mode === -1 )
			$title	= $title.$separator.$this->title;
		$this->title	= $title;
	}
1342919
public function setTitle($title)
    {
        $returnValue = (bool) false;

        
		$this->title = $title;
		$returnValue = true;
        

        return (bool) $returnValue;
    }
1169657
protected function createContent(Infoset $info) {
		if (php_sapi_name() === 'cli') {
			return;
		}
		
		$headersList = $this->createList();
		$headersList->setTitle('Headers');
		
		$totalSize = 0;
		
		foreach (headers_list() as $header) {
			$totalSize += strlen($header);
			$headersList[] = $header;
		}
		
		$infoTable = $this->createTable()
			->enableBbCodes()
			->setTitle('Info');
		
		$contentSize = (ob_get_level() > 0)
			? $this->formatMemory(ob_get_length())
			: 'Unknown';
		
		$infoTable[] = ['Headers size:', '[info]' . $this->formatMemory($totalSize) . '[/info]'];
		$infoTable[] = ['Content size:', '[info]' . $contentSize . '[/info]'];
		
		$info[] = $infoTable;
		$info[] = $headersList;
	}
82447
protected function collectData(Infoset $info, array $source, $title) {
		$infoTable = $this->createTable();
		$infoTable->setTitle($title);
		
		foreach ($source as $name => $value) {
			if (is_array($value)) {
				foreach ($value as $key => $val) {
					if (strlen($val) > 1024) {
						$val = substr($val, 0, 1024) . '...';
					}
					
					$infoTable[] = [$name . '[' . $key . ']:', $val];
				}
				
				continue;
			}
			
			if (strlen($value) > 1024) {
				$value = substr($value, 0, 1024) . '...';
			}
			
			$infoTable[] = [$name . ':', $value];
		}
		
		$info[] = $infoTable;
	}
1323664
protected function handleIcon(Infoset $info) {
		if (empty($this->errors)) {
			$info->setIcon('ok');
			return;
		}
		
		if ($this->hasError) {
			$info->setIcon('alert');
			return;
		}
		
		$info->setIcon('warning');
	}