CoreFiles by mySites.guru
view.html.php60 lines, 1,443 bytes, from Joomla_1.6.6-Stable-Full_Package.zip
Raw History Compare with 1.6.5
md5
fb226ccbde6057f40a7093356ed0e02c
sha1
ede5dfe13ae5601efefabb3f731cd1ef3822ad9c
sha256
54c478d27653cb20dc48fa3d3af40972358a0adc424e944fdf5e497c934d8118
<?php
/**
 * @version		$Id: view.html.php 20196 2011-01-09 02:40:25Z ian $
 * @copyright	Copyright (C) 2005 - 2011 Open Source Matters, Inc. All rights reserved.
 * @license		GNU General Public License version 2 or later; see LICENSE.txt
 */

defined('_JEXEC') or die;

jimport('joomla.application.component.view');

/**
 * @package		Joomla.Administrator
 * @subpackage	com_admin
 */
class AdminViewProfile extends JView
{
	protected $form;
	protected $item;
	protected $state;

	/**
	 * Display the view
	 */
	public function display($tpl = null)
	{
		$this->form			= $this->get('Form');
		$this->item			= $this->get('Item');
		$this->state		= $this->get('State');

		// Check for errors.
		if (count($errors = $this->get('Errors'))) {
			JError::raiseError(500, implode("\n", $errors));
			return false;
		}

		$this->form->setValue('password',	null);
		$this->form->setValue('password2',	null);

		parent::display($tpl);
		$this->addToolbar();
	}

	/**
	 * Add the page title and toolbar.
	 *
	 * @since	1.6
	 */
	protected function addToolbar()
	{
		JRequest::setVar('hidemainmenu', 1);

		JToolBarHelper::title(JText::_('COM_ADMIN_VIEW_PROFILE_TITLE'), 'user-profile');
		JToolBarHelper::apply('profile.apply','JTOOLBAR_APPLY');
		JToolBarHelper::save('profile.save','JTOOLBAR_SAVE');
		JToolBarHelper::cancel('profile.cancel', 'JTOOLBAR_CLOSE');
		JToolBarHelper::divider();
		JToolBarHelper::help('JHELP_ADMIN_USER_PROFILE_EDIT');
	}
}

The same content is in 7 releases, Joomla 1.6.0 to 1.6.6. See them all, or every version of this file.