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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
| <base target="_self">
<html>
<head>
<meta http-equiv="Content-Type" content="text-html; charset=windows-1251">
<meta http-equiv="Pragma" content="no-cache">
<meta http-equiv="Expires" content="-1">
<link href="style.css" rel="stylesheet" type="text/css">
<script type='text/javascript'>var sLang="ru-RU";document.write("<scr"+"ipt src='language/"+sLang+"/asset.js'></scr"+"ipt>");</script>
<script type='text/javascript'>writeTitle();</script>
<script type='text/javascript'>
var bReturnAbsolute=true;
var activeModalWin;
function getAction()
{
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
//Clean previous ffilter=...
sQueryString=window.location.search.substring(1);
//sQueryString=sQueryString.replace(/ffilter=media/,"");
//sQueryString=sQueryString.replace(/ffilter=image/,"");
//sQueryString=sQueryString.replace(/ffilter=office/,"");
//sQueryString=sQueryString.replace(/ffilter=text/,"");
//sQueryString=sQueryString.replace(/ffilter=archive/,"");
sQueryString=sQueryString.replace(/ffilter=\w*(&|$)/,"");
if(sQueryString.substring(sQueryString.length-1)=="&");
sQueryString=sQueryString.substring(0,sQueryString.length-1);
if(sQueryString.indexOf("=")==-1)
{//no querystring
sAction="assetmanager.php?ffilter="+document.getElementById("selFilter").value;
}
else
{
sAction="assetmanager.php?"+sQueryString+"&ffilter="+document.getElementById("selFilter").value;
}
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
return sAction;
}
function applyFilter()//ffilter
{
var Form1 = document.forms.Form1;
Form1.elements.inpCurrFolder.value=document.getElementById("selCurrFolder").value;
Form1.elements.inpFileToDelete.value="";
Form1.action=getAction();
Form1.submit();
}
function refreshAfterDelete(sDestination)
{
var Form1 = document.forms.Form1;
Form1.elements.inpCurrFolder.value=sDestination;
Form1.elements.inpFileToDelete.value="";
Form1.action=getAction();
Form1.submit();
}
function changeFolder()
{
var Form1 = document.forms.Form1;
Form1.elements.inpCurrFolder.value=document.getElementById("selCurrFolder").value;
Form1.elements.inpFileToDelete.value="";
Form1.action=getAction();
Form1.submit();
}
function upload()
{
var Form2 = document.forms.Form2;
if(Form2.elements.File1.value == "")return;
var sFile=Form2.elements.File1.value.substring(Form2.elements.File1.value.lastIndexOf("\\")+1);
for(var i=0;i<document.getElementById("inpNumOfFiles").value;i++)
{
if(sFile==document.getElementById("idFile"+(i*1+1)).innerHTML)
{
if(confirm(getTxt("File already exists. Do you want to replace it?"))!=true)return;
}
}
Form2.elements.inpCurrFolder2.value=document.getElementById("selCurrFolder").value;
document.getElementById("idUploadStatus").innerHTML=getTxt("Uploading...");
Form2.action=getAction();
Form2.submit();
}
function modalDialogShow(url,width,height)//moz
{
var left = screen.availWidth/2 - width/2;
var top = screen.availHeight/2 - height/2;
var activeModalWin = window.open(url, "", "width="+width+"px,height="+height+",left="+left+",top="+top);
window.onfocus = function(){if (activeModalWin.closed == false){activeModalWin.focus();};};
}
function newFolder()
{
if(navigator.appName.indexOf('Microsoft')!=-1)
window.showModalDialog("foldernew.php",window,"dialogWidth:250px;dialogHeight:192px;edge:Raised;center:Yes;help:No;resizable:No;");
else
modalDialogShow("foldernew.php", 270, 150);
}
function deleteFolder()
{
var selCurrFolder = document.getElementById("selCurrFolder");
if(selCurrFolder.value.toLowerCase()=='/var/www/html/files/htdocs/2128/user') {window.alert(getTxt('Cannot delete Asset Base Folder.')); return false;} if(navigator.appName.indexOf('Microsoft')!=-1)
window.showModalDialog("folderdel.php",window,"dialogWidth:250px;dialogHeight:192px;edge:Raised;center:Yes;help:No;resizable:No;");
else
modalDialogShow("folderdel.php", 250, 150);
}
function downloadFile(index)
{
sFile_RelativePath = document.getElementById("inpFile"+index).value;
window.location='download.php?file='+sFile_RelativePath;
}
function selectFile(index) {
sFile_RelativePath = document.getElementById("inpFile"+index).value;
if(bReturnAbsolute) sFile_RelativePath = 'http://files.mirsudrf.ru/2128' + sFile_RelativePath;
document.getElementById("inpSource").value=sFile_RelativePath;
var arrTmp = sFile_RelativePath.split(".");
var sFile_Extension = arrTmp[arrTmp.length-1];
var sHTML="";
//Image
if(sFile_Extension.toUpperCase()=="GIF" || sFile_Extension.toUpperCase()=="JPG" || sFile_Extension.toUpperCase()=="PNG" || sFile_Extension.toUpperCase()=="BMP") sHTML = "<img src=\"" + sFile_RelativePath + "\">";
//SWF
else if(sFile_Extension.toUpperCase()=="SWF") {
sHTML = "<object "+
"classid='clsid:D27CDB6E-AE6D-11cf-96B8-444553540000' " +
"width='100%' "+
"height='100%' " +
"codebase='http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9.0.28.0'>"+
" <param name=movie value='"+sFile_RelativePath+"'>" +
" <param name=quality value='high'>" +
" <embed src='"+sFile_RelativePath+"' " +
" width='100%' " +
" height='100%' " +
" quality='high' " +
" pluginspage='http://get.adobe.com/flashplayer/'>" +
" </embed>"+
"</object>";
}
/*
//Video
else if(sFile_Extension.toUpperCase()=="WMV"||sFile_Extension.toUpperCase()=="AVI"||sFile_Extension.toUpperCase()=="MPG") sHTML = "<embed src='"+sFile_RelativePath+"' hidden=false autostart='true' type='video/avi' loop='true'></embed>";
//Sound
else if(sFile_Extension.toUpperCase()=="WMA"||sFile_Extension.toUpperCase()=="WAV" || sFile_Extension.toUpperCase()=="MID" || sFile_Extension.toUpperCase()=="MP3") sHTML = "<embed src='"+sFile_RelativePath+"' hidden=false autostart='true' type='audio/wav' loop='true'></embed>";
*/
//Files (Hyperlinks)
else sHTML = "<br><br><br><br><br><br>Предварительный просмотр<br>для данного типа файлов не доступен.";
document.getElementById("idPreview").innerHTML = sHTML;
}
function deleteFile(index) {
sFile_RelativePath = document.getElementById("inpFile"+index).value;
var Form1 = document.getElementById("Form1");
Form1.elements.inpCurrFolder.value=document.getElementById("selCurrFolder").value;
Form1.elements.inpFileToDelete.value=sFile_RelativePath;
Form1.action=getAction();
Form1.submit();
}
bOk=false;
function doOk() {
if(navigator.appName.indexOf('Microsoft')!=-1) window.returnValue=inpSource.value;
else window.opener.setAssetValue(document.getElementById("inpSource").value);
bOk=true;
self.close();
}
function doUnload() {
if(navigator.appName.indexOf('Microsoft')!=-1) if(!bOk)window.returnValue="";
else if(!bOk)window.opener.setAssetValue("");
}
</script>
</head>
<body onunload="doUnload()" onload="loadTxt();this.focus();if(document.getElementById('inpUploadedFile').value!='')selectFile(document.getElementById('inpUploadedFile').value);" style="overflow:hidden;margin:0px;">
<table width="100%" height="100%" align=center style="" cellpadding=0 cellspacing=0 border=0 >
<tr>
<td valign=top style="background:url('bg.gif') no-repeat right bottom;padding-top:5px;padding-left:5px;padding-right:5px;padding-bottom:0px;">
<!--ffilter-->
<form method='post' name="Form1" id="Form1">
<input type="hidden" name="inpFileToDelete">
<input type="hidden" name="inpCurrFolder">
</form>
<table width="100%" border="0">
<tr>
<td>
<table width="100%" cellpadding="2" cellspacing="2" border="0">
<tr>
<td valign=center nowrap><select name='selCurrFolder' id='selCurrFolder' onchange='changeFolder()' class='inpSel'><option value='/var/www/html/files/htdocs/2128/user'>Files</option><option value='/var/www/html/files/htdocs/2128/user/Normativka'>Files/Normativka</option><option value='/var/www/html/files/htdocs/2128/user/Spisok_del_krassmotreniyu' selected>Files/Spisok_del_krassmotreniyu</option><option value='/var/www/html/files/htdocs/2128/user/Rezultat_rassmotreniya'>Files/Rezultat_rassmotreniya</option></select> </td>
<td nowrap>
<span onclick="newFolder()" style="cursor:pointer;"><u><span name="txtLang" id="txtLang">New Folder</span></u></span>
<span onclick="deleteFolder()" style="cursor:pointer;"><u><span name="txtLang" id="txtLang">Del Folder</span></u></span>
</td>
<td width="100%" align="right">
<select name=selFilter id=selFilter onchange='applyFilter()' class='inpSel'><option name='optLang' id='optLang' value='' selected>all_files</option><option name='optLang' id='optLang' value='archive' >archive</option><option name='optLang' id='optLang' value='flash' >flash</option><option name='optLang' id='optLang' value='image' >image</option><option name='optLang' id='optLang' value='media' >media</option><option name='optLang' id='optLang' value='office' >office</option><option name='optLang' id='optLang' value='text' >text</option></select> </td>
</tr>
</table>
</td>
</tr>
<tr>
<td valign=top align="center">
<table width=100% cellpadding=0 cellspacing=0>
<tr>
<td>
<div id="idPreview" style="text-align:center;overflow:auto;width:297px;height:245px;border:#d7d7d7 1px solid;background:#ffffff;margin-right:2px;"></div>
<div align=center><input type="text" id="inpSource" name="inpSource" style="border:#cfcfcf 1px solid;width:297px;margin-right:2px;margin-top:2px;" class="inpTxt"></div>
</td>
<td valign=top width=100%>
<div style='overflow:auto;height:240px;width:100%;margin-top:3px;margin-bottom:2px;'><table border=0 cellpadding=2 cellspacing=0 width=100% height=100% ><tr style='background:#EFEFF5;'><td><img src='images/ico_doc.gif'></td><td valign=top width=100% ><u id="idFile1" style='cursor:pointer;' onclick="selectFile(1)" title="s_03.05._po_06.05.2011_g._spisok_del.doc">s_03.05._po_06.05.20...</u> <img style='cursor:pointer;' onclick="downloadFile(1)" src='download.gif' title='Сохранить как...' alt=''></td><input type=hidden name=inpFile1 id=inpFile1 value="/user/Spisok_del_krassmotreniyu/s_03.05._po_06.05.2011_g._spisok_del.doc"><td valign=top align=right nowrap>40.5 КБ </td><td valign=top nowrap onclick="if(window.confirm('Вы действительно хотите удалить файл «s_03.05._po_06.05.2011_g._spisok_del.doc»?')) deleteFile(1);"><u style='font-size:10px;cursor:pointer;color:crimson'><script>document.write(getTxt('del'))</script></u></td></tr><tr style='background:;'><td><img src='images/ico_doc.gif'></td><td valign=top width=100% ><u id="idFile2" style='cursor:pointer;' onclick="selectFile(2)" title="s_10.05._po_13.05.2011_g._spisok_del.doc">s_10.05._po_13.05.20...</u> <img style='cursor:pointer;' onclick="downloadFile(2)" src='download.gif' title='Сохранить как...' alt=''></td><input type=hidden name=inpFile2 id=inpFile2 value="/user/Spisok_del_krassmotreniyu/s_10.05._po_13.05.2011_g._spisok_del.doc"><td valign=top align=right nowrap>44 КБ </td><td valign=top nowrap onclick="if(window.confirm('Вы действительно хотите удалить файл «s_10.05._po_13.05.2011_g._spisok_del.doc»?')) deleteFile(2);"><u style='font-size:10px;cursor:pointer;color:crimson'><script>document.write(getTxt('del'))</script></u></td></tr><tr style='background:#EFEFF5;'><td><img src='images/ico_doc.gif'></td><td valign=top width=100% ><u id="idFile3" style='cursor:pointer;' onclick="selectFile(3)" title="s_16.05._po_20.05.2011_g._spisok_del.doc">s_16.05._po_20.05.20...</u> <img style='cursor:pointer;' onclick="downloadFile(3)" src='download.gif' title='Сохранить как...' alt=''></td><input type=hidden name=inpFile3 id=inpFile3 value="/user/Spisok_del_krassmotreniyu/s_16.05._po_20.05.2011_g._spisok_del.doc"><td valign=top align=right nowrap>68 КБ </td><td valign=top nowrap onclick="if(window.confirm('Вы действительно хотите удалить файл «s_16.05._po_20.05.2011_g._spisok_del.doc»?')) deleteFile(3);"><u style='font-size:10px;cursor:pointer;color:crimson'><script>document.write(getTxt('del'))</script></u></td></tr><tr style='background:;'><td><img src='images/ico_doc.gif'></td><td valign=top width=100% ><u id="idFile4" style='cursor:pointer;' onclick="selectFile(4)" title="s_18.04._po_22.04.2011_g._spisok_del.doc">s_18.04._po_22.04.20...</u> <img style='cursor:pointer;' onclick="downloadFile(4)" src='download.gif' title='Сохранить как...' alt=''></td><input type=hidden name=inpFile4 id=inpFile4 value="/user/Spisok_del_krassmotreniyu/s_18.04._po_22.04.2011_g._spisok_del.doc"><td valign=top align=right nowrap>67 КБ </td><td valign=top nowrap onclick="if(window.confirm('Вы действительно хотите удалить файл «s_18.04._po_22.04.2011_g._spisok_del.doc»?')) deleteFile(4);"><u style='font-size:10px;cursor:pointer;color:crimson'><script>document.write(getTxt('del'))</script></u></td></tr><tr style='background:#EFEFF5;'><td><img src='images/ico_doc.gif'></td><td valign=top width=100% ><u id="idFile5" style='cursor:pointer;' onclick="selectFile(5)" title="s_23.05._po_27.05.2011_g._spisok_del.doc">s_23.05._po_27.05.20...</u> <img style='cursor:pointer;' onclick="downloadFile(5)" src='download.gif' title='Сохранить как...' alt=''></td><input type=hidden name=inpFile5 id=inpFile5 value="/user/Spisok_del_krassmotreniyu/s_23.05._po_27.05.2011_g._spisok_del.doc"><td valign=top align=right nowrap>60 КБ </td><td valign=top nowrap onclick="if(window.confirm('Вы действительно хотите удалить файл «s_23.05._po_27.05.2011_g._spisok_del.doc»?')) deleteFile(5);"><u style='font-size:10px;cursor:pointer;color:crimson'><script>document.write(getTxt('del'))</script></u></td></tr><tr style='background:;'><td><img src='images/ico_doc.gif'></td><td valign=top width=100% ><u id="idFile6" style='cursor:pointer;' onclick="selectFile(6)" title="s_25.04._po_29.04.2011_g._spisok_del.doc">s_25.04._po_29.04.20...</u> <img style='cursor:pointer;' onclick="downloadFile(6)" src='download.gif' title='Сохранить как...' alt=''></td><input type=hidden name=inpFile6 id=inpFile6 value="/user/Spisok_del_krassmotreniyu/s_25.04._po_29.04.2011_g._spisok_del.doc"><td valign=top align=right nowrap>55.5 КБ </td><td valign=top nowrap onclick="if(window.confirm('Вы действительно хотите удалить файл «s_25.04._po_29.04.2011_g._spisok_del.doc»?')) deleteFile(6);"><u style='font-size:10px;cursor:pointer;color:crimson'><script>document.write(getTxt('del'))</script></u></td></tr><tr><td colspan=4 height=100% ></td></tr></table></div><input type='hidden' name='inpUploadedFile' id='inpUploadedFile' value=''><input type='hidden' name='inpNumOfFiles' id='inpNumOfFiles' value='6'> </td>
</tr>
</table>
</td>
</tr>
<tr>
<td>
<div>
<div style="height:12">
<font color=red></font>
<span style="font-weight:bold" id=idUploadStatus></span>
</div>
<form enctype="multipart/form-data" method="post" runat="server" name="Form2" id="Form2">
<input type="hidden" name="inpCurrFolder2" ID="inpCurrFolder2">
<!--ffilter-->
<input type="hidden" name="inpFilter" ID="inpFilter" value="">
<span name="txtLang" id="txtLang">Upload File</span>: <input type="file" id="File1" name="File1" class="inpTxt" size='50'>
<input name="btnUpload" id="btnUpload" type="button" value="upload" onclick="upload()" class="inpBtn" onmouseover="this.className='inpBtnOver';" onmouseout="this.className='inpBtnOut'">
</form>
</div>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td class="dialogFooter" style="height:40px;padding-right:15px;" align=right valign=middle>
<table cellpadding=0 cellspacing=0 ID="Table2">
<tr>
<td>
<input name="btnOk" id="btnOk" type="button" value=" ok " onclick="doOk()" class="inpBtn" onmouseover="this.className='inpBtnOver';" onmouseout="this.className='inpBtnOut'">
</td>
</tr>
</table>
</td>
</tr>
</table>
</body>
</html> |