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

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

revision 1.8 by dpavlin, Fri Aug 4 10:20:22 2000 UTC revision 1.9 by dpavlin, Fri Aug 4 10:43:23 2000 UTC
# Line 65  IMPORTANT INSTALLATION NOTE: Line 65  IMPORTANT INSTALLATION NOTE:
65  TODO:  TODO:
66          mixed file/directory output (add type to each entry,          mixed file/directory output (add type to each entry,
67                  real support for links)                  real support for links)
68          add more content-management (like cms.sourceforge.net):          retrieve old versions of files (overwritten)
                 check-out/check-in/reserve  
                 comments to files  
69  */  */
70    
71  //////////////////////////////////////////////////////////////////  //////////////////////////////////////////////////////////////////
# Line 194  function EndHTML() { Line 192  function EndHTML() {
192  </small>  </small>
193  </P>  </P>
194  <BR>  <BR>
195  <? include(".debug.inc") ?>  <? //include(".debug.inc") ?>
196  <BR><BR></BODY></HTML>  <BR><BR></BODY></HTML>
197    
198  <?php  <?php
# Line 294  echo($fstr) ; ?></TEXTAREA> Line 292  echo($fstr) ; ?></TEXTAREA>
292  </FORM>  </FORM>
293    
294  <?php  <?php
295          } else if ( strstr( join(" ",$gblImages), $ext ) ) {            }
296            if ( !$file_lock && strstr(join(" ",$gblImages),$ext) ) {  
297                  $info  = getimagesize($fsPath) ;                  $info  = getimagesize($fsPath) ;
298                  $tstr  = "<IMG SRC=\"". $relPath . "\" BORDER=0 " ;                  $tstr = "<IMG SRC=\"".urlpath($relPath)."\" BORDER=0 " ;
299                  $tstr .= $info[3] . " ALT=\"" . $fn . " - " ;                  $tstr .= $info[3] . " ALT=\"" . $fn . " - " ;
300                  $tstr .= (int)(($fsize+1023)/1024) . "Kb\">" ;                  $tstr .= (int)(($fsize+1023)/1024) . "Kb\">" ;
301                  echo htmlentities($tstr) . "<BR><BR>" . $tstr ;  //              echo htmlentities($tstr) . "<BR><BR>" . $tstr ;
302                    echo $tstr ;
303          }          }
304    
305  ?>  ?>
# Line 848  about file, as well as delete, rename an Line 848  about file, as well as delete, rename an
848   <INPUT TYPE="HIDDEN" NAME="POSTACTION" VALUE="CREATE">   <INPUT TYPE="HIDDEN" NAME="POSTACTION" VALUE="CREATE">
849   <INPUT TYPE="HIDDEN" NAME="DIR" VALUE="<?= $relDir ?>">   <INPUT TYPE="HIDDEN" NAME="DIR" VALUE="<?= $relDir ?>">
850   <INPUT TYPE="SUBMIT" VALUE="CREATE"></NOBR>   <INPUT TYPE="SUBMIT" VALUE="CREATE"></NOBR>
851   <NOBR>OR <A HREF="<?= $self   <NOBR>OR <A HREF="<?= $self ?>?A=U&D=<?= urlencode($relDir) ?>">UPLOAD</A> A FILE
         ?>?A=U&D=<?= urlencode($relDir) ?>">UPLOAD</A> A FILE  
852   </NOBR>   </NOBR>
853  </TD></TR>  </TD></TR>
854  </FORM>  </FORM>
# Line 1070  function Unlock($target) { Line 1069  function Unlock($target) {
1069    
1070  //////////////////////////////////////////////////////////////////  //////////////////////////////////////////////////////////////////
1071    
1072  function redir_to_url($url) {  function urlpath($url) {
1073          $url=urlencode(StripSlashes("$url"));          $url=urlencode(StripSlashes("$url"));
1074          $url=str_replace("%2F","/",$url);          $url=str_replace("%2F","/",$url);
1075          $url=str_replace("+","%20",$url);          $url=str_replace("+","%20",$url);
1076          Header("Location: $url");          return($url);
1077  }  }
1078    
1079  //////////////////////////////////////////////////////////////////  //////////////////////////////////////////////////////////////////
# Line 1342  function safe_rename($from,$to) { Line 1341  function safe_rename($from,$to) {
1341          case "Co" :          case "Co" :
1342                  // checkout                  // checkout
1343                  Lock("$gblFsRoot/$relDir/$F");                  Lock("$gblFsRoot/$relDir/$F");
1344                  redir_to_url("$relDir/$F");                  Header("Location: ".urlpath("$relDir/$F"));
1345                  exit;                  exit;
1346          case "Ci" :          case "Ci" :
1347                  // upload && update to $relDir                  // upload && update to $relDir
# Line 1356  function safe_rename($from,$to) { Line 1355  function safe_rename($from,$to) {
1355                  exit ;                  exit ;
1356          case "V" :          case "V" :
1357                  // view                  // view
1358                  Log("viewed");                  LogIt("$gblFsRoot/$relDir/$F","viewed");
1359                  redir_to_url("$relDir/$F");                  Header("Location: ".urlpath("$relDir/$F"));
1360                  exit;                  exit;
1361          }          }
1362    

Legend:
Removed from v.1.8  
changed lines
  Added in v.1.9

  ViewVC Help
Powered by ViewVC 1.1.26