<?php
  /**
   * Copyright 2011 Zazavi - http://www.zazavi.com
   * Zazavi is free software released under the terms of the GNU General Public License.
   * You should have received a copy of the license.  If not, see <http://www.gnu.org/licenses/>.
   */
 
  if (!defined("_VALID_PHP"))
      die('Direct access to this location is not allowed.');
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title><?php echo $core->company;?></title>
<script language="javascript" type="text/javascript">
var IMGURL = "<?php echo ADMINURL; ?>/images";
var ADMINURL = "<?php echo ADMINURL; ?>";
</script>
<link href="assets/header.css" rel="stylesheet" type="text/css" />
<link href="assets/style.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="../assets/jquery.js"></script>
<script type="text/javascript" src="../assets/jquery-ui-1.8.13.custom.min.js"></script>
<script type="text/javascript" src="../assets/tooltip.js"></script>
<script type="text/javascript" src="../assets/global.js"></script>
<script type="text/javascript" src="../assets/jquery.validate.pack.js"></script>
<link href="../assets/redmond/jquery-ui.css" rel="stylesheet" type="text/css" />
<link href="../assets/prettyPhoto.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="../assets/jquery.prettyPhoto.js"></script>
<link href="assets/jquery.jqplot.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="editor/scripts/jscripts/tiny_mce/jquery.tinymce.js"></script>
<?php if($core->do == "menus"):?>
<link rel="stylesheet" href="assets/tree.css" type="text/css" media="screen" />
<script type="text/javascript" src="assets/jquery.tree.js"></script>
<?php endif;?>
<script type="text/javascript">
  $(document).ready(function() {
          $("#admin_form").validate({
                  meta: "validate"
          });

          $('input[type="checkbox"]').ezMark();
          $('input[type="radio"]').ezMark();

          $(function() {
                  $("a[rel^='prettyPhoto']").prettyPhoto({
                          theme: 'facebook'
                  });
          });

          $("#dialog").dialog({
                  bgiframe: true,
                  autoOpen: false,
                  width: "auto",
                  height: "auto",
                  zindex: 9998,
                  modal: false
          });
          $('a.langchange').click(function() {
                  var target = $(this).attr('href');
                  $('body').fadeOut(1000, function() {
                          window.location.href = target;
                  });
                  return false
          });

          $("a.langchange").click(function() {
                  $.cookie("LANG_ZAZAVIPRO", $(this).attr('rel'), {
                          expires: 120,
                          path: '/'
                  });
                  return false;
          });
		  
		  /* Tiny MCE */
		  
		  $('textarea.tinymce').tinymce({
			// Location of TinyMCE script
			script_url : 'editor/scripts/jscripts/tiny_mce/tiny_mce.js',

			// General options
			theme : "advanced",
			plugins : "autolink,lists,pagebreak,style,layer,table,save,advhr,advimage,advlink,emotions,iespell,inlinepopups,insertdatetime,preview,media,searchreplace,print,contextmenu,paste,directionality,fullscreen,noneditable,visualchars,nonbreaking,xhtmlxtras,template,advlist",

			// Theme options
			theme_advanced_buttons1 : "save,newdocument,|,bold,italic,underline,strikethrough,|,justifyleft,justifycenter,justifyright,justifyfull,styleselect,formatselect,fontselect,fontsizeselect,|,insertlayer,moveforward,movebackward,absolute,|,styleprops,|,tablecontrols,|,hr,|,fullscreen",
			theme_advanced_buttons2 : "cut,copy,paste,pastetext,pasteword,|,search,replace,|,bullist,numlist,|,outdent,indent,blockquote,|,undo,redo,|,link,unlink,anchor,image,cleanup,help,code,|,insertdate,inserttime,preview,|,forecolor,backcolor,|,visualchars,nonbreaking,template,pagebreak,|,charmap,emotions,iespell,media,advhr,|,print,|,ltr,rtl,|,cite,abbr,acronym,del,ins,attribs",
			theme_advanced_buttons3 : "",
			theme_advanced_toolbar_location : "top",
			theme_advanced_toolbar_align : "left",
			theme_advanced_statusbar_location : "bottom",
			theme_advanced_resizing : true,

			// Example content CSS (should be your site CSS)
			content_css : "css/content.css",

			// Drop lists for link/image/media/template dialogs
			template_external_list_url : "lists/template_list.js",
			external_link_list_url : "lists/link_list.js",
			external_image_list_url : "lists/image_list.js",
			media_external_list_url : "lists/media_list.js",

			// Replace values for the template plugin
			template_replace_values : {
				username : "Some User",
				staffid : "991234"
			}
		});
		  
  });
  /* Main Menu */
  $(function(){
          $("ul#nav li").hover(function(){
                  $(this).addClass("hover");
                  $('ul:first',this).css('visibility', 'visible');
          }, function(){
                  $(this).removeClass("hover");
                  $('ul:first',this).css('visibility', 'hidden');
          });
          $("ul#nav li:has(ul)").find("a:first").append("&nbsp;");
  });
  /* Lang Switcher */
  $.fn.langSwitcher = function() {
          $(this).click(function() {
                  return false;
          });
  }
  $('#lang-switcher').langSwitcher();
</script>
<?php
if(file_exists("modules/".sanitize(get("mod"))."/style.css"))
echo "<link href=\"modules/".sanitize(get("mod"))."/style.css\" rel=\"stylesheet\" type=\"text/css\" />\n";

if(file_exists("modules/".sanitize(get("mod"))."/script.js"))
echo "<script type=\"text/javascript\" src=\"modules/".sanitize(get("mod"))."/script.js\"></script>\n";
?>
</head>
<body>
               
                <div align="center">
<div id="content" style="width:1200px; text-align:left;">