CoreFiles by mySites.guru
PhpSetting.php58 lines, 1,121 bytes, from Joomla_4.1.0-Stable-Full_Package.zip
Raw History Compare with 4.0.6
md5
b94fdc12107b0122a0e9ebaf734941d0
sha1
9ac415f8567b6e1436792746088ee15e1fe17514
sha256
4646027aff7bacf3bc5256668b845640e7ca48b4b04a38c1bb068d7a749cfa5c
<?php
/**
 * @package     Joomla.Administrator
 * @subpackage  com_admin
 *
 * @copyright   (C) 2009 Open Source Matters, Inc. <https://www.joomla.org>
 * @license     GNU General Public License version 2 or later; see LICENSE.txt
 */

namespace Joomla\Component\Admin\Administrator\Service\HTML;

\defined('_JEXEC') or die;

use Joomla\CMS\Language\Text;

/**
 * Utility class working with phpsetting
 *
 * @since  1.6
 */
class PhpSetting
{
	/**
	 * Method to generate a boolean message for a value
	 *
	 * @param   boolean  $val  is the value set?
	 *
	 * @return  string html code
	 */
	public function boolean($val)
	{
		return Text::_($val ? 'JON' : 'JOFF');
	}

	/**
	 * Method to generate a boolean message for a value
	 *
	 * @param   boolean  $val  is the value set?
	 *
	 * @return  string html code
	 */
	public function set($val)
	{
		return Text::_($val ? 'JYES' : 'JNO');
	}

	/**
	 * Method to generate a string message for a value
	 *
	 * @param   string  $val  a php ini value
	 *
	 * @return  string html code
	 */
	public function string($val)
	{
		return !empty($val) ? $val : Text::_('JNONE');
	}
}

The same content is in 51 releases, Joomla 4.0.0-beta6 to 4.2.0-beta2. See them all, or every version of this file.