CoreFiles by mySites.guru
PostinstallHelper.php43 lines, 878 bytes, from Joomla_4.0.0-alpha12-Alpha-Full_Package.zip
Raw History Compare with 4.0.0-alpha11
md5
6660ef87f704047f89744b558c9648d9
sha1
44d2a0945c0a8acb5091db4074930e4cd0c6b565
sha256
e8d472ae05bcc31e2b02167296407381237cfc29b741b33f23ecfc5613240fb9
<?php
/**
 * @package     Joomla.Administrator
 * @subpackage  com_postinstall
 *
 * @copyright   Copyright (C) 2005 - 2019 Open Source Matters, Inc. All rights reserved.
 * @license     GNU General Public License version 2 or later; see LICENSE.txt
 */

namespace Joomla\Component\Postinstall\Administrator\Helper;

defined('_JEXEC') or die;

/**
 * Helper class for postinstall messages
 *
 * @since  3.6
 */
class PostinstallHelper
{
	/**
	 * Method for parsing ini files.
	 *
	 * @param   string  $path  Fancy path.
	 *
	 * @return  string  Parsed path.
	 *
	 * @since   3.6
	 */
	public function parsePath($path)
	{
		if (strpos($path, 'site://') !== false)
		{
			$path = JPATH_ROOT . str_replace('site://', '/', $path);
		}
		elseif (strpos($path, 'admin://') !== false)
		{
			$path = JPATH_ADMINISTRATOR . str_replace('admin://', '/', $path);
		}

		return $path;
	}
}

The same content is in 6 releases, Joomla 4.0.0-alpha7 to 4.0.0-alpha12. See them all, or every version of this file.