/[health_html]/inc/Smarty.local.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 /inc/Smarty.local.php

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

revision 1.2 by ravilov, Mon Sep 3 15:52:15 2001 UTC revision 1.3 by ravilov, Fri Oct 12 13:13:38 2001 UTC
# Line 15  function dir2path($dir) { Line 15  function dir2path($dir) {
15  function smarty_func_img() {  function smarty_func_img() {
16          extract(func_get_arg(0));          extract(func_get_arg(0));
17    
18          $f=Array();          $f = array();
19    
20          global $img_time;          global $img_time;
21          if (!isset($img_time)) {          if (!isset($img_time)) {
22                  $img_time=time();                  $img_time=time();
23          }          }
24                                    
   
25          if (isset($dir)) {          if (isset($dir)) {
26                  $tdir=dir2path($dir);                  $tdir=dir2path($dir);
27                  $h=opendir($dir);                  $h=opendir($dir);
# Line 143  function smarty_mod_filesize($file,$dir, Line 142  function smarty_mod_filesize($file,$dir,
142          }          }
143  }  }
144    
145    // pic_url|js_popup:"dir_reference"
146    
147    function smarty_mod_js_popup($pic, $dir) {
148            if ($dir) { global ${$dir}; $pic = ${$dir}."/".$pic; }
149            if ($pic) {
150                    @$size = GetImageSize($pic);
151                    list($w, $h) = array($size[0], $size[1]);
152            }
153            $opts = array("scrollbar=no", "menu=no", "personal=no");
154            // KLUDGY!!! I have to somehow include the window chrome (ie.
155            // decorations: titlebar, borders...) when calculating
156            /// width/height...
157            if ($w) array_push($opts, "width=".($w + 6));
158            if ($h) array_push($opts, "height=".($h + 25));
159            return "with (window.open(this.href, this.target, '".implode(',', $opts)."')) { }; return false;";
160    }
161    
162  // input functions (input, rinput)  // input functions (input, rinput)
163    
164  function smarty_func_input() {  function smarty_func_input() {

Legend:
Removed from v.1.2  
changed lines
  Added in v.1.3

  ViewVC Help
Powered by ViewVC 1.1.26