/[corp_html]/results.php
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Diff of /results.php

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.4 by dpavlin, Sat Mar 3 12:56:33 2001 UTC revision 1.11 by dpavlin, Fri Oct 12 07:39:37 2001 UTC
# Line 1  Line 1 
1  <?php  <?php
2  require("Smarty.class.php");  require("Smarty.class.php");
 require("conn.inc");  
3    
4  $smarty = new Smarty;  $smarty = new Smarty;
5    
6  $smarty->assign( array ( Title=>"Pliva d.d." ) );  $smarty->assign( array ( Title=>"Pliva d.d." ) );
7    
8  $section="investor";  if (isset($from)) {
9            $section=$from;
10    } else {
11            $section="investor";
12    }
13    
14  $title="INVESTOR'S PAGE";  require("conn.inc");
15  if ($menu_item) $title.=" : $menu_item";  include("section.inc");
16  $lpic="investor"; $lext=".jpg";  
17  $mpic="investors.gif";  if (! $type) $type="r";
18    
19    $sql="select id,town_date,title,body,pdf from news where type='$type' and $visible_is_true order by priority desc,date desc";
20    #       print "$sql";
21    $sth = $dbh->prepare("$sql");
22    $sth->execute();
23    while ($row=$sth->fetchrow_hash()) {
24            $results[]=$row;
25    }
26    
27  if ($part && file_exists("templates/$part.tpl")) {  if ($type == "p") {
28          $main_file=$part;          $main_file="presentations";
29    } elseif ($type == "o") {
30            $main_file="comp_profile";
31  } else {  } else {
32          $main_file="results";          $main_file="results";
33  }  }
34    
35  $smarty->assign( array ( lpic=>$lpic, lext=>$lext, mpic=>$mpic, Section_title=>$title ) );  $smarty->assign(array(
36            results=>$results,
37          $sql="select id,title,pdf from news where type='r' and visible order by priority desc,date desc";          type=>$type
38  #       print "$sql";          ));
         $sth = $dbh->prepare("$sql");  
         $sth->execute();  
         while ($row=$sth->fetchrow_hash()) {  
                 $results[]=$row;  
         }  
         $smarty->assign("results",$results);  
39    
40  $main=$smarty->fetch("$main_file.tpl");  $main=$smarty->fetch("$main_file.tpl");
41    
42  include("common.inc");  include("common.inc");
43    
44    $smarty->assign( array ( lpic=>$lpic, lext=>$lext, mpic=>$mpic, Section_title=>$title ) );
45    
46  $smarty->assign( array(back_url=>"$section.php", MAIN=>$main));  $smarty->assign( array(back_url=>"$section.php", MAIN=>$main));
47    
48  $smarty->display("index.tpl");  $smarty->display("index.tpl");

Legend:
Removed from v.1.4  
changed lines
  Added in v.1.11

  ViewVC Help
Powered by ViewVC 1.1.26