Gets content panel for the Debugbar

@return string
510558
public function getPanel()
    {
        $panel = '';

        $linebreak = $this->getLinebreak();

        # Support for APC
        if (function_exists('apc_sma_info') && ini_get('apc.enabled')) {
            $mem = apc_sma_info();
            $memSize = $mem['num_seg'] * $mem['seg_size'];
            $memAvail = $mem['avail_mem'];
            $memUsed = $memSize - $memAvail;

            $cache = apc_cache_info();
            if ($cache['mem_size'] > 0) {
                $panel .= '<h4>APC '.phpversion('apc').' Enabled</h4>';
                $panel .= round($memAvail/1024/1024, 1) . 'M available, '
                        . round($memUsed/1024/1024, 1) . 'M used' . $linebreak
                        . $cache['num_entries'].' Files cached ('
                        . round($cache['mem_size']/1024/1024, 1) . 'M)' . $linebreak
                        . $cache['num_hits'] . ' Hits ('
                        . round($cache['num_hits'] * 100 / ($cache['num_hits'] + $cache['num_misses']), 1) . '%)'
                        ;//. $linebreak
                        //. $cache['expunges'] . ' Expunges (cache full count)';
            }
        }
        
        if (function_exists('opcache_get_configuration')) {
            $opconfig = opcache_get_configuration();
            if ($opconfig['directives']['opcache.enable']) {
                $opstatus = opcache_get_status();
                $cache = $opstatus['opcache_statistics'];
                $panel .= '<h4>'.$opconfig['version']['opcache_product_name'].' '.$opconfig['version']['version'].' Enabled</h4>';
                $panel .= round($opstatus['memory_usage']['used_memory']/1024/1024, 1) . 'M used, '
                        . round($opstatus['memory_usage']['free_memory']/1024/1024, 1) . 'M free ('
                        . round($opstatus['memory_usage']['current_wasted_percentage'], 1) .'% wasted)' . $linebreak
                        . $cache['num_cached_scripts'].' Files cached' . $linebreak
                        . $cache['hits'] . ' Hits ('
                        . round($cache['opcache_hit_rate'], 1) . '%)';
            }
        }

        foreach ($this->_cacheBackends as $name => $backend) {
            $fillingPercentage = $backend->getFillingPercentage();
            $ids = $backend->getIds();

            # Print full class name, backends might be custom
            $panel .= '<h4>Cache '.$name.' ('.get_class($backend).')</h4>';
            $panel .= count($ids).' Entr'.(count($ids)>1?'ies':'y').''.$linebreak
                    . 'Filling Percentage: '.$backend->getFillingPercentage().'%'.$linebreak;

            $cacheSize = 0;
            foreach ($ids as $id) {
                # Calculate valid cache size
                $memPre = memory_get_usage();
                if ($cached = $backend->load($id)) {
                    $memPost = memory_get_usage();
                    $cacheSize += $memPost - $memPre;
                    unset($cached);
                }
            }
            $panel .= 'Valid Cache Size: ' . round($cacheSize/1024, 1) . 'K';
        }
        return $panel;
    }
497618
public function getContents()
    {
        if ($this->resource === null) {
            return '';
        }

        $result = substr($this->resource, $this->pointer);

        if ($result === false) {
            return '';
        }

        return $result;
    }
795111
public function getCMSFields()
    {
        $fields = parent::getCMSFields();
        $fields->removeByName('Content');
        if (Director::isDev()) {
            $fields->addFieldsToTab(
                'Root.Developer',
                array(
                    LiteralField::create(
                        'DeveloperNote',
                        '<p class="message warning">'._t('Placeable.DEVNOTE', 'This tab is only visible during development and is intended to help debug.').'</p>'
                    ),
                    GridField::create(
                        'Regions',
                        _t('PlaceablePage.SECTIONS', 'Regions'),
                        $this->Regions(),
                        GridFieldConfig_RecordEditor::create()
                    )
                )
            );
        }
        foreach ($this->PageFields as $region) {
            $fields->addFieldToTab(
                "Root.{$region->Type}",
                HeaderField::create(
                    "header[$region->Type]",
                    $region->Title
                )
            );
            foreach ($region->Fields as $field) {
                $fields->addFieldToTab(
                    "Root.{$region->Type}",
                    $field
                );
            }
            foreach ($region->Blocks as $Block) {
                $blockfields = CompositeField::create(
                    HeaderField::create(
                        "header[$Block->Type]",
                        $Block->Title
                    )
                );
                foreach ($Block->Fields as $field) {
                    $blockfields->push($field);
                }
                $fields->addFieldToTab(
                    "Root.{$region->Type}",
                    $blockfields
                );
            }
        }
        return $fields;
    }
797354
public function getContent()
    {
        $page = $this->getPage();
        $html = $page->getHTML();
        $html = $this->replaceChildrenCalls($html);

        return $html;
    }
982743
public function getSidebarContent() {
	    ob_start();
	    $root = Globals::getController()->getSignificantIndividual();
	    if ($root) {
	        $dindi = new Individual($root);
	        	
	        if (!$dindi->canDisplayIsSourced()) {
	            echo '<div class="error">', I18N::translate('This information is private and cannot be shown.'), '</div>';
	        } else {
	            echo '
	                <table class="issourcedtable">
	                   <tr>
	                       <td class="slabel"> ' . GedcomTag::getLabel('INDI') . '</td>
	                       <td class="svalue">' . FunctionsPrint::formatIsSourcedIcon('R', $dindi->isSourced(), 'INDI', 1).'</td>
	                   </tr>
	                   <tr>
	                       <td class="slabel">' . GedcomTag::getLabel('BIRT') . '</td>
	                       <td class="svalue">' . FunctionsPrint::formatIsSourcedIcon('E', $dindi->isBirthSourced(), 'BIRT', 1).'</td>
	                   </tr>';
	            
	            $fams = $root->getSpouseFamilies();
	            ($ct = count($fams)) > 1 ? $nb=1 : $nb=' ';	            
	            foreach($fams as $fam){
	                $dfam = new Family($fam);
	                echo '
	                    <tr>
	                       <td class="slabel right">
	                           <a href="' . $fam->getHtmlUrl() . '"> '. GedcomTag::getLabel('MARR');
	                if($ct > 1){
	                    echo ' ',$nb;
	                    $nb++;
	                }
	                echo '     </a>
	                       </td>
	                       <td class="svalue">' . FunctionsPrint::formatIsSourcedIcon('E', $dfam->isMarriageSourced(), 'MARR', 1).'</td>
	                   </tr>';
	            }
	            
	            if( $root->isDead() )
	                echo '
	                    <tr>
	                       <td class="slabel">' . GedcomTag::getLabel('DEAT') . '</td>
	                       <td class="svalue">' . FunctionsPrint::formatIsSourcedIcon('E', $dindi->isDeathSourced(), 'DEAT', 1).'</td>
	                   </tr>';
	            
	            echo '</table>';
	        }
	    }
	    return ob_get_clean();	    
	}
1149480
public function getContent()
    {
        if (null === $this->content && $this->fromGlobal) {
            $this->content = file_get_contents('php://input');
        }
        return $this->content;
    }
646549
public function getPanel(): string
	{
		if (empty($this->queries)) {
			return '';
		}

		$params = $this->connection->getParams();
		$host = ($params['driver'] === 'pdo_sqlite' && isset($params['path']))
			? 'path: ' . basename($params['path'])
			: sprintf('host: %s%s/%s', $this->connection->getHost(),
				(($p = $this->connection->getPort()) ? ':' . $p : ''),
				$this->connection->getDatabase());

		return	'<style>
				#nette-debug td.nette-Doctrine2Panel-sql { background: white !important}
				#nette-debug .nette-Doctrine2Panel-source { color: #BBB !important }
				#nette-debug nette-Doctrine2Panel tr table { margin: 8px 0; max-height: 150px; overflow:auto }
				#tracy-debug td.nette-Doctrine2Panel-sql { background: white !important}
				#tracy-debug .nette-Doctrine2Panel-source { color: #BBB !important }
				#tracy-debug nette-Doctrine2Panel tr table { margin: 8px 0; max-height: 150px; overflow:auto }
			</style>' .
				sprintf('<h1>Queries: %s%s, %s</h1>', count($this->queries),
					($this->totalTime ? ', time: ' . sprintf('%0.3f', $this->totalTime * 1000) . ' ms' : ''), $host) .
			'<div class="nette-inner tracy-inner nette-Doctrine2Panel">' .
				implode('<br>', array_filter([$this->renderPanelCacheStatistics(), $this->renderPanelQueries()])) .
			'</div>';
	}
889488
public function getMsgBody()
    {
        $body = null;

        if (!empty($this->_parts)) {
            if (count($this->_parts) > 1) {
                foreach ($this->_parts as $part) {
                    if ($part->contentType != Content::CT_TEXT_PLAIN && $this->getHeaders()->getMessageContentType() == Content::CT_MULTIPART_ALTERNATIVE) {
                        $body = $part->getContentDecode();
                        break;
                    }

                    $body .= PHP_EOL.$part->getContentDecode();
                }
            } else {
                $body = $this->_parts[0]->getContentDecode();
            }
        }

        return $body;
    }
1063708
public function getTopLevelContent() {
		$content = $this->blockInnerContents;
		$offset = strlen($this->openingDelimiter);

		foreach($this->getChildren() as $c) {
			$length = strlen($c->getOuterContents());
			$content = substr_replace($content, str_repeat("\n", $length), $c->getRelativeOffset()+$offset, $length);
		}

		return str_replace("\n", "", $content);
	}
1361020
public function getContent()
    {
        if (!$this->layout) {
            throw new InvalidConfigException("Unable to find the requested cms layout '{$this->layout_id}' for nav item page id '{$this->id}'. Make sure your page does not have an old inactive/deleted cms layout selected.");
        }

        $placholders = [];
        foreach ($this->layout->getJsonConfig('placeholders') as $row) {
            foreach ($row as $item) {
                $placholders[$item['var']] = $this->renderPlaceholder($item['var']);
            }
        }
        
        return Yii::$app->view->render($this->layout->view_file, [
            'placeholders' => $placholders,
        ], $this);
    }
1257406
protected function getContent()
    {
        $widget = (object) $this->widget->execute();
        $widget->cache_key = $this->widget->cacheKeys();

        return trim(preg_replace('/(\s|\r|\n)+</', '<',
            view($this->widget->template(), compact('widget'))->render()
        ));

        // Debug function if App has error:
        // `Cannot end a section without first starting one.`
        return view($this->widget->template(), compact('widget'));
    }
261725
public function getPermissionsActionPanel()
    {
        $fields = FieldList::create();
        $showFields = array(
            'CanViewType'  => '',
            'ViewerGroups' => 'hide',
            'CanEditType'  => '',
            'EditorGroups' => 'hide',
        );
        /** @var SiteTree $siteTree */
        $siteTree = singleton('SiteTree');
        $settingsFields = $siteTree->getSettingsFields();

        foreach ($showFields as $name => $extraCss) {
            $compositeName = "Root.Settings.$name";
            /** @var FormField $field */
            if ($field = $settingsFields->fieldByName($compositeName)) {
                $field->addExtraClass($extraCss);
                $title = str_replace('page', 'document', $field->Title());
                $field->setTitle($title);

                // Remove Inherited source option from DropdownField
                if ($field instanceof DropdownField) {
                    $options = $field->getSource();
                    unset($options['Inherit']);
                    $field->setSource($options);
                }
                $fields->push($field);
            }
        }

        $this->extend('updatePermissionsFields', $fields);

        return CompositeField::create($fields);
    }
525607
public function getBufferedContents(): string {
	    if ($this->jhtmlJsonPayload === null) {
	        return $this->htmlView->getBufferedContents();
	    }
	    
	    return $this->jhtmlJsonPayload->getBufferedContents();
	}
1351529
protected function getControllerContent()
    {
        if (!$stub = $this->getControllerStub()) {
            return '';
        }

        $sectionSegmentsStudly = $this->sectionSegmentsStudly;

        $name      = array_pop($sectionSegmentsStudly).'Controller';
        $namespace = $this->appNs.'\Http\Controllers';
        $requestNs = $this->appNs.'\Http\Requests\\'.implode('\\', $this->sectionSegmentsStudly);
        $listingClass = $this->appNs.'\Listings\\'.implode('\\', $this->sectionSegmentsStudly).'Listing';

        if ($sectionSegmentsStudly) {
            $namespace .= '\\'.implode('\\', $sectionSegmentsStudly);
        }

        return strtr($stub, array_merge($this->getCommonReplacements(), [
            '{{namespace}}'        => $namespace,
            '{{name}}'             => $name,
            '{{requestNamespace}}' => $requestNs,
            '{{listingClass}}'     => $listingClass,
        ]));
    }
1046611
public function getClosingContent()
    {
        $content = '';
        if ($this->_color) {
            $content .= '\cf0 ';
        }
        if ($this->_backgroundColor) {
            $content .= '\chcbpat0 ';
        }
        if ($this->_isBold) {
            $content .= '\b0 ';
        }
        if ($this->_isItalic) {
            $content .= '\i0 ';
        }
        if ($this->_isUnderlined) {
            $content .= '\ul0 ';
        }
        return $content;
    }
996152
public function getContentData()
    {
        $data = [
            'locale' => $this->contentLocaleProvider->getCurrentLocale(),
        ];
        if (null !== $page = $this->pageHelper->getCurrent()) {
            $data['id'] = $page->getId();
        }

        return $data;
    }
458254
public function toolContentAction()
    {
        $translator = $this->getServiceLocator()->get('translator');

        $container = new Container('meliscore');
        $locale    = $container['melis-lang-locale'];

        $columns            = $this->tool()->getColumns();
        $columns['actions'] = array('text' => $translator->translate('tr_meliscore_global_action'), 'width' => '20%');

        $theme   = $this->getTheme();
        $themeId = isset($theme->pros_theme_id) ? (int) $theme->pros_theme_id : null;
        $view    = new ViewModel();
        $view->melisKey               = $this->getMelisKey();
        $view->tableColumns           = $columns;
        $view->getToolDataTableConfig = $this->tool()->getDataTableConfiguration('#' . $themeId . '_tableToolProspectsThemeItems', true, false, array('order' => '[[ 0, "desc" ]]'));
        $view->theme = $theme;

        return $view;
    }