CoreFiles by mySites.guru
p3p.php31 lines, 743 bytes, from Joomla_2.5.2-Stable-Full_Package.zip
Raw History Compare with 2.5.1
md5
a9698d5148b65d23eef3b638d729cfe0
sha1
60ab2081596facb75e7768ac9708f56007a92913
sha256
b7435ceb9784c5d1c999c66a4169f4cb992505fcec2c349a1b1b2dcaa8935bfa
<?php
/**
 * @copyright	Copyright (C) 2005 - 2012 Open Source Matters, Inc. All rights reserved.
 * @license		GNU General Public License version 2 or later; see LICENSE.txt
 */

// no direct access
defined('_JEXEC') or die;

/**
 * Joomla! P3P Header Plugin
 *
 * @package		Joomla.Plugin
 * @subpackage	System.p3p
 */
class plgSystemP3p extends JPlugin
{
	function onAfterInitialise()
	{
		// Get the header
		$header = $this->params->get('header', 'NOI ADM DEV PSAi COM NAV OUR OTRo STP IND DEM');
		$header = trim($header);
		// Bail out on empty header (why would anyone do that?!)
		if( empty($header) )
		{
			return;
		}
		// Replace any existing P3P headers in the response
		JResponse::setHeader('P3P', 'CP="'.$header.'"', true);
	}
}

The same content is in 9 releases, Joomla 2.5.0 to 2.5.8. See them all, or every version of this file.