// NASTAVENI PROMENNYCH ABY SE NEMUSELO NASTAVOVAT GET A POST foreach ($_SERVER as $key => $value) $$key = $value; foreach ($_REQUEST as $key => $value) $$key = $value; include "db.php"; define ('VICE_JAZYKU', true); //nastavuju jeste v htaccess. kdyz bude TRUE adresa bude mit v url jazyk $nastavene_jazyky =array("cz"); // nastavuju jazyky pro tuto prezentaci if (!isset($jazyk)) $jazyk ="cz"; //nastavuju defaultni jazyk. Neni-li zadny zadan nastavi se tento // jestlize nekdo zkusi nastavit jiny jazyk nez je povolen, tak aby se to cely nepojebalo, nastavi se defaultni else if (!in_array($jazyk, $nastavene_jazyky)) $jazyk="cz"; // nastavuju DEFINE - data beru z databaze $query =MYSQL_QUERY("SELECT * FROM promenne_nazev n, promenne_$jazyk j WHERE n.id=j.produkt_id"); while ($var=MYSQL_FETCH_OBJECT($query)) { DEFINE ($var->nazev,$var->obsah); } // nastavuju titulek, klicova slova a description pro stranky $query =MYSQL_QUERY("SELECT * FROM nastaveni_projektu_$jazyk"); while ($loop=MYSQL_FETCH_OBJECT($query)) { $project_title = "$loop->title |"; $project_description = "$loop->description"; $project_keywords = "$loop->keywords"; } // echo getcwd(); // pro UPLOAD OBRAZKU V TINY - je to s lomitkem $root2 ="/users/zalohovane/beautiful-czech-women.com/firstclass-agency.cz"; //nastaveni data kvuli menu kde se porovnava expirace stranky $datum =Date("Y-m-d"); $trans = Array( 'á'=>'a', 'č'=>'c', 'ď'=>'d', 'd´'=>'d', 'ě'=>'e', 'é'=>'e', 'í'=>'i', 'ň'=>'n', 'ó'=>'o', 'ř'=>'r', 'š'=>'s', 'ť'=>'t', 't´'=>'t', 'ů'=>'u', 'ú'=>'u', 'ž'=>'z', 'ý'=>'y', ' '=>'-', 'Ú'=>'u', 'Ů'=>'u', 'Á'=>'a', 'Č'=>'c', 'Ď'=>'d', 'Ě'=>'e', 'É'=>'e', 'Í'=>'i', 'Ň'=>'n', 'Ó'=>'o', 'Ř'=>'r', 'Š'=>'s', 'Ť'=>'t', 'Ý'=>'y', 'Ž'=>'z', '('=>'', ')'=>'', '/'=>'-', '?'=>'', '&'=>'a', ); header('content-type: text/html;charset=utf-8'); /******************** NASTAVENI SEO - TITLE, KEYWORDS, DESCR. ***********************************/ /******************** NASTAVENI SEO - TITLE, KEYWORDS, DESCR. ***********************************/ // kdyz neni idsite - nastavuju default id a to id uvodni stranky if (!isset($idName)) $idName = "homepageDefault"; if (isset($idName)) { $query =MYSQL_QUERY("SELECT * FROM redakce_$jazyk WHERE sekce='$idName' LIMIT 1"); WHILE ($obsah=MYSQL_FETCH_OBJECT($query)) { if ($obsah->title!="") $title ="$obsah->title | "; else $title = $project_title; // nastaveno v connect if ($obsah->keywords!="") $keywords ="$obsah->keywords"; else $keywords = "$project_keywords" ;// nastaveno v connect if ($obsah->description!="") $description ="$obsah->description"; else $description = $project_description; // nastaveno v connect // plati pro vsechny krome homepage if ($idSite!=1) { if ($obsah->title=="") $title2 = $obsah->nadpis; } else $title2 = "";} } if (isset($idNameDva) && !isset($idNameTri)) { $query =MYSQL_QUERY("SELECT * FROM redakce_$jazyk WHERE sekce='$idNameDva' LIMIT 1"); WHILE ($obsah=MYSQL_FETCH_OBJECT($query)) { if ($obsah->title!="") $title ="$obsah->title | "; else $title = $project_title; // nastaveno v connect if ($obsah->keywords!="") $keywords ="$obsah->keywords"; else $keywords = "$project_keywords" ;// nastaveno v connect if ($obsah->description!="") $description ="$obsah->description"; else $description = $project_description; // nastaveno v connect // plati pro vsechny krome homepage if ($idSite!=1) { $title2 = $obsah->nadpis; } else $title2 = "";} } if (isset($idNameTri)) { $query =MYSQL_QUERY("SELECT * FROM redakce_$jazyk WHERE sekce='$idNameTri' LIMIT 1"); WHILE ($obsah=MYSQL_FETCH_OBJECT($query)) { if ($obsah->title!="") $title ="$obsah->title | "; else $title = $project_title; // nastaveno v connect if ($obsah->keywords!="") $keywords ="$obsah->keywords"; else $keywords = "$project_keywords" ;// nastaveno v connect if ($obsah->description!="") $description ="$obsah->description"; else $description = $project_description; // nastaveno v connect // plati pro vsechny krome homepage if ($idSite!=1) { $title2 = $obsah->nadpis; } else $title2 = "";} } /******************** end NASTAVENI SEO - TITLE, KEYWORDS, DESCR. ***********************************/ ?>
TOPlist