Show PHP SAPI in WDT
This commit is contained in:
parent
84e4f4b23f
commit
16b342607c
@ -35,6 +35,10 @@
|
||||
<span class="sf-toolbar-status sf-toolbar-status-{{ collector.hasxdebug ? 'green' : 'red' }}">xdebug</span>
|
||||
<span class="sf-toolbar-status sf-toolbar-status-{{ collector.hasaccelerator ? 'green' : 'red' }}">accel</span>
|
||||
</div>
|
||||
<div class="sf-toolbar-info-piece">
|
||||
<b>PHP SAPI</b>
|
||||
<span>{{ collector.sapiName }}</span>
|
||||
</div>
|
||||
{% endspaceless %}
|
||||
{% endset %}
|
||||
{% include '@WebProfiler/Profiler/toolbar_item.html.twig' with { 'link': false } %}
|
||||
|
@ -54,6 +54,7 @@ class ConfigDataCollector extends DataCollector
|
||||
'xcache_enabled' => extension_loaded('xcache') && ini_get('xcache.cacher'),
|
||||
'wincache_enabled' => extension_loaded('wincache') && ini_get('wincache.ocenabled'),
|
||||
'bundles' => array(),
|
||||
'sapi_name' => php_sapi_name()
|
||||
);
|
||||
|
||||
if (isset($this->kernel)) {
|
||||
@ -188,6 +189,16 @@ class ConfigDataCollector extends DataCollector
|
||||
return $this->data['bundles'];
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the PHP SAPI name.
|
||||
*
|
||||
* @return string The environment
|
||||
*/
|
||||
public function getSapiName()
|
||||
{
|
||||
return $this->data['sapi_name'];
|
||||
}
|
||||
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
|
Reference in New Issue
Block a user