CoreFiles by mySites.guru
url.php29 lines, 559 bytes, from Joomla_3.7.3-Stable-Full_Package.zip
Raw History Compare with 3.7.2
md5
0ed447e696dd39fb1d8d7b1db1819bbd
sha1
3424c23e13f501d8b21984a3cb8d7a2238787f9e
sha256
dd7bb5e4dd56497617a728fbd104836fecfa4c335e398af44daf22b991f6d04b
<?php
/**
 * @package     Joomla.Plugin
 * @subpackage  Fields.URL
 *
 * @copyright   Copyright (C) 2005 - 2017 Open Source Matters, Inc. All rights reserved.
 * @license     GNU General Public License version 2 or later; see LICENSE.txt
 */
defined('_JEXEC') or die;

$value = $field->value;

if ($value == '')
{
	return;
}

$attributes = '';

if (!JUri::isInternal($value))
{
	$attributes = ' rel="nofollow noopener noreferrer" target="_blank"';
}

echo sprintf('<a href="%s"%s>%s</a>',
	htmlspecialchars($value),
	$attributes,
	htmlspecialchars($value)
);

The same content is in 21 releases, Joomla 3.7.3-beta1 to 4.0.0-alpha2. See them all, or every version of this file.