<script type="text/javascript" src="/public/editor/fckeditor.js"></script>
<script type="text/javascript" src="/public/ckeditor/ckeditor.js"></script>
<script type="text/javascript" src="/public/ckfinder/ckfinder.js"></script>

<h1><?=$this->lang->line('pages_h1_edit')?></h1>


<?=form_open('admin/pageedit/'.$record->page_id)?>
<?=form_hidden('page_id',$record->page_id)?>
<?=form_hidden('do','update')?>
	
	<?if($record->page_category=="Események" || base64_decode($this->uri->segment(4))=="Események" || $record->page_category=="Events"):?>
	<div style="width: 200px; float: right;">
		<a href="/admin/alklubtemak">ARCHLine Klub témák szerkesztése</a><br>
		PDF fájl helye a Klub oldalon: #pdf# (minta: korábbi Klub oldal)
	</div>
	<?endif;?>
	
	<dl class="news_edit">
		<dt><?=$this->lang->line('faq_title')?></dt>
			<dd>
				<input type="text" value="<?=$record->page_title?>" size="80" maxlength="128" name="page_title" id="content_title" />
			</dd>
		<dt><?=$this->lang->line('page_category')?></dt>
			<dd>
				<?if($this->uri->segment(3)!="new"):?>
				<?=form_dropdown('page_category',$cat,$record->page_category)?>
				<?else:?>
				<?=form_dropdown('page_category',$cat,base64_decode($this->uri->segment(4)))?>
				<?endif;?>
			</dd>
		<dt><i>Rövid leírás</i></dt>
			<dd>
				<input type="text" value="<?=$record->page_desc?>" size="80" maxlength="128" name="page_desc" id="page_desc" />
			</dd>
		<dt><i>Linkek</i></dt>
			<dd>
				<input type="text" value="<?=$record->page_urls?>" size="80" maxlength="128" name="page_urls" id="page_urls" />
			</dd>
	</dl>	
			<div class="clear"></div>
			<textarea cols="64" rows="30" wrap="OFF" name="page_body" id="page_body"><?=$record->page_body?></textarea>
				<?=form_submit('ok',$this->lang->line('faq_button_save'))?>
	
	<div class="clear"></div>
	
	
</form>



<script type="text/javascript">
var editor = CKEDITOR.replace( 'page_body', {toolbar : 'Page', height: 320, entities: false } );

	// Just call CKFinder.SetupCKEditor and pass the CKEditor instance as the first argument.
	// The second parameter (optional), is the path for the CKFinder installation (default = "/ckfinder/").
//	CKFinder.setupCKEditor( editor, '../' ) ;
	CKFinder.setupCKEditor( editor, '/public/ckfinder/' ) ;

jQuery(document).ready(function($){
/* hogy ne leptessen ki*/
idozito = setTimeout(function(){menjel();},10000);
function menjel(){
	var url = "/other/semmi";
	jQuery('#semmidiv').load(url, function(response, status, xhr){
	//		alert("ok");
		});
	
	idozito = setTimeout(function(){menjel();},180000);
}
});
</script>

<div id="semmidiv" style="display: none;"></div>
