Не моё)

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
if (fileSelectorHistory.length > 0){
html += '<div class="backlink"><a class="arrow_link" id="file_selector_backline" href="#" data-type="'+Type+'">&larr; <span>Назад</span></a></div>'
}
html += '<div class="busi_switcher">'
html += '<table width="100%">'
html += ' <tr>'
if (Lt == '1'){
html += '<td><span class="active_item">папки</span></td>'
html += '<td><a href="#" class="list_type_selector" data-lt="2" data-type="'+Type+'">все файлы</a></td>'
}else{
html += '<td><a href="#" class="list_type_selector" data-lt="1" data-type="'+Type+'">папки</a></td>'
html += '<td><span class="active_item">все файлы</span></td>'
}
html += ' </tr>'
html += '</table>'
html += '</div>'
for (var i=0; i < dirsLength; i++ ){
html += '<a href="#" data-dir="'+dirs[i].nid+'" data-p="'+P+'" data-type="'+Type+'" data-lt="'+Lt+'" class="select_dir no_ajax t-block_item t-padd_right light_border_bottom t-bg3 t-link_no_underline_block">'
html += ' <span class="t-block_item stnd_padd t-bg_arrow_next">'
html += ' <img src="http://spaces.ru/i/'
if (dirs[i].icon == '4'){
html += 'folder_locked.gif'
}else if (dirs[i].icon == '5'){
if (dirs[i].type == '1'){
html += 'film.gif'
}else if (dirs[i].type == '2'){
html += 'file_mp3.gif'
}else if (dirs[i].type == '3'){
html += 'PhotoIcon.gif'
}
}else if (dirs[i].access_settings.mode == '2'){
html += 'folder.gif'
}else if (dirs[i].access_settings.mode == '1'){
html += 'folder_locked.gif'
}else if (dirs[i].access_settings.mode == '8'){
html += 'folder_password.gif'
}else{
html += 'folder_user.gif'
}
html += '" alt="" class="icon icon_align" />'
html += ' <span class="m t-strong_item t-link_item_hover">'+dirs[i].name+'</span>'
html += ' <small class="m">('+dirs[i].count+')</small>'
html += ' </span>'
html += '</a>'
}