CoreFiles by mySites.guru
form.php33 lines, 736 bytes, from Joomla_3.5.1-Stable-Full_Package.zip
Raw History Compare with 3.5.0
md5
1374f6400817afec8fd63b9a1ac939d9
sha1
d96b16f58267356fab5242668033812a00a47356
sha256
92eedfcb81cb97607155834761ca04c78eeeed755b94f0ab54f32dd348b51084
<?php
/**
 * @package     Joomla.Libraries
 * @subpackage  HTML
 *
 * @copyright   Copyright (C) 2005 - 2016 Open Source Matters, Inc. All rights reserved.
 * @license     GNU General Public License version 2 or later; see LICENSE
 */

defined('JPATH_PLATFORM') or die;

/**
 * Utility class for form elements
 *
 * @since  1.5
 */
abstract class JHtmlForm
{
	/**
	 * Displays a hidden token field to reduce the risk of CSRF exploits
	 *
	 * Use in conjunction with JSession::checkToken()
	 *
	 * @return  string  A hidden input field with a token
	 *
	 * @see     JSession::checkToken()
	 * @since   1.5
	 */
	public static function token()
	{
		return '<input type="hidden" name="' . JSession::getFormToken() . '" value="1" />';
	}
}

The same content is in 29 releases, Joomla 3.5.0-beta2 to 3.7.0-alpha1. See them all, or every version of this file.