// site exceptions: NONE //header specific production site session_start(); while(list($key,$value) = each($_GET)) { $$key = $value ; } include "cgi-bin/rad_appfunctions.php"; $domexist = nregistos(TB_MIC,'dominio','dominio',$curdomain); if ($domexist > 0) { $_SESSION["curdomain"] = $curdomain; }else{ Header("Location: ./manut.php"); // Redirect exit(); } // dominio existe include "cgi-bin/rad_functions.php"; $ligacao=mysql_connect(DB_SERVER, DB_USER, DB_PASSWORD); mysql_select_db(DB_NAME, $ligacao); $sql="SELECT * FROM ".TB_MIC." WHERE dominio='".$_SESSION["curdomain"]."'"; $resultado=mysql_query($sql,$ligacao); $registo=mysql_fetch_array($resultado); $_SESSION["siteid"] = $registo['id']; $id = $registo['id']; $dominio=$registo['dominio']; $site = $_SESSION["siteid"]; $ntvlang = tabvalor('nativelg',TB_CNF,'site_id',$site); include "cgi-bin/rad_translations_nv_inc.php"; //END header specific production site $vv = validhome($registo['home'],$site); if ($vv == NULL or $vv == '') { $home = "partcc"; }else{ $home=$registo['home']; } $css = $registo['css']; $cssp = csstogo($css); $denomina=$registo['denomina']; $contacts=$registo['contacts']; $back=$registo['back']; $urladd = tabvalor('conteudo',TB_ADM,'variavel','urladd'); // sec validations if (isset($sec) == false or $sec == NULL) { $sec = $home; }else{ $sec = $sec; } $fam=""; $cat=""; // page specific code // ****************** $banner = tabvalor('banner_txt',TB_MIC,'id',$site); $disclaimer = tabvalor('disclaimer',TB_MIC,'id',$site); $prd_navbox_title = tabvalor('prd_navbox_title',TB_MIC,'id',$site); $slideshow = tabvalor('slideshow',TB_CNF,'site_id',$site); $authtm = tabvalor('tm',TB_CNF,'site_id',$site); $lay_tophzbar = tabvalor('lay_tophzbar',TB_CNF,'site_id',$site); $map_zoom = tabvalor('map_zoom',TB_CNF,'site_id',$site); $map_lat = tabvalor('map_gpslat',TB_CNF,'site_id',$site); $map_long = tabvalor('map_gpslong',TB_CNF,'site_id',$site); $shop = tabvalor('shop_view',TB_CNF,'site_id',$site); $priv_active = tabvalor('priv_active',TB_CNF,'site_id',$site); $priv_label = tabvalor('priv_label',TB_CNF,'site_id',$site); $priv_view = tabvalor('priv_view',TB_CNF,'site_id',$site); $head_back_img = tabvalor('head_back_img',TB_CNF,'site_id',$site); $wallimg = ($head_back_img != '' ? 'background="anexos/'.$head_back_img.'"' : ''); $cgerais_label = tabvalor('shop_cgerais_label',TB_CNF,'site_id',$site); $cgerais_txt = tabvalor('shop_cgerais_txt',TB_CNF,'site_id',$site); $authsign = tabvalor('conteudo',TB_ADM,'variavel',$authtm); $priv_inc = 0; if ($priv_active > 0 AND $priv_view > 0) { $priv_inc = 1; } $lang_uk = tabvalor('lang_uk',TB_CNF,'site_id',$site); $lang_sp = tabvalor('lang_sp',TB_CNF,'site_id',$site); $lang_fr = tabvalor('lang_fr',TB_CNF,'site_id',$site); $navproduto = nregistossql("SELECT * FROM ".TB_PRODUCTS." WHERE private='0' AND visivel='1' AND site='$site'"); $destproduto = nregistossql("SELECT * FROM ".TB_PRODUCTS." WHERE private='0' AND destaque='1' AND visivel='1' AND site='$site'"); //itens if ($navproduto > 0) { $itens_nav=" ".$footer01." :: "; }else{ $itens_nav=""; } //cgerais if ($cgerais_txt !="" and $shop > 0) { $cgerais_nav=" ".$cgerais_label." :: "; }else{ $cgerais_nav=""; } //termos if ($disclaimer !="") { $disclaimer_nav=" ".$footer05." :: "; }else{ $disclaimer_nav=""; } //home rodapé $home_nav=" Home :: "; //contactos rodapé $cont_nav=" ".$footer02." :: "; //editores rodapé $edit_nav=" ".$footer04.""; $tp1_data=$registo['tp1_data']; $tp2_data=$registo['tp2_data']; $tp3_data=$registo['tp3_data']; $tp4_data=$registo['tp4_data']; $tp5_data=$registo['tp5_data']; $tp6_data=$registo['tp6_data']; $tp7_data=$registo['tp7_data']; $tp8_data=$registo['tp8_data']; $tp9_data=$registo['tp9_data']; $tp10_data=$registo['tp10_data']; $tp11_data=$registo['tp11_data']; $tp12_data=$registo['tp12_data']; $tp13_data=$registo['tp13_data']; $tp14_data=$registo['tp14_data']; if ($map_lat !="") { $mapa=""; } else { $mapa=""; } $com1=""; $com2=""; $com3=""; $com4=""; $com5=""; $com6=""; $com7=""; $com8=""; $com9=""; $com10=""; $com11=""; $com12=""; $com13=""; $com14=""; $comgal=""; $commul=""; $comserv=""; $comvis=""; $comcc=""; //navigation desktop if ($registo['tp1_title']!="") { if ($sec=="part1") { $com1="".$registo['tp1_title'].""; }else{ $com1="".$registo['tp1_title'].""; } } if ($registo['tp2_title']!="") { if ($sec=="part2") { $com2="".$registo['tp2_title'].""; }else{ $com2="".$registo['tp2_title'].""; } } if ($registo['tp3_title']!="") { if ($sec=="part3") { $com3="".$registo['tp3_title'].""; }else{ $com3="".$registo['tp3_title'].""; } } if ($registo['tp4_title']!="") { if ($sec=="part4") { $com4="".$registo['tp4_title'].""; }else{ $com4="".$registo['tp4_title'].""; } } if ($registo['tp5_title']!="") { if ($sec=="part5") { $com5="".$registo['tp5_title'].""; }else{ $com5="".$registo['tp5_title'].""; } } if ($registo['tp6_title']!="") { if ($sec=="part6") { $com6="".$registo['tp6_title'].""; }else{ $com6="".$registo['tp6_title'].""; } } if ($registo['tp7_title']!="") { if ($sec=="part7") { $com7="".$registo['tp7_title'].""; }else{ $com7="".$registo['tp7_title'].""; } } if ($registo['tp8_title']!="") { if ($sec=="part8") { $com8="".$registo['tp8_title'].""; }else{ $com8="".$registo['tp8_title'].""; } } if ($registo['tp9_title']!="") { if ($sec=="part9") { $com9="".$registo['tp9_title'].""; }else{ $com9="".$registo['tp9_title'].""; } } if ($registo['tp10_title']!="") { if ($sec=="part10") { $com10="".$registo['tp10_title'].""; }else{ $com10="".$registo['tp10_title'].""; } } if ($registo['tp11_title']!="") { if ($sec=="part11") { $com11="".$registo['tp11_title'].""; }else{ $com11="".$registo['tp11_title'].""; } } if ($registo['tp12_title']!="") { if ($sec=="part12") { $com12="".$registo['tp12_title'].""; }else{ $com12="".$registo['tp12_title'].""; } } if ($registo['tp13_title']!="") { if ($sec=="part13") { $com13="".$registo['tp13_title'].""; }else{ $com13="".$registo['tp13_title'].""; } } if ($registo['tp14_title']!="") { if ($sec=="part14") { $com14="".$registo['tp14_title'].""; }else{ $com14="".$registo['tp14_title'].""; } } // existe texto de contactos if ($registo['contacts']!="") { if ($sec=="partcc") { $comcc=" ".$registo['contactos_title'].""; }else{ $comcc=" ".$registo['contactos_title'].""; } } //navigation mobile if ($registo['tp1_title']!="") { $com1m="".$registo['tp1_title'].""; }else{ $com1m=""; } if ($registo['tp2_title']!="") { $com2m="".$registo['tp2_title'].""; }else{ $com2m=""; } if ($registo['tp3_title']!="") { $com3m="".$registo['tp3_title'].""; }else{ $com3m=""; } if ($registo['tp4_title']!="") { $com4m="".$registo['tp4_title'].""; }else{ $com4m=""; } if ($registo['tp5_title']!="") { $com5m="".$registo['tp5_title'].""; }else{ $com5m=""; } if ($registo['tp6_title']!="") { $com6m="".$registo['tp6_title'].""; }else{ $com6m=""; } if ($registo['tp7_title']!="") { $com7m="".$registo['tp7_title'].""; }else{ $com7m=""; } if ($registo['tp8_title']!="") { $com8m="".$registo['tp8_title'].""; }else{ $com8m=""; } if ($registo['tp9_title']!="") { $com9m="".$registo['tp9_title'].""; }else{ $com9m=""; } if ($registo['tp10_title']!="") { $com10m="".$registo['tp10_title'].""; }else{ $com10m=""; } if ($registo['tp11_title']!="") { $com11m="".$registo['tp11_title'].""; }else{ $com11m=""; } if ($registo['tp12_title']!="") { $com12m="".$registo['tp12_title'].""; }else{ $com12m=""; } if ($registo['tp13_title']!="") { $com13m="".$registo['tp13_title'].""; }else{ $com13m=""; } if ($registo['tp14_title']!="") { $com14m="".$registo['tp14_title'].""; }else{ $com14m=""; } // existe texto de contactos if ($registo['contacts']!="") { $comccm="".$registo['contactos_title'].""; }else{ $comccm=""; } //home page if ($sec!="") { $sec=$sec; }else{ $sec=$home; } //page constucter switch ($sec) { case "part1": if ($slideshow==0) { $imgtopox=($registo['imgtopo01'] != "" ? "images/deco/".$registo['imgtopo01'] : "images/deco/".$registo['imgtopo1']); } $titlemetatogo = ($registo['tp01_metatitle'] != '' ? $registo['tp01_metatitle'] : $denomina.' :: '.$registo['tp1_title']); $html=$tp1_data; break; case "part2": if ($slideshow==0) { $imgtopox=($registo['imgtopo02'] != "" ? "images/deco/".$registo['imgtopo02'] : "images/deco/".$registo['imgtopo1']); } $titlemetatogo = ($registo['tp02_metatitle'] != '' ? $registo['tp02_metatitle'] : $denomina.' :: '.$registo['tp2_title']); $html=$tp2_data; break; case "part3": if ($slideshow==0) { $imgtopox=($registo['imgtopo03'] != "" ? "images/deco/".$registo['imgtopo03'] : "images/deco/".$registo['imgtopo1']); } $titlemetatogo = ($registo['tp03_metatitle'] != '' ? $registo['tp03_metatitle'] : $denomina.' :: '.$registo['tp3_title']); $html=$tp3_data; break; case "part4": if ($slideshow==0) { $imgtopox=($registo['imgtopo04'] != "" ? "images/deco/".$registo['imgtopo04'] : "images/deco/".$registo['imgtopo1']); } $titlemetatogo = ($registo['tp04_metatitle'] != '' ? $registo['tp04_metatitle'] : $denomina.' :: '.$registo['tp4_title']); $html=$tp4_data; break; case "part5": if ($slideshow==0) { $imgtopox=($registo['imgtopo05'] != "" ? "images/deco/".$registo['imgtopo05'] : "images/deco/".$registo['imgtopo1']); } $titlemetatogo = ($registo['tp05_metatitle'] != '' ? $registo['tp05_metatitle'] : $denomina.' :: '.$registo['tp5_title']); $html=$tp5_data; break; case "part6": if ($slideshow==0) { $imgtopox=($registo['imgtopo06'] != "" ? "images/deco/".$registo['imgtopo06'] : "images/deco/".$registo['imgtopo1']); } $titlemetatogo = ($registo['tp06_metatitle'] != '' ? $registo['tp06_metatitle'] : $denomina.' :: '.$registo['tp6_title']); $html=$tp6_data; break; case "part7": if ($slideshow==0) { $imgtopox=($registo['imgtopo07'] != "" ? "images/deco/".$registo['imgtopo07'] : "images/deco/".$registo['imgtopo1']); } $titlemetatogo = ($registo['tp07_metatitle'] != '' ? $registo['tp07_metatitle'] : $denomina.' :: '.$registo['tp7_title']); $html=$tp7_data; break; case "part8": if ($slideshow==0) { $imgtopox=($registo['imgtopo08'] != "" ? "images/deco/".$registo['imgtopo08'] : "images/deco/".$registo['imgtopo1']); } $titlemetatogo = ($registo['tp08_metatitle'] != '' ? $registo['tp08_metatitle'] : $denomina.' :: '.$registo['tp8_title']); $html=$tp8_data; break; case "part9": if ($slideshow==0) { $imgtopox=($registo['imgtopo09'] != "" ? "images/deco/".$registo['imgtopo09'] : "images/deco/".$registo['imgtopo1']); } $titlemetatogo = ($registo['tp09_metatitle'] != '' ? $registo['tp09_metatitle'] : $denomina.' :: '.$registo['tp9_title']); $html=$tp9_data; break; case "part10": if ($slideshow==0) { $imgtopox=($registo['imgtopo10'] != "" ? "images/deco/".$registo['imgtopo10'] : "images/deco/".$registo['imgtopo1']); } $titlemetatogo = ($registo['tp010_metatitle'] != '' ? $registo['tp010_metatitle'] : $denomina.' :: '.$registo['tp10_title']); $html=$tp10_data; break; case "part11": if ($slideshow==0) { $imgtopox=($registo['imgtopo11'] != "" ? "images/deco/".$registo['imgtopo11'] : "images/deco/".$registo['imgtopo1']); } $titlemetatogo = ($registo['tp011_metatitle'] != '' ? $registo['tp011_metatitle'] : $denomina.' :: '.$registo['tp11_title']); $html=$tp11_data; break; case "part12": if ($slideshow==0) { $imgtopox=($registo['imgtopo12'] != "" ? "images/deco/".$registo['imgtopo12'] : "images/deco/".$registo['imgtopo1']); } $titlemetatogo = ($registo['tp012_metatitle'] != '' ? $registo['tp012_metatitle'] : $denomina.' :: '.$registo['tp12_title']); $html=$tp12_data; break; case "part13": if ($slideshow==0) { $imgtopox=($registo['imgtopo13'] != "" ? "images/deco/".$registo['imgtopo13'] : "images/deco/".$registo['imgtopo1']); } $titlemetatogo = ($registo['tp013_metatitle'] != '' ? $registo['tp013_metatitle'] : $denomina.' :: '.$registo['tp13_title']); $html=$tp13_data; break; case "part14": if ($slideshow==0) { $imgtopox=($registo['imgtopo14'] != "" ? "images/deco/".$registo['imgtopo14'] : "images/deco/".$registo['imgtopo1']); } $titlemetatogo = ($registo['tp014_metatitle'] != '' ? $registo['tp014_metatitle'] : $denomina.' :: '.$registo['tp14_title']); $html=$tp14_data; break; default: $imgtopox=($registo['imgtopo1'] != "" ? "images/deco/".$registo['imgtopo1'] : "images/deco/".$registo['imgtopo1']); $titlemetatogo = ($registo['cont_metatitle'] != '' ? $registo['cont_metatitle'] : $denomina.' :: '.$registo['contactos_title']); $html=$contacts.$mapa; } ?>