<?php
/**
 * Adodis Blog package
 * @author J-Extension <contact@jextn.com>
 * @link http://www.jextn.com
 * @copyright (C) 2012 - 2013 J-Extension
 * @license GNU/GPL, see LICENSE.php for full license.
**/

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

JHtml::_('behavior.keepalive');
JHtml::_('behavior.tooltip');
JHtml::_('behavior.calendar');
JHtml::_('behavior.formvalidation');

$app	= JFactory::getApplication();
$user	= JFactory::getUser();
?>
<body onload="nonRegisteredBlog()">
<div class="edit item-page<?php echo $this->pageclass_sfx; ?>">
	<?php echo $this->loadTemplate('title'); ?>

	<dl id="system-message" style="display : none">
		<dd class="warning message">
			<ul>
				<li><div id="adodis-error-message"></div></li>
			</ul>
		</dd>
	</dl>

	<form action="<?php echo JRoute::_('index.php?option=com_adodisblog&a_id='.(int) $this->item->id); ?>" method="post" name="adminForm" id="adminForm" class="form-validate" enctype="multipart/form-data" onsubmit="return validateAUBlog()">
		<?php echo $this->loadTemplate('fields'); ?>

		<input type="hidden" name="task" value="blog.save" />
		<input type="hidden" name="userval"  id="userval" value="<?php echo $user->id;?>" />
		<input type="hidden" name="return" value="<?php echo $this->return_page;?>" />
		<input type="hidden" name="adodis-errorwarning-message" id="adodis-errorwarning-message" value="<?php echo JText::_('COM_ADODISBLOG_VALIDATION_FORM_FAILED'); ?>"/>

		<?php echo JHTML::_( 'form.token' ); ?>
	</form>
	<?php
	if($this->params->get('show_footertext', 1)) {
	?>
		<p class="copyright" style="text-align : right; font-size : 10px;">
			<?php /*require_once( JPATH_COMPONENT . DS . 'copyright' . DS . 'copyright.php' );*/ ?>
		</p>
	<?php
	}
	?>
</div>
</body>