9 |
$section=str_replace(".php","",basename($PHP_SELF)); |
$section=str_replace(".php","",basename($PHP_SELF)); |
10 |
$smarty->assign("section",$section); |
$smarty->assign("section",$section); |
11 |
|
|
12 |
$main_file=$section; |
$title="ABOUT US"; |
13 |
|
$lpic="about"; $lext=".gif"; |
14 |
if ($section == "index") { |
$mpic="about.gif"; |
15 |
$title="HOME"; |
|
16 |
$lpic="obitelj"; $lext=".jpg"; |
$title.=" : About Us"; |
17 |
$tmp = time() % 3; |
|
18 |
$mpic="welcome_".($tmp+1).".gif"; |
$main_file="./html/AboutUs-"; |
19 |
$main_file="main"; |
if (file_exists($main_file.$part.".htm")) { |
20 |
} elseif ($section == "about") { |
$main_file.=$part.".htm"; |
21 |
$title="ABOUT US"; |
$main=join('',file($main_file)); |
22 |
$lpic="about"; $lext=".gif"; |
} elseif (file_exists("./templates/AboutUs-".$part.".tpl")) { |
23 |
$mpic="about.gif"; |
|
24 |
} elseif ($section == "products") { |
# $sth = $dbh->prepare("select iso,name from countries order by iso"); |
25 |
$title="PRODUCTS"; |
# $sth->execute(); |
26 |
$lpic="products"; $lext=".jpg"; |
# while ($row=$sth->fetchrow_hash()) { |
27 |
$mpic="products.gif"; |
# $countries[]=$row; |
28 |
} elseif ($section == "investor") { |
# } |
29 |
$title="INVESTOR'S PAGE"; |
# $smarty->assign("countries",$countries); |
30 |
$lpic="investor"; $lext=".jpg"; |
|
31 |
$mpic="investors.gif"; |
$main=$smarty->fetch("AboutUs-".$part.".tpl"); |
32 |
} elseif ($section == "rnd") { |
} else { |
33 |
$title="R&D"; |
$main_file.="Main.htm"; |
34 |
$lpic="rnd"; $lext=".gif"; |
$main=join('',file($main_file)); |
|
$tmp = time() % 2; |
|
|
$mpic="rnd_u".($tmp+1).".gif"; |
|
|
} elseif ($section == "careers") { |
|
|
$title="CAREERS"; |
|
|
$lpic="careers"; $lext=".jpg"; |
|
|
$mpic="careers.gif"; |
|
|
} elseif ($section == "contact") { |
|
|
$title="CONTACT US"; |
|
|
$lpic="cont"; $lext=".jpg"; |
|
|
$mpic="contactus.gif"; |
|
|
} elseif ($section == "coreval") { |
|
|
$title="CORE VALUES"; |
|
|
$lpic="about"; $lext=".gif"; |
|
|
$mpic="about.gif"; |
|
|
$section="about"; |
|
|
} elseif ($section == "vision") { |
|
|
$title="VISION"; |
|
|
$lpic="about"; $lext=".gif"; |
|
|
$mpic="about.gif"; |
|
|
$section="about"; |
|
35 |
} |
} |
36 |
|
|
37 |
|
|
38 |
$smarty->assign( array ( lpic=>$lpic, lext=>$lext, mpic=>$mpic, Section_title=>$title ) ); |
$smarty->assign( array ( lpic=>$lpic, lext=>$lext, mpic=>$mpic, Section_title=>$title ) ); |
39 |
|
|
40 |
include("common.inc"); |
include("common.inc"); |
|
|
|
|
$main=$smarty->fetch("$main_file.tpl"); |
|
41 |
$smarty->assign("MAIN",$main); |
$smarty->assign("MAIN",$main); |
42 |
|
|
|
$smarty->assign("debug",$PHP_SELF." -- ".basename($PHP_SELF)." -- $section --". |
|
|
$url[0]); |
|
|
|
|
|
|
|
43 |
$smarty->display("index.tpl"); |
$smarty->display("index.tpl"); |
44 |
?> |
?> |