|
<!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 $title ?> | <?php echo $this->settings->get('title') ?></title>
|
|
<?php echo html::link('media/images/favicon_16x16.png', 'shorcut icon', 'image/png', FALSE); ?>
|
|
<?php echo html::stylesheet('media/css/style.css', 'screen and (min-device-width: 481px)') ?>
|
|
<?php echo html::stylesheet('media/css/tables.css', 'screen and (min-device-width: 481px)') ?>
|
|
<?php echo html::stylesheet('media/css/forms.css', 'screen and (min-device-width: 481px)') ?>
|
|
<!--[if IE]>
|
|
<?php echo html::stylesheet('media/css/style.css', 'screen') ?>
|
|
<?php echo html::stylesheet('media/css/tables.css', 'screen') ?>
|
|
<?php echo html::stylesheet('media/css/forms.css', 'screen') ?>
|
|
<![endif]-->
|
|
<?php echo html::stylesheet('media/css/m.style.css', 'handheld, only screen and (max-device-width: 480px)') ?>
|
|
<?php echo html::stylesheet('media/css/m.tables.css', 'handheld, only screen and (max-device-width: 480px)') ?>
|
|
<?php echo html::stylesheet('media/css/m.forms.css', 'handheld, only screen and (max-device-width: 480px)') ?>
|
|
<?php echo html::stylesheet('media/css/print.css', 'print') ?>
|
|
<?php echo html::stylesheet('media/css/jquery.autocomplete.css') ?>
|
|
<?php echo html::stylesheet('media/css/jquery.validate.password.css') ?>
|
|
<?php echo html::stylesheet('media/css/jquery-ui.css') ?>
|
|
<?php echo html::stylesheet('media/css/highslide.css') ?>
|
|
<?php echo html::script('media/js/js', FALSE) ?>
|
|
<?php echo html::script('media/js/jquery.min', FALSE) ?>
|
|
<?php echo html::script('media/js/jquery-ui.min', FALSE) ?>
|
|
<?php echo html::script('media/js/jquery.ui.datepicker-cs', FALSE) ?>
|
|
<?php echo html::script('media/js/jquery.autocomplete.min', FALSE) ?>
|
|
<?php echo html::script('media/js/jquery.validate.min', FALSE) ?>
|
|
<?php echo html::script('media/js/jquery.validate.password', FALSE) ?>
|
|
<?php echo html::script('media/js/jquery.metadata', FALSE) ?>
|
|
<?php echo html::script('media/js/jquery.tablesorter.min', FALSE) ?>
|
|
<?php echo html::script('media/js/messages_cs', FALSE) ?>
|
|
<?php // echo html::script('media/js/redirection', FALSE) ?>
|
|
<?php echo html::script('media/js/highslide/highslide-with-html.js', FALSE) ?>
|
|
<?php echo html::script('media/js/php.min', FALSE) ?>
|
|
<?php echo html::script('media/js/tinymce/tiny_mce', FALSE) ?>
|
|
<?php if (!$this->popup): ?>
|
|
<script language="javascript" type="text/javascript">
|
|
tinyMCE.init({
|
|
// General options
|
|
mode : "textareas",
|
|
theme : "advanced",
|
|
editor_selector : "wysiwyg",
|
|
editor_deselector : "textarea",
|
|
plugins : "safari,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",
|
|
elements : "registration_license",
|
|
theme_advanced_toolbar_location : "top",
|
|
theme_advanced_buttons1 : "save,newdocument,|,bold,italic,underline,strikethrough,|,justifyleft,justifycenter,justifyright,justifyfull,|,styleselect,formatselect,fontselect,fontsizeselect",
|
|
theme_advanced_buttons2 : "pastetext,pasteword,|,search,replace,|,bullist,numlist,|,outdent,indent,blockquote,|,undo,redo,|,link,unlink,anchor,image,cleanup,help,code,|,insertdate,inserttime,preview,|,forecolor,backcolor",
|
|
theme_advanced_buttons3 : "tablecontrols,|,hr,removeformat,visualaid,|,sub,sup,|,charmap,emotions,iespell,media,advhr,|,print,|,ltr,rtl,|,fullscreen",
|
|
theme_advanced_buttons4 : "insertlayer,moveforward,movebackward,absolute,|,styleprops,|,cite,abbr,acronym,del,ins,attribs,|,visualchars,nonbreaking,template,pagebreak",
|
|
theme_advanced_toolbar_location : "top",
|
|
theme_advanced_toolbar_align : "left",
|
|
theme_advanced_statusbar_location : "bottom",
|
|
theme_advanced_resizing : false,
|
|
height:"480px",
|
|
width:"656px"
|
|
});
|
|
</script>
|
|
<?php endif ?>
|
|
<script type="text/javascript">
|
|
<?php echo isset($extra_scripts) ? $extra_scripts : '' ?>
|
|
|
|
$(document).ready(function(){
|
|
|
|
var $dialog = $('<div></div>').dialog({
|
|
autoOpen: false,
|
|
title: '<?php echo url_lang::lang('texts.Change language') ?>',
|
|
modal: true,
|
|
position: ['center', 50]
|
|
});
|
|
|
|
$.validator.passwordRating.messages = {
|
|
"too-short": "<?php echo url_lang::lang('texts.Too short') ?>",
|
|
"very-weak": "<?php echo url_lang::lang('texts.Very weak') ?>",
|
|
"weak": "<?php echo url_lang::lang('texts.Weak') ?>",
|
|
"good": "<?php echo url_lang::lang('texts.Good') ?>",
|
|
"strong": "<?php echo url_lang::lang('texts.Strong') ?>"
|
|
}
|
|
|
|
$("form").validate();
|
|
|
|
$("table").tablesorter();
|
|
|
|
$('#change_language_link').click(function(){
|
|
$dialog.load(this.href+'?popup=1&dialog=1');
|
|
$dialog.dialog('open');
|
|
return false;
|
|
})
|
|
|
|
/* Show menu in mobile browsers (default state of menu is hide) */
|
|
$('#a_show_menu').click(function () {
|
|
$('#menu').toggle();
|
|
$(this).hide();
|
|
return false;
|
|
});
|
|
|
|
$('.focus').focus();
|
|
|
|
$('.ico_add').click(function(){
|
|
var win = window.open(this.href, 'formpopup', 'width=930,height=500,resizeable,scrollbars');
|
|
win.focus();
|
|
|
|
if (window.opener == null) window.opener = self;
|
|
|
|
return false;
|
|
})
|
|
|
|
$('.delete_link').click(function(){
|
|
return window.confirm('<?php echo url_lang::lang('texts.Do you really want to delete this record') ?>?');
|
|
})
|
|
|
|
$.validator.addMethod('ip_address', function(value) {
|
|
return value.match(/^((25[0-5])|(2[0-4][0-9])|(1[0-9][0-9])|([1-9][0-9])|[0-9])\.((25[0-5])|(2[0-4][0-9])|(1[0-9][0-9])|([1-9][0-9])|[0-9])\.((25[0-5])|(2[0-4][0-9])|(1[0-9][0-9])|([1-9][0-9])|[0-9])\.((25[0-5])|(2[0-4][0-9])|(1[0-9][0-9])|([1-9][0-9])|[0-9])$/);
|
|
}, '<?php echo url_lang::lang('texts.Invalid IP address') ?>');
|
|
|
|
$.validator.addMethod('mac_address', function(value) {
|
|
return value.match(/^([0-9a-fA-F]{2}:){5}[0-9a-fA-F]{2}$/);
|
|
}, '<?php echo url_lang::lang('texts.Invalid MAC address') ?>');
|
|
|
|
$.validator.addMethod('to_field', function(value) {
|
|
return value.match(/^([a-z][a-z0-9]*[_]{0,1}[a-z0-9]+),?[ ]*(([a-z][a-z0-9]*[_]{0,1}[a-z0-9]+),?[ ]*)*$/);
|
|
}, '<?php echo url_lang::lang('texts.Invalid value') ?>');
|
|
|
|
$.validator.addMethod('suffix', function(value) {
|
|
return value.match(/^\/([^\/]+\/)*$/);
|
|
}, '<?php echo url_lang::lang('texts.suffix has to start with slash character and has to end with slash character')?>');
|
|
|
|
$.validator.addMethod('var_sym', function(value) {
|
|
return value.match(/^[0-9]{1,10}$/);
|
|
}, '<?php echo url_lang::lang('texts.Bad variable symbol format.') ?>');
|
|
|
|
$.validator.addMethod('icq', function(value) {
|
|
return value.match(/(^[0-9]{9}$)|(^[0-9]{3}-[0-9]{3}-[0-9]{3}$)/);
|
|
}, '<?php echo url_lang::lang('texts.Bad ICQ format.') ?>');
|
|
|
|
$.validator.addMethod('jabber', function(value) {
|
|
return value.match(/^([a-zA-Z0-9]+)((\-|_|\.)([a-zA-Z0-9]+))*@([a-zA-Z0-9]+)((\-|_)([a-zA-Z0-9]+))*(\.[a-z]+)+$/);
|
|
}, '<?php echo url_lang::lang('texts.Bad jabber format.') ?>');
|
|
|
|
$('#ip_address').keyup(function(){
|
|
// test if ip address is complete and valid
|
|
var complete = this.value.match(/^((25[0-5])|(2[0-4][0-9])|(1[0-9][0-9])|([1-9][0-9])|[0-9])\.((25[0-5])|(2[0-4][0-9])|(1[0-9][0-9])|([1-9][0-9])|[0-9])\.((25[0-5])|(2[0-4][0-9])|(1[0-9][0-9])|([1-9][0-9])|[0-9])\.((25[0-5])|(2[0-4][0-9])|(1[0-9][0-9])|([1-9][0-9])|[0-9])$/);
|
|
var subnet = document.getElementById('subnet_id');
|
|
|
|
// for each subnets from select box
|
|
for (i=0;i<subnet.options.length;i++)
|
|
{
|
|
var value = subnet.options[i].value;
|
|
var text = subnet.options[i].text;
|
|
|
|
if (value != 0)
|
|
{
|
|
arr = text.split(' ');
|
|
var subnet_address = arr[0].substr(0, arr[0].length-1);
|
|
|
|
arr = subnet_address.split('/');
|
|
var address = arr[0];
|
|
var netmask = arr[1];
|
|
var range = Math.pow(2, 32-netmask);
|
|
|
|
// ip address is valid and complete
|
|
if (complete != null)
|
|
{
|
|
// test if ip address belongs to this subnet
|
|
if ((ip2long(this.value) > ip2long(address)) && (ip2long(this.value) < (ip2long(address) + range)))
|
|
{
|
|
// choose this
|
|
subnet.selectedIndex = i;
|
|
break;
|
|
}
|
|
}
|
|
|
|
// test if this subnet starts with uncomplete ip address
|
|
if (this.value != '' && address.substr(0, this.value.length).indexOf(this.value)!=-1)
|
|
{
|
|
// choose this
|
|
subnet.selectedIndex = i;
|
|
break;
|
|
}
|
|
|
|
// else choose default
|
|
subnet.selectedIndex = 0;
|
|
}
|
|
}
|
|
});
|
|
});
|
|
|
|
hs.graphicsDir = '<?php echo url::base()?>media/images/highslide/';
|
|
hs.outlineType = 'rounded-white';
|
|
hs.wrapperClassName = 'draggable-header';
|
|
|
|
hs.lang.cssDirection = '<?php echo url_lang::lang('texts.ltr')?>';
|
|
hs.lang.loadingText = '<?php echo url_lang::lang('texts.Loading...')?>';
|
|
hs.lang.loadingTitle = '<?php echo url_lang::lang('texts.Click to cancel')?>';
|
|
hs.lang.focusTitle = '<?php echo url_lang::lang('texts.Click to bring to front')?>';
|
|
hs.lang.fullExpandTitle = '<?php echo url_lang::lang('texts.Expand to actual size (f)')?>';
|
|
hs.lang.creditsText = '<?php echo url_lang::lang('texts.Powered by <i>Highslide JS</i>')?>';
|
|
hs.lang.creditsTitle = '<?php echo url_lang::lang('texts.Go to the Highslide JS homepage')?>';
|
|
hs.lang.previousText = '<?php echo url_lang::lang('texts.Previous')?>';
|
|
hs.lang.nextText = '<?php echo url_lang::lang('texts.Next')?>';
|
|
hs.lang.moveText = '<?php echo url_lang::lang('texts.Move')?>';
|
|
hs.lang.closeText = '<?php echo url_lang::lang('texts.Close')?>';
|
|
hs.lang.closeTitle = '<?php echo url_lang::lang('texts.Close (esc)')?>';
|
|
hs.lang.resizeTitle = '<?php echo url_lang::lang('texts.Resize')?>';
|
|
hs.lang.playText = '<?php echo url_lang::lang('texts.Play')?>';
|
|
hs.lang.playTitle = '<?php echo url_lang::lang('texts.Play slideshow (spacebar)')?>';
|
|
hs.lang.pauseText = '<?php echo url_lang::lang('texts.Pause')?>';
|
|
hs.lang.pauseTitle = '<?php echo url_lang::lang('texts.Pause slideshow (spacebar)')?>';
|
|
hs.lang.previousTitle = '<?php echo url_lang::lang('texts.Previous (arrow left)')?>';
|
|
hs.lang.nextTitle = '<?php echo url_lang::lang('texts.Next (arrow right)')?>';
|
|
hs.lang.moveTitle = '<?php echo url_lang::lang('texts.Move')?>';
|
|
hs.lang.fullExpandText = '<?php echo url_lang::lang('texts.1:1')?>';
|
|
hs.lang.restoreTitle = '<?php echo url_lang::lang('texts.Click to close image, click and drag to move. Use arrow keys for next and previous.')?>';
|
|
|
|
</script>
|
|
<?php echo isset($other_styles) ? $other_styles : '' ?>
|
|
</head>
|
|
<body<?php echo (isset($body_extra) ? ' '.$body_extra : '') ?>>
|
|
<?php if (!$this->popup): ?>
|
|
<div id="main">
|
|
<div id="header">
|
|
<h1 id="logo"><span>Free<em>Net</em>IS</span></h1>
|
|
<div class="separator1"></div>
|
|
<div class="status">
|
|
<span><?php echo $this->session->get('user_id', 0) ? url_lang::lang('texts.Logged user') : url_lang::lang('texts.Unlogged user') ?></span>
|
|
<a href="<?php echo url_lang::base() ?>languages/change" title="<?php echo url_lang::lang('texts.Change language') ?>" id="change_language_link"><img src="<?php echo url::base() ?>media/images/flags/<?php echo Config::get('lang') ?>.jpg" alt="print icon" alt="<?php echo url_lang::lang('texts.Change language') ?>"/></a> |
|
|
<?php
|
|
if ($this->session->get('user_id', 0))
|
|
{
|
|
$mail_message_model = new Mail_message_Model();
|
|
$unread_mails = $mail_message_model->count_all_unread_inbox_messages_by_user_id($this->session->get('user_id', 0));
|
|
$src = (!$unread_mails) ? url::base().'media/images/inbox.png' : url::base().'media/images/inbox_warning.png';
|
|
$title = ($unread_mails) ? url_lang::lang('texts.Mail inbox').' ('.$unread_mails.')' : url_lang::lang('texts.Mail inbox');
|
|
echo html::anchor(url_lang::base().'mail/inbox',html::image(array('src' => $src, 'alt' => $title, 'title' => $title))).' | ';
|
|
}
|
|
?>
|
|
<a href="javascript: window.print();"><img src="<?php echo url::base() ?>media/images/print.png" alt="print icon" /></a>
|
|
|
|
<?php
|
|
if ($this->session->get('user_id', 0) && $this->acl_check_2D('freenetis', 'write_email'))
|
|
{
|
|
$model_sms_message = new Sms_message_Model();
|
|
$unread_sms = count($model_sms_message->get_unread_messages());
|
|
echo html::anchor(url_lang::base().'sms/show_unread', ($unread_sms != 0 )?'<b class="orange" >SMS('.$unread_sms.')</b>':'SMS()', array('class' => 'orange', 'style' => 'margin-left: 20px;text-decoration: none;', 'title' => url_lang::lang('texts.Show unread messages')));
|
|
}
|
|
?>
|
|
<table>
|
|
<tr>
|
|
<td class="orange"><?php echo $this->session->get('user_id', 0) ? url_lang::lang('texts.Name').':' : '' ?></td>
|
|
<td class="bold"> <?php echo $this->session->get('user_name').' '.$this->session->get('user_surname') ?></td>
|
|
<td class="bold"> <?php echo $this->session->get('login').' '.$this->session->get('login') ?></td>
|
|
</tr>
|
|
<tr>
|
|
<td class="orange"><?php echo url_lang::lang('texts.IP address').':' ?></td>
|
|
<td class="bold">
|
|
<?php echo server::remote_addr() ?>
|
|
<?php
|
|
echo ($ptr_record = dns::get_ptr_record(server::remote_addr()))!='' ? ' <i>('.$ptr_record.')</i>' : ''
|
|
?>
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
</div>
|
|
<div class="map"></div>
|
|
<div class="logout"><span><?php echo $this->session->get('user_id', 0) ? html::anchor(url_lang::base().'login/logout/', url_lang::lang('texts.Logout')) : html::anchor(url_lang::base().'login', url_lang::lang('texts.Login')) ?></span></div>
|
|
</div>
|
|
|
|
<div id="middle">
|
|
<a href="#" id="a_show_menu"><?php echo url_lang::lang('texts.Show menu') ?></a>
|
|
<div id="menu">
|
|
<div id="menu-padd">
|
|
<?php if ($this->session->get('user_id')) echo new View('menu') ?>
|
|
</div>
|
|
</div>
|
|
|
|
<div id="content">
|
|
<div id="content-padd">
|
|
<?php echo $content ?>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="clear"></div>
|
|
</div>
|
|
|
|
<div id="footer" class="noprint">
|
|
<div id="footer-padd">
|
|
<?php
|
|
$footer_links[] = html::anchor("http://wiki.freenetis.org/", url_lang::lang('texts.Documentation'));
|
|
$footer_links[] = html::anchor("http://sourceforge.net/projects/freenetis/", url_lang::lang('texts.Project site'));
|
|
echo ' '.implode(' | ', $footer_links);
|
|
?>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<?php else: ?>
|
|
<?php if (!$this->dialog): ?>
|
|
<div id="content" class="popup">
|
|
<div id="content-padd">
|
|
<?php echo $content ?>
|
|
</div>
|
|
</div>
|
|
<?php else: ?>
|
|
<?php echo $content ?>
|
|
<?php endif ?>
|
|
<?php endif ?>
|
|
|
|
</body>
|
|
</html>
|
|
|