CoreFiles by mySites.guru
toolbar.poll.php62 lines, 1,532 bytes, from Joomla_1.0.6-Stable-Full_Package.zip
Raw History Compare with 1.0.3
md5
ae1fc8cd4ab6a095f094414e0f73545c
sha1
69aefc8f3254d5d28000833793c5cca92325e293
sha256
cf38afd2a3571b86e7e7945aef3b31d9df6fa726cfff2e8a4c11464e41446ca4
<?php
/**
* @version $Id: toolbar.poll.php 85 2005-09-15 23:12:03Z eddieajau $
* @package Joomla
* @subpackage Polls
* @copyright Copyright (C) 2005 Open Source Matters. All rights reserved.
* @license http://www.gnu.org/copyleft/gpl.html GNU/GPL, see LICENSE.php
* Joomla! is free software. This version may have been modified pursuant
* to the GNU General Public License, and as distributed it includes or
* is derivative of works licensed under the GNU General Public License or
* other free or open source software licenses.
* See COPYRIGHT.php for copyright notices and details.
*/

// no direct access
defined( '_VALID_MOS' ) or die( 'Restricted access' );

require_once( $mainframe->getPath( 'toolbar_html' ) );

switch ($task) {
	case 'new':
		TOOLBAR_poll::_NEW();
		break;

	case 'edit':
		$cid = mosGetParam( $_REQUEST, 'cid', array(0) );
		if (!is_array( $cid )) {
			$cid = array(0);
		}

		$query = "SELECT published"
		. "\n FROM #__polls"
		. "\n WHERE id = $cid[0]"
		;
		$database->setQuery( $query );
		$published = $database->loadResult();

		$cur_template = $mainframe->getTemplate();

		TOOLBAR_poll::_EDIT( $cid[0], $cur_template );
		break;

	case 'editA':
		$id = mosGetParam( $_REQUEST, 'id', 0 );

		$query = "SELECT published"
		. "\n FROM #__polls"
		. "\n WHERE id = $id"
		;
		$database->setQuery( $query );
		$published = $database->loadResult();

		$cur_template = $mainframe->getTemplate();

		TOOLBAR_poll::_EDIT( $id, $cur_template );
		break;

	default:
		TOOLBAR_poll::_DEFAULT();
		break;
}
?>

The same content is in 4 releases, Joomla 1.0.3 to 1.0.8. See them all, or every version of this file.