@Ghazascanner
_2019runbot
Ghazascanner File Manager
server :Linux phosweb009 3.10.0-1160.el7.x86_64 #1 SMP Mon Oct 19 16:18:59 UTC 2020 x86_64
Current Path :
/
homepage
/
v-mt
/
tmpl
/
cms
/
include
/
Path :
Upload File :
New :
File
Dir
//homepage/v-mt/tmpl/cms/include/asset_upload.tmpl
<script type="text/javascript"> <!-- function setExtraPath(sel) { var opt = sel.options[sel.selectedIndex]; var path = opt.getAttribute("middle_path"); if (!path) path = ''; var middle = sel.form['middle_path']; if (middle) middle.value = path; } //--> </script> <mt:if name="missing_paths"> <mt:if name="have_permissions"> <p><__trans phrase="Before you can upload a file, you need to publish your blog. [_1]Configure your blog's publishing paths[_2] and rebuild your blog." params="<a href="javascript:void(0);" onclick="closeDialog('<mt:var name="script_url">?__mode=cfg_archives&blog_id=<mt:var name="blog_id">');">%%</a>"></p> <mt:else> <p><__trans phrase="Your system or blog administrator needs to publish the blog before you can upload files. Please contact your system or blog administrator."></p> </mt:if> <div class="actions-bar"> <div class="actions-bar-inner pkg actions"> <button onclick="closeDialog(); return false" type="submit" accesskey="x" title="<__trans phrase="Close (x)">" ><__trans phrase="Close"></button> </div> </div> <mt:else> <mt:if name="error"> <mtapp:statusmsg id="generic-error" class="error"> <mt:var name="error"> </mtapp:statusmsg> </mt:if> <form method="post" enctype="multipart/form-data" action="<mt:var name="script_url">" id="upload-form"> <input type="hidden" name="__mode" value="<mt:if name="upload_mode"><mt:var name="upload_mode" escape="html"><mt:else>upload_file</mt:if>" /> <input type="hidden" name="blog_id" value="<mt:var name="blog_id">" /> <input type="hidden" name="middle_path" value="<mt:var name="middle_path" escape="html">" /> <input type="hidden" name="entry_insert" value="<mt:var name="entry_insert">" /> <input type="hidden" name="asset_select" value="<mt:var name="asset_select">" /> <input type="hidden" name="edit_field" value="<mt:var name="edit_field">" /> <input type="hidden" name="require_type" value="<mt:var name="require_type">" /> <input type="hidden" name="magic_token" value="<mt:var name="magic_token">" /> <mt:if name="user_id"> <input type="hidden" name="user_id" value="<mt:var name="user_id">" /> </mt:if> <mtapp:setting id="file" label_class="top-label" label="<__trans phrase="Select File to Upload">" hint="" show_hint="0"> <input type="file" name="file" /> </mtapp:setting> <mt:if name="enable_destination"> <mt:setvarblock name="upload_hint"> <__trans phrase="_USAGE_UPLOAD" params="<$mt:var name="blog_name" escape="html"$>"> </mt:setvarblock> <mtapp:setting id="folder" label_class="top-label" label="<__trans phrase="Upload Destination">" hint="<$mt:var name="upload_hint"$>" show_hint="1"> <mt:var name="object_type" value="page"> <script type="text/javascript" src="<$mt:var name="static_uri"$>js/tc/client.js?v=<mt:var name="mt_version_id" escape="url">"></script> <script type="text/javascript"> /* <![CDATA[ */ MT.App.selectedCategoryList = []; MT.App.objectType = '<mt:var name="object_type" escape="js">'; App.singletonConstructor = MT.App = new Class( MT.App, { initComponents: function() { arguments.callee.applySuper( this, arguments ); this.categorySelector = this.addComponent( new this.constructor.CategorySelector( "folder-selector", "categorySelectorList" ) ); var cats = MT.App.categoryList; if ( cats ) { /* cache all the categories */ this.catCache = new Cache( cats.length + 50 ); for ( var i = 0; i < cats.length; i++ ) this.catCache.setItem( 'cat:'+cats[ i ].id, cats[ i ] ); } this.catList = { redraw: this.getIndirectMethod( "redrawFolderList" ) }; /* we don't need the modal mask here */ this.modalMask = { element: DOM.getElement( "folder-selector" ), show: Function.stub, hide: Function.stub }; this.form = DOM.getElement( "upload-form" ); }, redrawFolderList: function() { var item = this.catCache.getItem( "cat:" + MT.App.selectedCategoryList ); var path = []; var cat; for ( var i = 1, len = item.path.length; i < len; i++ ) { cat = this.catCache.getItem( "cat:" + item.path[ i ] ); if ( cat ) path.push( cat.basename ); } path.push( item.basename ); /* no leading slash */ path[ 0 ] = path[ 0 ].replace( /^\//, '' ); DOM.getElement( "extra_path" ).value = path.join( '' ); }, eventClick: function( event ) { var command = this.getMouseEventCommand( event ); switch( command ) { case "openFolderSelector": this.categorySelector.open( event.commandElement ); break; } return arguments.callee.applySuper( this, arguments ); } } ); /* ]]> */ </script> <!-- <$mt:var name="blog_url" escape="html"$> --> <select name="site_path" onchange="setExtraPath(this)"> <option value="1"><<__trans phrase="Site Root">></option> <mt:if name="enable_archive_paths"> <option value="0"<mt:if name="archive_path"> selected="selected"</mt:if>><<__trans phrase="Archive Root">></option> </mt:if> <mt:if name="extra_paths"> <mt:loop name="extra_paths"> <option value="<mt:if name="enable_archive_paths">0<mt:else>1</mt:if>" middle_path="<mt:var name="path" escape="html">"<mt:if name="selected"> selected="selected"</mt:if>><mt:var name="label" escape="html"></option> </mt:loop> </mt:if> </select> / <input name="extra_path" id="extra_path" value="<mt:var name="extra_path" escape="html">" /> <a href="javascript:void(0);" mt:command="open-folder-selector"><__trans phrase="Choose Folder"></a> </mtapp:setting> </mt:if> <div class="actions-bar"> <div class="actions-bar-inner pkg actions"> <button type="submit" accesskey="s" title="<__trans phrase="Upload (s)">" class="primary-button" ><__trans phrase="Upload"></button> <mt:if name="included_upload_asset"> <button onclick="toggleHidden('list-assets-dialog'); toggleHidden('upload-asset-dialog'); return false" type="submit" accesskey="b" title="<__trans phrase="Back (b)">" ><__trans phrase="Back"></button> </mt:if> <button onclick="closeDialog(); return false" type="submit" accesskey="x" title="<__trans phrase="Cancel (x)">" ><__trans phrase="Cancel"></button> </div> </div> </form> <mt:if name="enable_destination"> <$mt:var name="container_type" value="folder"$> <mt:include name="include/category_selector.tmpl"> </mt:if> </mt:if>