Changeset 1156

Show
Ignore:
Timestamp:
06/15/07 15:53:34 (1 year ago)
Author:
icewing
Message:

Marcus Povey <marcus@dushka.co.uk>
* Returns url as part of returning the friendly identifier for an object.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • devel/mod/file/lib.php

    r1155 r1156  
    165165        $result = get_record_sql("select * from {$CFG->prefix}files where ident = $object_id"); 
    166166 
    167         return $result->originalname; 
     167        $filepath = $CFG->wwwroot . user_info("username", $result->owner) . "/files/{$result->folder}/{$result->ident}/" . urlencode($result->originalname); 
     168 
     169        return "<a href=\"$filepath\">" . $result->originalname . "</a>"; 
    168170} 
    169171