2024.8.23
Loading...
Searching...
No Matches
ajax.memcached.php File Reference

Go to the source code of this file.

Variables

global $bearsamppBins
 
global $bearsamppLang
 
 $port = $bearsamppBins->getMemcached()->getPort()
 
 $result
 
 $textDisabled = $bearsamppLang->getValue(Lang::DISABLED)
 
 $textServiceStarted = $bearsamppLang->getValue(Lang::HOMEPAGE_SERVICE_STARTED)
 
 $textServiceStopped = $bearsamppLang->getValue(Lang::HOMEPAGE_SERVICE_STOPPED)
 
if($bearsamppBins->getMemcached() ->isEnable()) else
 
 foreach ( $bearsamppBins->getMemcached() ->getVersionList() as $version)
 

Variable Documentation

◆ $bearsamppBins

global $bearsamppBins

Definition at line 10 of file ajax.memcached.php.

◆ $bearsamppLang

global $bearsamppLang

Definition at line 10 of file ajax.memcached.php.

◆ $port

$port = $bearsamppBins->getMemcached()->getPort()

Definition at line 28 of file ajax.memcached.php.

◆ $result

$result
Initial value:
= array(
'checkport' => '',
'versions' => '',
)

This script checks the status of the Memcached service, including the port check and service status. It also retrieves and displays the list of Memcached versions, highlighting the current version. The final output is encoded in JSON format.

@global object $bearsamppBins Provides access to various service binaries including Memcached. @global object $bearsamppLang Provides access to language strings for localization.

Definition at line 22 of file ajax.memcached.php.

◆ $textDisabled

$textDisabled = $bearsamppLang->getValue(Lang::DISABLED)

Definition at line 33 of file ajax.memcached.php.

◆ $textServiceStarted

$textServiceStarted = $bearsamppLang->getValue(Lang::HOMEPAGE_SERVICE_STARTED)

Definition at line 31 of file ajax.memcached.php.

◆ $textServiceStopped

$textServiceStopped = $bearsamppLang->getValue(Lang::HOMEPAGE_SERVICE_STOPPED)

Definition at line 32 of file ajax.memcached.php.

◆ else

if ( $bearsamppBins->getMemcached() ->isEnable()) else
Initial value:
{
$result['checkport'] = '<span class="float-end badge text-bg-secondary">' . $textDisabled . '</span>'
$textDisabled

Check if the Memcached service is enabled and update the 'checkport' status accordingly. If the service is enabled, check if the port is open and update the status. If the service is disabled, set the status to disabled.

Definition at line 46 of file ajax.memcached.php.

◆ foreach

foreach($bearsamppBins->getMemcached() ->getVersionList() as $version) ( $bearsamppBins->getMemcached() ->getVersionList() as)

Retrieve the list of Memcached versions and update the 'versions' status. Highlight the current version with a primary badge and other versions with a secondary badge.

Definition at line 54 of file ajax.memcached.php.