04-04-2015
#exportable
function filelist $file=;
var $list =<xt:filelist sort_type="updated" sort_dir="desc" per_page="15" folder="/files/uploads/$idfile" template="[dau].file_name.[cuoi] (.file_size.)" filter="*.jar"/>
@batdau
assign $end=call strrpos $haystack=$list;$needle=[cuoi]; $offset=0
assign $start=call strrpos $haystack=$list;$needle=[dau]; $offset=0
var $getname = call substr $val=$list;$start=($start+5);$length=($end-$start-5);
var $tenfile2 = $getname
var $tenfile2 = call str_replace $subject=$tenfile2;$search=.jar;$replace=
var $tenfiles = call source $file=/files/uploads/$idfile/$tenfile2
var $lblog2 = $lblog
var $lblog2 = $lblog
assign $lblog2 = call base64_encode $val=$lblog2
var $getname2 = $getname
assign $getname2 = call base64_encode $val=$getname2
var $id2 = $id
assign $id2 = call base64_encode $val=$id2
var $list = call str_replace $subject=$list;$search=[dau]$getname[cuoi];$replace=</div><div class="list"><img src="/icon/down.png" alt="download" class="icon"/><a href ='/files/uploads/$idfile/$getname' title='$tenfiles' rel='nofollow'><font color="red"> $tenfiles</font></a>;
if $start > 25
goto @batdau
endif
If not $list
Else
print $list
Endif
endfunction
code này chỉ hỗ trợ up file jar giờ bác nào giúp e thêm các file khác vào như .apk.nth...vs
|
Out - Cấp bậc: |
04-04-2015
Káj này thêm phần tap tin đúg hok?
04-04-2015
nếu dùng xts cắt tên file thì có lẽ chỉ cần 1list thôi là đủ