$seo->meta_title(TIPO_PAGINA, PAGINA) , 'description' => $seo->meta_description(TIPO_PAGINA, PAGINA) , 'keywords' => $seo->meta_keywords(TIPO_PAGINA, PAGINA) ); if(imatch('msie 6', $_SERVER['HTTP_USER_AGENT'])){ $javascripts_required['scripts/unitpngfix'] = true; } /* ****************************************************************************************************************************************************/ // Licenza //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// $protocol = imatch('https',$_SERVER["SERVER_PROTOCOL"]) ?'https://':'http://'; $domain = strtolower($_SERVER['HTTP_HOST']).'/'; $basedir = explode('/',$_SERVER['PHP_SELF']); unset($basedir[count($basedir)-1]); $basedir = trim(join('/',$basedir),'/'); $url = $basedir!='' ? $domain.$basedir.'/' : trim($domain,'/'); if(in_array($url,$ALLOWED)) { $sito_ok = true; } else { die('.'); } /* ****************************************************************************************************************************************************/ // Sito e Home page //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// if(modulo_attivo('cms')){ call('base.home'); } else if(modulo_attivo('filesharing')){ define('HOME','file-sharing'); if($_GET['p']==''){ $_GET['p'] = 'file-sharing'; } # define('PAGINA',$_GET['p']); # define('TIPO_PAGINA',(in_array(PAGINA,$seo_riservate) ?'pagina_riservata' :'backend')); } else if(modulo_attivo('help-desk')){ define('HOME','help-desk'); if($_GET['p']==''){ $_GET['p'] = 'help-desk'; } # define('PAGINA',$_GET['p']); # define('TIPO_PAGINA',(in_array(PAGINA,$seo_riservate) ?'pagina_riservata' :'backend')); } /* ****************************************************************************************************************************************************/ // Lettura skin //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// $layout = new LAYOUT; if(TIPO_PAGINA=='pagina_riservata') { #riservate $pagina = layout('skins/'.SKIN.'/full.html',0,0); } else { if(intval(PAGINA)==0) { # backend $javascripts_required['scripts/jq'] = true; $pagina = layout('skins/backend/backend.html',0,0); } else if(modulo_attivo('cms') & TIPO_PAGINA=='pagina_home') { # home $pagina = layout('skins/'.SKIN.'/home.html',0,0); } else if(modulo_attivo('cms')){ # pagina $tmp = @reset(callMethod('oggetto','up',PAGINA,0)); define('PARENT', $tmp['id_oggetto']); $pagina = layout('skins/'.SKIN.'/index.html',0,0); } } $sezioni = $layout->trova_sezioni($pagina); /* ****************************************************************************************************************************************************/ // SE BACKEND //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// if(TIPO_PAGINA=='backend') { #$javascripts_required['scripts/swfobject'] = true; $javascripts_required['scripts/jq.tools'] = true; $javascripts_required['scripts/jq.fancybox'] = true; $javascripts_required['scripts/jq.prettyphoto'] = true; $javascripts_required['scripts/jq.jdropdown'] = true; #$javascripts_required['scripts/preloadify'] = true; #$javascripts_required['scripts/jq.prettyloader'] = true; $javascripts_required['scripts/frontend'] = true; $css_required['scripts/jq.tools'] = true; $css_required['scripts/jq.fancybox'] = true; $css_required['scripts/jq.prettyphoto'] = true; #$css_required['scripts/jq.prettyloader'] = true; include_once('skins/backend/testi_'.LANGUAGE.'.php'); if(posso('backend')){ #unset($css_required['scripts/jq.fancybox']); #unset($javascripts_required['scripts/jq.fancybox']); #$javascripts_required['scripts/jq.fancybox2'] = true; $javascripts_required['scripts/jq.menu'] = true; $javascripts_required['scripts/jq.smartsuggest'] = true; $javascripts_required['scripts/i18n/'.LANGUAGE] = true; $javascripts_required['scripts/plupload/plupload.full'] = true; $javascripts_required['scripts/jq.prettyphoto'] = true; $javascripts_required['scripts/jq.prettyloader'] = true; $javascripts_required['scripts/jq.ui'] = true; $javascripts_required['scripts/jq.imgareaselect'] = true; $javascripts_required['scripts/growl'] = true; $javascripts_required['scripts/tiny_mce/jquery.tinymce'] = true; #$css_required['scripts/jq.fancybox2'] = true; $css_required['scripts/jq.menu'] = true; $css_required['scripts/jq.smartsuggest'] = true; $css_required['scripts/jq.tools'] = true; $css_required['scripts/jq.prettyphoto'] = true; $css_required['scripts/jq.prettyloader'] = true; $css_required['scripts/jq.imgareaselect'] = true; $css_required['scripts/growl'] = true; if(ABS_PATH != BASE_PATH){ header("location:".ABS_PATH.'?'.$_SERVER['QUERY_STRING']); } } else { header('location:'.$seo->permaLink('?p=login')); } call('base.out.css'); call('base.out.js'); $pagina = str_replace('','',$pagina); $pagina = explode('!% contenuti %!',$pagina); if(file_exists('--application/backend/admin/'.trim(PAGINA).'.php')){ echo $pagina[0]; include('--application/backend/admin/'.trim(PAGINA).'.php'); echo $pagina[1]; } else { header('location:'.$seo->permaLink('?p=login')); } } /* ****************************************************************************************************************************************************/ // SE FRONTEND o RISERVATO //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// else if(intval(PAGINA)>0 | in_array(PAGINA,array_keys($seo_riservate))){ call('base.out.css'); call('base.out.js'); if(modulo_attivo('seo')){ $pagina = $seo->sostituisci_links($pagina); } $pagina = str_replace('','',$pagina); echo $pagina; } /* ****************************************************************************************************************************************************/ // Fine //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// mysql_close($connessione); /* ****************************************************************************************************************************************************/ //echo '
'.(array_sum(explode(' ', microtime()))-START); ?>