/[corp_html]/human_health.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 /human_health.php

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

revision 1.1 by dpavlin, Tue Feb 20 12:16:35 2001 UTC revision 1.4 by dpavlin, Mon Mar 5 13:03:45 2001 UTC
# Line 15  $back_url="products.php"; Line 15  $back_url="products.php";
15    
16  $smarty->assign( array ( lpic=>$lpic, lext=>$lext, mpic=>$mpic, Section_title=>$title ) );  $smarty->assign( array ( lpic=>$lpic, lext=>$lext, mpic=>$mpic, Section_title=>$title ) );
17    
18  $sth = $dbh->prepare("select distinct type from products");  $sth = $dbh->prepare("select type,description from prod_type");
19  $sth->execute();  $sth->execute();
20  $types[]="any";  $types[]="any";
21  while ($row=$sth->fetchrow_array()) {  while ($row=$sth->fetchrow_array()) {
22          $types[]=$row[0];          $types[]=$row[0];
23            $type_desc[]=$row[1];
24  }  }
25  $smarty->assign("types",$types);  $smarty->assign(array(
26            types=>$types,
27            type_desc=>$type_desc
28            ));
29    
30  $sql_where="";  $sql_where="";
31    
# Line 46  if ($sql_where != "") { Line 50  if ($sql_where != "") {
50    
51  if (isset($search)) {  if (isset($search)) {
52    
53          $sth = $dbh->prepare("select distinct brand,form,generic,description,type,atc,town,smpc,have_smpc from products $sql_where");          $sth = $dbh->prepare("select distinct brand,form,generic,description,type,atc,town,smpc,have_smpc from products $sql_where order by brand asc");
54          $sth->execute();          $sth->execute();
55          while ($row=$sth->fetchrow_hash()) {          while ($row=$sth->fetchrow_hash()) {
56                  $data[]=$row;                  $data[]=$row;
# Line 63  if (isset($search)) { Line 67  if (isset($search)) {
67          $smarty->assign("search","all");          $smarty->assign("search","all");
68  }  }
69    
70  $smarty->assign("type","$type");  $smarty->assign( array(type=>"$type",
71                    show_description=>$show_description
72            ));
73  $main=$smarty->fetch("human_health.tpl");  $main=$smarty->fetch("human_health.tpl");
74    
75  include("common.inc");  include("common.inc");

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

  ViewVC Help
Powered by ViewVC 1.1.26