Nucleus CMS日本語版用プラグインのうち、日本語版開発者がサポートしているもの
Revision | a45b3f2f5bd5bee4c5bcc26622ddc6f987672830 (tree) |
---|---|
Time | 2011-10-09 18:19:00 |
Author | hsur <hsur@1ca2...> |
Commiter | hsur |
NP_DragAndDropUploader v1.2
git-svn-id: https://svn.sourceforge.jp/svnroot/nucleus-jp/plugin@1203 1ca29b6e-896d-4ea0-84a5-967f57386b96
@@ -2,12 +2,12 @@ | ||
2 | 2 | // vim: tabstop=2:shiftwidth=2 |
3 | 3 | |
4 | 4 | /** |
5 | - * NP_DragAndDropUploader ($Revision: 1.11 $) | |
5 | + * NP_DragAndDropUploader ($Revision: 1.12 $) | |
6 | 6 | * by hsur ( http://blog.cles.jp/np_cles ) |
7 | 7 | * |
8 | 8 | * Based on upload.php (http://www.plupload.com) |
9 | 9 | * |
10 | - * $Id: NP_DragAndDropUploader.php,v 1.11 2010/05/08 23:26:28 hsur Exp $ | |
10 | + * $Id: NP_DragAndDropUploader.php,v 1.12 2011/10/09 08:49:31 hsur Exp $ | |
11 | 11 | */ |
12 | 12 | |
13 | 13 | /* |
@@ -76,7 +76,7 @@ class NP_DragAndDropUploader extends NucleusPlugin { | ||
76 | 76 | |
77 | 77 | // version of the plugin |
78 | 78 | function getVersion() { |
79 | - return '1.1'; | |
79 | + return '1.2'; | |
80 | 80 | } |
81 | 81 | |
82 | 82 | function hasAdminArea() { |
@@ -153,7 +153,7 @@ class NP_DragAndDropUploader extends NucleusPlugin { | ||
153 | 153 | |
154 | 154 | // a description to be shown on the installed plugins listing |
155 | 155 | function getDescription() { |
156 | - return '[$Revision: 1.11 $]<br />' . NP_DRAGANDDROPUPLOADER_DESCRIPTION; | |
156 | + return '[$Revision: 1.12 $]<br />' . NP_DRAGANDDROPUPLOADER_DESCRIPTION; | |
157 | 157 | } |
158 | 158 | |
159 | 159 | function supportsFeature($what) { |
@@ -1,177 +0,0 @@ | ||
1 | -/* | |
2 | - Plupload | |
3 | -------------------------------------------------------------------- */ | |
4 | - | |
5 | -.plupload_button { | |
6 | - display: -moz-inline-box; /* FF < 3*/ | |
7 | - display: inline-block; | |
8 | - font: normal 12px sans-serif; | |
9 | - text-decoration: none; | |
10 | - color: #42454a; | |
11 | - border: 1px solid #bababa; | |
12 | - padding: 2px 8px 3px 20px; | |
13 | - margin-right: 4px; | |
14 | - background: #f3f3f3 url('../img/buttons.png') no-repeat 0 center; | |
15 | - outline: 0; | |
16 | - | |
17 | - /* Optional rounded corners for browsers that support it */ | |
18 | - -moz-border-radius: 3px; | |
19 | - -khtml-border-radius: 3px; | |
20 | - -webkit-border-radius: 3px; | |
21 | - border-radius: 3px; | |
22 | -} | |
23 | - | |
24 | -.plupload_button:hover { | |
25 | - color: #000; | |
26 | - text-decoration: none; | |
27 | -} | |
28 | - | |
29 | -.plupload_disabled, a.plupload_disabled:hover { | |
30 | - color: #737373; | |
31 | - border-color: #c5c5c5; | |
32 | - background: #ededed url('../img/buttons-disabled.png') no-repeat 0 center; | |
33 | - cursor: default; | |
34 | -} | |
35 | - | |
36 | -.plupload_add { | |
37 | - background-position: -181px center; | |
38 | -} | |
39 | - | |
40 | -.plupload_wrapper { | |
41 | - font: normal 11px Verdana,sans-serif; | |
42 | - width: 100%; | |
43 | -} | |
44 | - | |
45 | -.plupload_container { | |
46 | - padding: 8px; | |
47 | - background: url('../img/transp50.png'); | |
48 | - /*-moz-border-radius: 5px;*/ | |
49 | -} | |
50 | - | |
51 | -.plupload_container input { | |
52 | - border: 1px solid #DDD; | |
53 | - font: normal 11px Verdana,sans-serif; | |
54 | - width: 98%; | |
55 | -} | |
56 | - | |
57 | -.plupload_header {background: #2A2C2E url('../img/backgrounds.gif') repeat-x;} | |
58 | -.plupload_header_content { | |
59 | - background: url('../img/backgrounds.gif') no-repeat 0 -317px; | |
60 | - min-height: 56px; | |
61 | - padding-left: 60px; | |
62 | - color: #FFF; | |
63 | -} | |
64 | -.plupload_header_title { | |
65 | - font: normal 18px sans-serif; | |
66 | - padding: 6px 0 3px; | |
67 | -} | |
68 | -.plupload_header_text { | |
69 | - font: normal 12px sans-serif; | |
70 | -} | |
71 | - | |
72 | -.plupload_filelist { | |
73 | - margin: 0; | |
74 | - padding: 0; | |
75 | - list-style: none; | |
76 | -} | |
77 | - | |
78 | -.plupload_scroll .plupload_filelist { | |
79 | - height: 185px; | |
80 | - background: #F5F5F5; | |
81 | - overflow-y: scroll; | |
82 | -} | |
83 | - | |
84 | -.plupload_filelist li { | |
85 | - padding: 10px 8px; | |
86 | - background: #F5F5F5 url('../img/backgrounds.gif') repeat-x 0 -156px; | |
87 | - border-bottom: 1px solid #DDD; | |
88 | -} | |
89 | - | |
90 | -.plupload_filelist_header, .plupload_filelist_footer { | |
91 | - background: #DFDFDF; | |
92 | - padding: 8px 8px; | |
93 | - color: #42454A; | |
94 | -} | |
95 | -.plupload_filelist_header { | |
96 | - border-top: 1px solid #EEE; | |
97 | - border-bottom: 1px solid #CDCDCD; | |
98 | -} | |
99 | - | |
100 | -.plupload_filelist_footer {border-top: 1px solid #FFF; height: 22px; line-height: 20px; vertical-align: middle;} | |
101 | -.plupload_file_name {float: left; overflow: hidden} | |
102 | -.plupload_file_status {color: #777;} | |
103 | -.plupload_file_status span {color: #42454A;} | |
104 | -.plupload_file_size, .plupload_file_status, .plupload_progress { | |
105 | - float: right; | |
106 | - width: 80px; | |
107 | -} | |
108 | -.plupload_file_size, .plupload_file_status, .plupload_file_action {text-align: right;} | |
109 | - | |
110 | -.plupload_filelist .plupload_file_name {width: 205px} | |
111 | - | |
112 | -.plupload_file_action { | |
113 | - float: right; | |
114 | - width: 16px; | |
115 | - height: 16px; | |
116 | - margin-left: 15px; | |
117 | -} | |
118 | - | |
119 | -.plupload_file_action * { | |
120 | - display: none; | |
121 | - width: 16px; | |
122 | - height: 16px; | |
123 | -} | |
124 | - | |
125 | -li.plupload_uploading {background: #ECF3DC url('../img/backgrounds.gif') repeat-x 0 -238px;} | |
126 | -li.plupload_done {color:#AAA} | |
127 | - | |
128 | -li.plupload_delete a { | |
129 | - background: url('../img/delete.gif'); | |
130 | -} | |
131 | - | |
132 | -li.plupload_failed a { | |
133 | - background: url('../img/error.gif'); | |
134 | - cursor: default; | |
135 | -} | |
136 | - | |
137 | -li.plupload_done a { | |
138 | - background: url('../img/done.gif'); | |
139 | - cursor: default; | |
140 | -} | |
141 | - | |
142 | -.plupload_progress, .plupload_upload_status { | |
143 | - display: none; | |
144 | -} | |
145 | - | |
146 | -.plupload_progress_container { | |
147 | - margin-top: 3px; | |
148 | - border: 1px solid #CCC; | |
149 | - background: #FFF; | |
150 | - padding: 1px; | |
151 | -} | |
152 | -.plupload_progress_bar { | |
153 | - width: 0px; | |
154 | - height: 7px; | |
155 | - background: #CDEB8B; | |
156 | -} | |
157 | - | |
158 | -.plupload_scroll .plupload_filelist_header .plupload_file_action, .plupload_scroll .plupload_filelist_footer .plupload_file_action { | |
159 | - margin-right: 17px; | |
160 | -} | |
161 | - | |
162 | -/* Floats */ | |
163 | - | |
164 | -.plupload_clear,.plupload_clearer {clear: both;} | |
165 | -.plupload_clearer, .plupload_progress_bar { | |
166 | - display: block; | |
167 | - font-size: 0; | |
168 | - line-height: 0; | |
169 | -} | |
170 | - | |
171 | -li.plupload_droptext { | |
172 | - background: transparent; | |
173 | - text-align: center; | |
174 | - vertical-align: middle; | |
175 | - border: 0; | |
176 | - line-height: 165px; | |
177 | -} |
@@ -1,15 +1,18 @@ | ||
1 | -<!-- $Id: help.html,v 1.5 2010/05/08 23:31:51 hsur Exp $ --> | |
1 | +<!-- $Id: help.html,v 1.6 2011/10/09 09:15:41 hsur Exp $ --> | |
2 | 2 | <h3>バージョン履歴</h3> |
3 | 3 | |
4 | 4 | <ul> |
5 | 5 | <li>Version 1.0b: (2010/04/25)</li> |
6 | 6 | <li> [New] 初版公開</li> |
7 | - <li> [Fixed] Nucleus v3.41でファイルがアップロード出来ないバグを修正 (Thanks 桜枝さん, 1.0.1b)</a> | |
8 | - <li> [Fixed] ファイルがアップロード出来ていないのに成功しているように見える現象を修正 (1.0.1b)</a> | |
7 | + <li> [Fixed] Nucleus v3.41でファイルがアップロード出来ないバグを修正 (Thanks 桜枝さん, 1.0.1b)</a> | |
8 | + <li> [Fixed] ファイルがアップロード出来ていないのに成功しているように見える現象を修正 (1.0.1b)</a> | |
9 | 9 | |
10 | 10 | <li>Version 1.1: (2010/05/09)</li> |
11 | 11 | <li> [Fixed] register_globals,allow_url_fopen,allow_url_includeがonの場合にリモートコードインジェクションが発生する問題に対応しました (Thanks Katsumiさん)</li> |
12 | 12 | <li> [Changed] エントリの編集部分に機能を統合しました</li> |
13 | 13 | <li> [Added] アップロード先のコレクションを選択可能にしました</li> |
14 | 14 | <li> [Added] リセット機能を実装しました</li> |
15 | + | |
16 | + <li>Version 1.2: (2011/10/19)</li> | |
17 | + <li> [Fixed] Firefox7 で動作しない問題に対応 (同梱のPluploadを1.5.1.1に更新)</li> | |
15 | 18 | </ul> |
@@ -2,10 +2,10 @@ | ||
2 | 2 | // vim: tabstop=2:shiftwidth=2 |
3 | 3 | |
4 | 4 | /** |
5 | - * index.php ($Revision: 1.3 $) | |
5 | + * index.php ($Revision: 1.4 $) | |
6 | 6 | * |
7 | 7 | * by hsur ( http://blog.cles.jp/np_cles ) |
8 | - * $Id: index.php,v 1.3 2010/05/08 20:49:28 hsur Exp $ | |
8 | + * $Id: index.php,v 1.4 2010/05/08 23:34:59 hsur Exp $ | |
9 | 9 | */ |
10 | 10 | |
11 | 11 | /* |
@@ -1,86 +0,0 @@ | ||
1 | -// Copyright 2007, Google Inc. | |
2 | -// | |
3 | -// Redistribution and use in source and binary forms, with or without | |
4 | -// modification, are permitted provided that the following conditions are met: | |
5 | -// | |
6 | -// 1. Redistributions of source code must retain the above copyright notice, | |
7 | -// this list of conditions and the following disclaimer. | |
8 | -// 2. Redistributions in binary form must reproduce the above copyright notice, | |
9 | -// this list of conditions and the following disclaimer in the documentation | |
10 | -// and/or other materials provided with the distribution. | |
11 | -// 3. Neither the name of Google Inc. nor the names of its contributors may be | |
12 | -// used to endorse or promote products derived from this software without | |
13 | -// specific prior written permission. | |
14 | -// | |
15 | -// THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED | |
16 | -// WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF | |
17 | -// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO | |
18 | -// EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, | |
19 | -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, | |
20 | -// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; | |
21 | -// OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, | |
22 | -// WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR | |
23 | -// OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF | |
24 | -// ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | |
25 | -// | |
26 | -// Sets up google.gears.*, which is *the only* supported way to access Gears. | |
27 | -// | |
28 | -// Circumvent this file at your own risk! | |
29 | -// | |
30 | -// In the future, Gears may automatically define google.gears.* without this | |
31 | -// file. Gears may use these objects to transparently fix bugs and compatibility | |
32 | -// issues. Applications that use the code below will continue to work seamlessly | |
33 | -// when that happens. | |
34 | - | |
35 | -(function() { | |
36 | - // We are already defined. Hooray! | |
37 | - if (window.google && google.gears) { | |
38 | - return; | |
39 | - } | |
40 | - | |
41 | - var factory = null; | |
42 | - | |
43 | - // Firefox | |
44 | - if (typeof GearsFactory != 'undefined') { | |
45 | - factory = new GearsFactory(); | |
46 | - } else { | |
47 | - // IE | |
48 | - try { | |
49 | - factory = new ActiveXObject('Gears.Factory'); | |
50 | - // privateSetGlobalObject is only required and supported on WinCE. | |
51 | - if (factory.getBuildInfo().indexOf('ie_mobile') != -1) { | |
52 | - factory.privateSetGlobalObject(this); | |
53 | - } | |
54 | - } catch (e) { | |
55 | - // Safari | |
56 | - if ((typeof navigator.mimeTypes != 'undefined') | |
57 | - && navigator.mimeTypes["application/x-googlegears"]) { | |
58 | - factory = document.createElement("object"); | |
59 | - factory.style.display = "none"; | |
60 | - factory.width = 0; | |
61 | - factory.height = 0; | |
62 | - factory.type = "application/x-googlegears"; | |
63 | - document.documentElement.appendChild(factory); | |
64 | - } | |
65 | - } | |
66 | - } | |
67 | - | |
68 | - // *Do not* define any objects if Gears is not installed. This mimics the | |
69 | - // behavior of Gears defining the objects in the future. | |
70 | - if (!factory) { | |
71 | - return; | |
72 | - } | |
73 | - | |
74 | - // Now set up the objects, being careful not to overwrite anything. | |
75 | - // | |
76 | - // Note: In Internet Explorer for Windows Mobile, you can't add properties to | |
77 | - // the window object. However, global objects are automatically added as | |
78 | - // properties of the window object in all browsers. | |
79 | - if (!window.google) { | |
80 | - google = {}; | |
81 | - } | |
82 | - | |
83 | - if (!google.gears) { | |
84 | - google.gears = {factory: factory}; | |
85 | - } | |
86 | -})(); |
@@ -1 +0,0 @@ | ||
1 | -(function(c){var d={};function a(e){return plupload.translate(e)||e}function b(f,e){e.contents().each(function(g,h){h=c(h);if(!h.is(".plupload")){h.remove()}});e.prepend('<div class="plupload_wrapper plupload_scroll"><div id="'+f+'_container" class="plupload_container"><div class="plupload"><div class="plupload_header"><div class="plupload_header_content"><div class="plupload_header_title">'+a("Select files")+'</div><div class="plupload_header_text">'+a("Add files to the upload queue and click the start button.")+'</div></div></div><div class="plupload_content"><div class="plupload_filelist_header"><div class="plupload_file_name">'+a("Filename")+'</div><div class="plupload_file_action"> </div><div class="plupload_file_status"><span>'+a("Status")+'</span></div><div class="plupload_file_size">'+a("Size")+'</div><div class="plupload_clearer"> </div></div><ul id="'+f+'_filelist" class="plupload_filelist"></ul><div class="plupload_filelist_footer"><div class="plupload_file_name"><div class="plupload_buttons"><a href="#" class="plupload_button plupload_add">'+a("Add files")+'</a><a href="#" class="plupload_button plupload_start">'+a("Start upload")+'</a></div><span class="plupload_upload_status"></span></div><div class="plupload_file_action"></div><div class="plupload_file_status"><span class="plupload_total_status">0%</span></div><div class="plupload_file_size"><span class="plupload_total_file_size">0 b</span></div><div class="plupload_progress"><div class="plupload_progress_container"><div class="plupload_progress_bar"></div></div></div><div class="plupload_clearer"> </div></div></div></div></div><input type="hidden" id="'+f+'_count" name="'+f+'_count" value="0" /></div>')}c.fn.pluploadQueue=function(e){if(e){this.each(function(){var j,i,k;i=c(this);k=i.attr("id");if(!k){k=plupload.guid();i.attr("id",k)}j=new plupload.Uploader(c.extend({dragdrop:true,container:k},e));if(e.preinit){e.preinit(j)}d[k]=j;function h(l){var m;if(l.status==plupload.DONE){m="plupload_done"}if(l.status==plupload.FAILED){m="plupload_failed"}if(l.status==plupload.QUEUED){m="plupload_delete"}if(l.status==plupload.UPLOADING){m="plupload_uploading"}c("#"+l.id).attr("class",m).find("a").css("display","block")}function f(){c("span.plupload_total_status",i).html(j.total.percent+"%");c("div.plupload_progress_bar",i).css("width",j.total.percent+"%");c("span.plupload_upload_status",i).text("Uploaded "+j.total.uploaded+"/"+j.files.length+" files");if(j.total.uploaded==j.files.length){j.stop()}}function g(){var m=c("ul.plupload_filelist",i).html(""),n=0,l;c.each(j.files,function(p,o){l="";if(o.status==plupload.DONE){if(o.target_name){l+='<input type="hidden" name="'+k+"_"+n+'_tmpname" value="'+plupload.xmlEncode(o.target_name)+'" />'}l+='<input type="hidden" name="'+k+"_"+n+'_name" value="'+plupload.xmlEncode(o.name)+'" />';l+='<input type="hidden" name="'+k+"_"+n+'_status" value="'+(o.status==plupload.DONE?"done":"failed")+'" />';n++;c("#"+k+"_count").val(n)}m.append('<li id="'+o.id+'"><div class="plupload_file_name"><span>'+o.name+'</span></div><div class="plupload_file_action"><a href="#"></a></div><div class="plupload_file_status">'+o.percent+'%</div><div class="plupload_file_size">'+plupload.formatSize(o.size)+'</div><div class="plupload_clearer"> </div>'+l+"</li>");h(o);c("#"+o.id+".plupload_delete a").click(function(q){c("#"+o.id).remove();j.removeFile(o);q.preventDefault()})});c("span.plupload_total_file_size",i).html(plupload.formatSize(j.total.size));if(j.total.queued===0){c("span.plupload_add_text",i).text(a("Add files."))}else{c("span.plupload_add_text",i).text(j.total.queued+" files queued.")}c("a.plupload_start",i).toggleClass("plupload_disabled",j.files.length===0);m[0].scrollTop=m[0].scrollHeight;f();if(!j.files.length&&j.features.dragdrop&&j.settings.dragdrop){c("#"+k+"_filelist").append('<li class="plupload_droptext">'+a("Drag files here.")+"</li>")}}j.bind("UploadFile",function(l,m){c("#"+m.id).addClass("plupload_current_file")});j.bind("Init",function(l,m){b(k,i);if(!e.unique_names&&e.rename){c("#"+k+"_filelist div.plupload_file_name span",i).live("click",function(s){var q=c(s.target),o,r,n,p="";o=l.getFile(q.parents("li")[0].id);n=o.name;r=/^(.+)(\.[^.]+)$/.exec(n);if(r){n=r[1];p=r[2]}q.hide().after('<input type="text" />');q.next().val(n).focus().blur(function(){q.show().next().remove()}).keydown(function(u){var t=c(this);if(u.keyCode==13){u.preventDefault();o.name=t.val()+p;q.text(o.name);t.blur()}})})}c("a.plupload_add",i).attr("id",k+"_browse");l.settings.browse_button=k+"_browse";if(l.features.dragdrop&&l.settings.dragdrop){l.settings.drop_element=k+"_filelist";c("#"+k+"_filelist").append('<li class="plupload_droptext">'+a("Drag files here.")+"</li>")}c("#"+k+"_container").attr("title","Using runtime: "+m.runtime);c("a.plupload_start",i).click(function(n){if(!c(this).hasClass("plupload_disabled")){j.start()}n.preventDefault()});c("a.plupload_stop",i).click(function(n){j.stop();n.preventDefault()});c("a.plupload_start",i).addClass("plupload_disabled")});j.init();if(e.setup){e.setup(j)}j.bind("Error",function(l,o){var m=o.file,n;if(m){n=o.message;if(o.details){n+=" ("+o.details+")"}c("#"+m.id).attr("class","plupload_failed").find("a").css("display","block").attr("title",n)}});j.bind("StateChanged",function(){if(j.state===plupload.STARTED){c("li.plupload_delete a,div.plupload_buttons",i).hide();c("span.plupload_upload_status,div.plupload_progress,a.plupload_stop",i).css("display","block");c("span.plupload_upload_status",i).text("Uploaded 0/"+j.files.length+" files")}else{c("a.plupload_stop,div.plupload_progress",i).hide();c("a.plupload_delete",i).css("display","block")}});j.bind("QueueChanged",g);j.bind("StateChanged",function(l){if(l.state==plupload.STOPPED){g()}});j.bind("FileUploaded",function(l,m){h(m)});j.bind("UploadProgress",function(l,m){c("#"+m.id+" div.plupload_file_status",i).html(m.percent+"%");h(m);f()})});return this}else{return d[c(this[0]).attr("id")]}}})(jQuery); | |
\ No newline at end of file |
@@ -1 +0,0 @@ | ||
1 | -(function(b){var c={};function a(e,d){d.html('<div class="plupload_single" id="'+e+'_browse"><div class="plupload_container"><input type="text" class="plupload_file_name" value="" /><input type="button" class="plupload_browse" value="Browse…" /><span class="plupload_status"></span></div></div>')}b.fn.pluploadSingle=function(d){if(d){this.each(function(){var f,e,g;f=new plupload.Uploader(d);e=b(this);g=e.attr("id");if(!g){g=plupload.guid();e.attr("id",g)}f.settings.browse_button=g+"_browse";f.settings.multi_selection=false;c[g]=f;f.bind("PreInit",function(){a(g,e);b(".plupload_file_name,.plupload_browse",e).click(function(h){f.browse();h.preventDefault()});if(f.settings.unique_names){f.bind("UploadFile",function(h,i){i.target_name=(f.settings.salt||"")+i.id+".tmp"})}f.bind("QueueChanged",function(h){var i;if(h.files.length){i=h.files[h.files.length-1];b(".plupload_file_name",e).val(i.name).attr("disabled","disabled");b(".plupload_status",e).html("Size: "+plupload.formatSize(i.size));b(".plupload_browse",e).attr("disabled","disabled");h.start()}});f.bind("UploadProgress",function(h,i){if(i.status==plupload.DONE){b(".plupload_status",e).html("File uploaded.")}else{b(".plupload_status",e).html("Uploading: "+i.percent+"%")}});f.bind("FileUploaded",function(h,i){if(i.status==plupload.DONE){if(i.target_name){e.append('<input type="hidden" name="'+g+'_tmpname" value="'+plupload.xmlEncode(i.target_name)+'" />')}e.append('<input type="hidden" name="'+g+'_name" value="'+plupload.xmlEncode(i.name)+'" />')}else{b(".plupload_file_name,.plupload_browse",e).attr("disabled","")}})});f.init()});return this}else{return c[b(this[0]).attr("id")]}}})(jQuery); | |
\ No newline at end of file |
@@ -1 +0,0 @@ | ||
1 | -(function(a){a.runtimes.BrowserPlus=a.addRuntime("browserplus",{init:function(g,i){var e=window.BrowserPlus,h={},d=g.settings,c=d.resize;function f(n){var m,l,j=[],k,o;for(l=0;l<n.length;l++){k=n[l];o=a.guid();h[o]=k;j.push(new a.File(o,k.name,k.size))}if(l){g.trigger("FilesAdded",j)}}function b(){g.bind("PostInit",function(){var m,k=d.drop_element,o=g.id+"_droptarget",j=document.getElementById(k),l;function p(r,q){e.DragAndDrop.AddDropTarget({id:r},function(s){e.DragAndDrop.AttachCallbacks({id:r,hover:function(t){if(!t&&q){q()}},drop:function(t){if(q){q()}f(t)}},function(){})})}function n(){document.getElementById(o).style.top="-1000px"}if(j){if(document.attachEvent&&(/MSIE/gi).test(navigator.userAgent)){m=document.createElement("div");m.setAttribute("id",o);a.extend(m.style,{position:"absolute",top:"-1000px",background:"red",filter:"alpha(opacity=0)",opacity:0});document.body.appendChild(m);a.addEvent(j,"dragenter",function(r){var q,s;q=document.getElementById(k);s=a.getPos(q);a.extend(document.getElementById(o).style,{top:s.y+"px",left:s.x+"px",width:q.offsetWidth+"px",height:q.offsetHeight+"px"})});p(o,n)}else{p(k)}}a.addEvent(document.getElementById(d.browse_button),"click",function(v){var t=[],r,q,u=d.filters,s;v.preventDefault();for(r=0;r<u.length;r++){s=u[r].extensions.split(",");for(q=0;q<s.length;q++){t.push(a.mimeTypes[s[q]])}}e.FileBrowse.OpenBrowseDialog({mimeTypes:t},function(w){if(w.success){f(w.value)}})});j=m=null});g.bind("UploadFile",function(n,k){var m=h[k.id],j={},l=n.settings.chunk_size,o,p=[];function r(s,u){var t;if(k.status==a.FAILED){return}j.name=k.target_name||k.name;if(l){j.chunk=s;j.chunks=u}t=p.shift();e.Uploader.upload({url:a.buildUrl(n.settings.url,j),files:{file:t},cookies:document.cookies,postvars:n.settings.multipart_params,progressCallback:function(x){var w,v=0;o[s]=parseInt(x.filePercent*t.size/100,10);for(w=0;w<o.length;w++){v+=o[w]}k.loaded=v;n.trigger("UploadProgress",k)}},function(w){var v,x;if(w.success){v=w.value.statusCode;if(l){n.trigger("ChunkUploaded",k,{chunk:s,chunks:u,response:w.value.body,status:v})}if(p.length>0){r(++s,u)}else{k.status=a.DONE;n.trigger("FileUploaded",k,{response:w.value.body,status:v});if(v>=400){n.trigger("Error",{code:a.HTTP_ERROR,message:"HTTP Error.",file:k,status:v})}}}else{n.trigger("Error",{code:a.GENERIC_ERROR,message:"Generic Error.",file:k,details:w.error})}})}function q(s){k.size=s.size;if(l){e.FileAccess.chunk({file:s,chunkSize:l},function(v){if(v.success){var w=v.value,t=w.length;o=Array(t);for(var u=0;u<t;u++){o[u]=0;p.push(w[u])}r(0,t)}})}else{o=Array(1);p.push(s);r(0,1)}}if(c&&/\.(png|jpg|jpeg)$/i.test(k.name)){BrowserPlus.ImageAlter.transform({file:m,quality:c.quality||90,actions:[{scale:{maxwidth:c.width,maxheight:c.height}}]},function(s){if(s.success){q(s.value.file)}})}else{q(m)}});g.features={dragdrop:true,jpgresize:true,pngresize:true,chunks:true,progress:true};i({success:true})}if(e){e.init(function(k){var j=[{service:"Uploader",version:"3"},{service:"DragAndDrop",version:"1"},{service:"FileBrowse",version:"1"},{service:"FileAccess",version:"2"}];if(c){j.push({service:"ImageAlter",version:"4"})}if(k.success){e.require({services:j},function(l){if(l.success){b()}else{i()}})}else{i()}})}else{i()}}})})(plupload); | |
\ No newline at end of file |
@@ -1 +0,0 @@ | ||
1 | -(function(c){var a={};function b(){var d;try{d=navigator.plugins["Shockwave Flash"];d=d.description}catch(f){try{d=new ActiveXObject("ShockwaveFlash.ShockwaveFlash").GetVariable("$version")}catch(e){d="0.0"}}d=d.match(/\d+/g);return parseFloat(d[0]+"."+d[1])}c.flash={trigger:function(f,d,e){setTimeout(function(){var j=a[f],h,g;if(j){j.trigger("Flash:"+d,e)}},0)}};c.runtimes.Flash=c.addRuntime("flash",{init:function(g,l){var k,f,h,e,m=0,d=document.body;if(b()<10){l({success:false});return}a[g.id]=g;k=document.getElementById(g.settings.browse_button);f=document.createElement("div");f.id=g.id+"_flash_container";c.extend(f.style,{position:"absolute",top:"0px",background:g.settings.shim_bgcolor||"transparent",zIndex:99999,width:"100%",height:"100%"});f.className="plupload flash";if(g.settings.container){d=document.getElementById(g.settings.container);d.style.position="relative"}d.appendChild(f);h="id="+escape(g.id);f.innerHTML='<object id="'+g.id+'_flash" width="100%" height="100%" style="outline:0" type="application/x-shockwave-flash" data="'+g.settings.flash_swf_url+'"><param name="movie" value="'+g.settings.flash_swf_url+'" /><param name="flashvars" value="'+h+'" /><param name="wmode" value="transparent" /><param name="allowscriptaccess" value="always" /></object>';function j(){return document.getElementById(g.id+"_flash")}function i(){if(m++>5000){l({success:false});return}if(!e){setTimeout(i,1)}}i();k=f=null;g.bind("Flash:Init",function(){var p={},o,n=g.settings.resize||{};e=true;j().setFileFilters(g.settings.filters,g.settings.multi_selection);g.bind("UploadFile",function(q,r){var s=q.settings;j().uploadFile(p[r.id],c.buildUrl(s.url,{name:r.target_name||r.name}),{chunk_size:s.chunk_size,width:n.width,height:n.height,quality:n.quality||90,multipart:s.multipart,multipart_params:s.multipart_params,file_data_name:s.file_data_name,format:/\.(jpg|jpeg)$/i.test(r.name)?"jpg":"png",headers:s.headers})});g.bind("Flash:UploadProcess",function(r,q){var s=r.getFile(p[q.id]);if(s.status!=c.FAILED){s.loaded=q.loaded;s.size=q.size;r.trigger("UploadProgress",s)}});g.bind("Flash:UploadChunkComplete",function(q,s){var t,r=q.getFile(p[s.id]);t={chunk:s.chunk,chunks:s.chunks,response:s.text};q.trigger("ChunkUploaded",r,t);if(r.status!=c.FAILED){j().uploadNextChunk()}if(s.chunk==s.chunks-1){r.status=c.DONE;q.trigger("FileUploaded",r,{response:s.text})}});g.bind("Flash:SelectFiles",function(q,t){var s,r,u=[],v;for(r=0;r<t.length;r++){s=t[r];v=c.guid();p[v]=s.id;p[s.id]=v;u.push(new c.File(v,s.name,s.size))}if(u.length){g.trigger("FilesAdded",u)}});g.bind("Flash:SecurityError",function(q,r){g.trigger("Error",{code:c.SECURITY_ERROR,message:"Security error.",details:r.message,file:g.getFile(p[r.id])})});g.bind("Flash:GenericError",function(q,r){g.trigger("Error",{code:c.GENERIC_ERROR,message:"Generic error.",details:r.message,file:g.getFile(p[r.id])})});g.bind("Flash:IOError",function(q,r){g.trigger("Error",{code:c.IO_ERROR,message:"IO error.",details:r.message,file:g.getFile(p[r.id])})});g.bind("QueueChanged",function(q){g.refresh()});g.bind("FilesRemoved",function(q,s){var r;for(r=0;r<s.length;r++){j().removeFile(p[s[r].id])}});g.bind("StateChanged",function(q){g.refresh()});g.bind("Refresh",function(q){var r,s,t;j().setFileFilters(g.settings.filters,g.settings.multi_selection);r=document.getElementById(q.settings.browse_button);s=c.getPos(r,document.getElementById(q.settings.container));t=c.getSize(r);c.extend(document.getElementById(q.id+"_flash_container").style,{top:s.y+"px",left:s.x+"px",width:t.w+"px",height:t.h+"px"})});g.features={jpgresize:true,pngresize:true,chunks:true,progress:true};l({success:true})})}})})(plupload); | |
\ No newline at end of file |
@@ -1 +0,0 @@ | ||
1 | -(function(){var c=0,h=[],j={},f={},a={"<":"lt",">":"gt","&":"amp",'"':"quot","'":"#39"},i=/[<>&\"\']/g,b;function e(){this.returnValue=false}function g(){this.cancelBubble=true}(function(k){var l=k.split(/,/),m,o,n;for(m=0;m<l.length;m+=2){n=l[m+1].split(/ /);for(o=0;o<n.length;o++){f[n[o]]=l[m]}}})("application/msword,doc dot,application/pdf,pdf,application/pgp-signature,pgp,application/postscript,ps ai eps,application/rtf,rtf,application/vnd.ms-excel,xls xlb,application/vnd.ms-powerpoint,ppt pps pot,application/zip,zip,application/x-shockwave-flash,swf swfl,application/vnd.openxmlformats,docx pptx xlsx,audio/mpeg,mpga mpega mp2 mp3,audio/x-wav,wav,image/bmp,bmp,image/gif,gif,image/jpeg,jpeg jpg jpe,image/png,png,image/svg+xml,svg svgz,image/tiff,tiff tif,text/html,htm html xhtml,text/rtf,rtf,video/mpeg,mpeg mpg mpe,video/quicktime,qt mov,video/x-flv,flv,video/vnd.rn-realvideo,rv,text/plain,asc txt text diff log,application/octet-stream,exe");var d={STOPPED:1,STARTED:2,QUEUED:1,UPLOADING:2,FAILED:4,DONE:5,GENERIC_ERROR:-100,HTTP_ERROR:-200,IO_ERROR:-300,SECURITY_ERROR:-400,INIT_ERROR:-500,FILE_SIZE_ERROR:-600,FILE_EXTENSION_ERROR:-700,mimeTypes:f,extend:function(k){d.each(arguments,function(l,m){if(m>0){d.each(l,function(o,n){k[n]=o})}});return k},cleanName:function(k){var l,m;m=[/[\300-\306]/g,"A",/[\340-\346]/g,"a",/\307/g,"C",/\347/g,"c",/[\310-\313]/g,"E",/[\350-\353]/g,"e",/[\314-\317]/g,"I",/[\354-\357]/g,"i",/\321/g,"N",/\361/g,"n",/[\322-\330]/g,"O",/[\362-\370]/g,"o",/[\331-\334]/g,"U",/[\371-\374]/g,"u"];for(l=0;l<m.length;l+=2){k=k.replace(m[l],m[l+1])}k=k.replace(/\s+/g,"_");k=k.replace(/[^a-z0-9_\-\.]+/gi,"");return k},addRuntime:function(k,l){l.name=k;h[k]=l;h.push(l);return l},guid:function(){var k=new Date().getTime().toString(32),l;for(l=0;l<5;l++){k+=Math.floor(Math.random()*65535).toString(32)}return(d.guidPrefix||"p")+k+(c++).toString(32)},buildUrl:function(l,k){var m="";d.each(k,function(o,n){m+=(m?"&":"")+encodeURIComponent(n)+"="+encodeURIComponent(o)});if(m){l+=(l.indexOf("?")>0?"&":"?")+m}return l},each:function(n,o){var m,l,k;if(n){m=n.length;if(m===b){for(l in n){if(n.hasOwnProperty(l)){if(o(n[l],l)===false){return}}}}else{for(k=0;k<m;k++){if(o(n[k],k)===false){return}}}}},formatSize:function(k){if(k===b){return d.translate("N/A")}if(k>1048576){return Math.round(k/1048576,1)+" MB"}if(k>1024){return Math.round(k/1024,1)+" KB"}return k+" b"},getPos:function(l,p){var q=0,o=0,s,r=document,m,n;l=l;p=p||r.body;function k(w){var u,v,t=0,z=0;if(w){v=w.getBoundingClientRect();u=r.compatMode==="CSS1Compat"?r.documentElement:r.body;t=v.left+u.scrollLeft;z=v.top+u.scrollTop}return{x:t,y:z}}if(l.getBoundingClientRect&&(navigator.userAgent.indexOf("MSIE")>0&&r.documentMode!==8)){m=k(l);n=k(p);return{x:m.x-n.x,y:m.y-n.y}}s=l;while(s&&s!=p&&s.nodeType){q+=s.offsetLeft||0;o+=s.offsetTop||0;s=s.offsetParent}s=l.parentNode;while(s&&s!=p&&s.nodeType){q-=s.scrollLeft||0;o-=s.scrollTop||0;s=s.parentNode}return{x:q,y:o}},getSize:function(k){return{w:k.clientWidth||k.offsetWidth,h:k.clientHeight||k.offsetHeight}},parseSize:function(k){var l;if(typeof(k)=="string"){k=/^([0-9]+)([mgk]+)$/.exec(k.toLowerCase().replace(/[^0-9mkg]/g,""));l=k[2];k=+k[1];if(l=="g"){k*=1073741824}if(l=="m"){k*=1048576}if(l=="k"){k*=1024}}return k},xmlEncode:function(k){return k?(""+k).replace(i,function(l){return a[l]?"&"+a[l]+";":l}):k},toArray:function(m){var l,k=[];for(l=0;l<m.length;l++){k[l]=m[l]}return k},addI18n:function(k){return d.extend(j,k)},translate:function(k){return j[k]||k},addEvent:function(l,k,m){if(l.attachEvent){l.attachEvent("on"+k,function(){var n=window.event;if(!n.target){n.target=n.srcElement}n.preventDefault=e;n.stopPropagation=g;m(n)})}else{if(l.addEventListener){l.addEventListener(k,m,false)}}}};d.Uploader=function(n){var l={},q,p=[],r,m;q=new d.QueueProgress();n=d.extend({chunk_size:0,max_file_size:"1gb",multi_selection:true,file_data_name:"file",filters:[]},n);function o(){var s;if(this.state==d.STARTED&&r<p.length){s=p[r++];if(s.status==d.QUEUED){this.trigger("UploadFile",s)}else{o.call(this)}}else{this.stop()}}function k(){var t,s;q.reset();for(t=0;t<p.length;t++){s=p[t];if(s.size!==b){q.size+=s.size;q.loaded+=s.loaded}else{q.size=b}if(s.status==d.DONE){q.uploaded++}else{if(s.status==d.FAILED){q.failed++}else{q.queued++}}}if(q.size===b){q.percent=p.length>0?Math.ceil(q.uploaded/p.length*100):0}else{q.bytesPerSec=Math.ceil(q.loaded/((+new Date()-m||1)/1000));q.percent=q.size>0?Math.ceil(q.loaded/q.size*100):0}}d.extend(this,{state:d.STOPPED,features:{},files:p,settings:n,total:q,id:d.guid(),init:function(){var x=this,y,u,t,w=0,v;n.page_url=n.page_url||document.location.pathname.replace(/\/[^\/]+$/g,"/");if(!/^(\w+:\/\/|\/)/.test(n.url)){n.url=n.page_url+n.url}n.chunk_size=d.parseSize(n.chunk_size);n.max_file_size=d.parseSize(n.max_file_size);x.bind("FilesAdded",function(z,C){var B,A,F=0,E,D=n.filters;if(D&&D.length){E={};d.each(D,function(G){d.each(G.extensions.split(/,/),function(H){E[H.toLowerCase()]=true})})}for(B=0;B<C.length;B++){A=C[B];A.loaded=0;A.percent=0;A.status=d.QUEUED;if(E&&!E[A.name.toLowerCase().split(".").slice(-1)]){z.trigger("Error",{code:d.FILE_EXTENSION_ERROR,message:"File extension error.",file:A});continue}if(A.size!==b&&A.size>n.max_file_size){z.trigger("Error",{code:d.FILE_SIZE_ERROR,message:"File size error.",file:A});continue}p.push(A);F++}if(F){x.trigger("QueueChanged");x.refresh()}});if(n.unique_names){x.bind("UploadFile",function(z,A){A.target_name=A.id+".tmp"})}x.bind("UploadProgress",function(z,A){if(A.status==d.QUEUED){A.status=d.UPLOADING}A.percent=A.size>0?Math.ceil(A.loaded/A.size*100):100;k()});x.bind("StateChanged",function(z){if(z.state==d.STARTED){m=(+new Date())}});x.bind("QueueChanged",k);x.bind("Error",function(z,A){if(A.file){A.file.status=d.FAILED;k();window.setTimeout(function(){o.call(x)})}});x.bind("FileUploaded",function(z,A){A.status=d.DONE;z.trigger("UploadProgress",A);o.call(x)});if(n.runtimes){u=[];v=n.runtimes.split(/\s?,\s?/);for(y=0;y<v.length;y++){if(h[v[y]]){u.push(h[v[y]])}}}else{u=h}function s(){var z=u[w++];if(z){z.init(x,function(C){var A,B;if(C&&C.success){A=x.settings.required_features;if(A){A=A.split(",");for(B=0;B<A.length;B++){if(!x.features[A[B]]){s();return}}}x.trigger("Init",{runtime:z.name});x.trigger("PostInit");x.refresh()}else{s()}})}else{x.trigger("Error",{code:d.INIT_ERROR,message:"Init error."})}}s()},refresh:function(){this.trigger("Refresh")},start:function(){if(this.state!=d.STARTED){r=0;this.state=d.STARTED;this.trigger("StateChanged");o.call(this)}},stop:function(){if(this.state!=d.STOPPED){this.state=d.STOPPED;this.trigger("StateChanged")}},getFile:function(t){var s;for(s=p.length-1;s>=0;s--){if(p[s].id===t){return p[s]}}},removeFile:function(t){var s;for(s=p.length-1;s>=0;s--){if(p[s].id===t.id){return this.splice(s,1)[0]}}},splice:function(u,s){var t;t=p.splice(u,s);this.trigger("FilesRemoved",t);this.trigger("QueueChanged");return t},trigger:function(t){var v=l[t.toLowerCase()],u,s;if(v){s=Array.prototype.slice.call(arguments);s[0]=this;for(u=0;u<v.length;u++){if(v[u].func.apply(v[u].scope,s)===false){return false}}}return true},bind:function(s,u,t){var v;s=s.toLowerCase();v=l[s]||[];v.push({func:u,scope:t||this});l[s]=v},unbind:function(s,u){var v=l[s.toLowerCase()],t;if(v){for(t=v.length-1;t>=0;t--){if(v[t].func===u){v.splice(t,1)}}}}})};d.File=function(n,l,m){var k=this;k.id=n;k.name=l;k.size=m;k.loaded=0;k.percent=0;k.status=0};d.Runtime=function(){this.init=function(k,l){}};d.QueueProgress=function(){var k=this;k.size=0;k.loaded=0;k.uploaded=0;k.failed=0;k.queued=0;k.percent=0;k.bytesPerSec=0;k.reset=function(){k.size=k.loaded=k.uploaded=k.failed=k.queued=k.percent=k.bytesPerSec=0}};d.runtimes={};window.plupload=d})();(function(b){var c={};function a(i,e,k,j,d){var l,g,f,h;g=google.gears.factory.create("beta.canvas");g.decode(i);h=Math.min(e/g.width,k/g.height);if(h<1){e=Math.round(g.width*h);k=Math.round(g.height*h)}else{e=g.width;k=g.height}g.resize(e,k);return g.encode(d,{quality:j/100})}b.runtimes.Gears=b.addRuntime("gears",{init:function(g,i){var h;if(!window.google||!google.gears){return i({success:false})}try{h=google.gears.factory.create("beta.desktop")}catch(f){return i({success:false})}function d(k){var j,e,l=[],m;for(e=0;e<k.length;e++){j=k[e];m=b.guid();c[m]=j.blob;l.push(new b.File(m,j.name,j.blob.length))}g.trigger("FilesAdded",l)}g.bind("PostInit",function(){var j=g.settings,e=document.getElementById(j.drop_element);if(e){b.addEvent(e,"dragover",function(k){h.setDropEffect(k,"copy");k.preventDefault()});b.addEvent(e,"drop",function(l){var k=h.getDragData(l,"application/x-gears-files");if(k){d(k.files)}l.preventDefault()});e=0}b.addEvent(document.getElementById(j.browse_button),"click",function(o){var n=[],l,k,m;o.preventDefault();for(l=0;l<j.filters.length;l++){m=j.filters[l].extensions.split(",");for(k=0;k<m.length;k++){n.push("."+m[k])}}h.openFiles(d,{singleFile:!j.multi_selection,filter:n})})});g.bind("UploadFile",function(o,l){var q=0,p,m,n=0,k=o.settings.resize,e;m=o.settings.chunk_size;e=m>0;p=Math.ceil(l.size/m);if(!e){m=l.size;p=1}if(k&&/\.(png|jpg|jpeg)$/i.test(l.name)){c[l.id]=a(c[l.id],k.width,k.height,k.quality||90,/\.png$/i.test(l.name)?"image/png":"image/jpeg")}l.size=c[l.id].length;function j(){var u,w,s=o.settings.multipart,r=0,v={name:l.target_name||l.name};function t(y){var x,C="----pluploadboundary"+b.guid(),A="--",B="\r\n",z;if(s){u.setRequestHeader("Content-Type","multipart/form-data; boundary="+C);x=google.gears.factory.create("beta.blobbuilder");b.each(o.settings.multipart_params,function(E,D){x.append(A+C+B+'Content-Disposition: form-data; name="'+D+'"'+B+B);x.append(E+B)});x.append(A+C+B+'Content-Disposition: form-data; name="'+o.settings.file_data_name+'"; filename="'+l.name+'"'+B+"Content-Type: application/octet-stream"+B+B);x.append(y);x.append(B+A+C+A+B);z=x.getAsBlob();r=z.length-y.length;y=z}u.send(y)}if(l.status==b.DONE||l.status==b.FAILED||o.state==b.STOPPED){return}if(e){v.chunk=q;v.chunks=p}w=Math.min(m,l.size-(q*m));u=google.gears.factory.create("beta.httprequest");u.open("POST",b.buildUrl(o.settings.url,v));if(!s){u.setRequestHeader("Content-Disposition",'attachment; filename="'+l.name+'"');u.setRequestHeader("Content-Type","application/octet-stream")}b.each(o.settings.headers,function(y,x){u.setRequestHeader(x,y)});u.upload.onprogress=function(x){l.loaded=n+x.loaded-r;o.trigger("UploadProgress",l)};u.onreadystatechange=function(){var x;if(u.readyState==4){if(u.status==200){x={chunk:q,chunks:p,response:u.responseText,status:u.status};o.trigger("ChunkUploaded",l,x);if(x.cancelled){l.status=b.FAILED;return}n+=w;if(++q>=p){l.status=b.DONE;o.trigger("FileUploaded",l,{response:u.responseText,status:u.status})}else{j()}}else{o.trigger("Error",{code:b.HTTP_ERROR,message:"HTTP Error.",file:l,chunk:q,chunks:p,status:u.status})}}};if(q<p){t(c[l.id].slice(q*m,w))}}j()});g.features={dragdrop:true,jpgresize:true,pngresize:true,chunks:true,progress:true};i({success:true})}})})(plupload);(function(c){var a={};function b(l){var k,j=typeof l,h,e,g,f;if(j==="string"){k="\bb\tt\nn\ff\rr\"\"''\\\\";return'"'+l.replace(/([\u0080-\uFFFF\x00-\x1f\"])/g,function(n,m){var i=k.indexOf(m);if(i+1){return"\\"+k.charAt(i+1)}n=m.charCodeAt().toString(16);return"\\u"+"0000".substring(n.length)+n})+'"'}if(j=="object"){e=l.length!==h;k="";if(e){for(g=0;g<l.length;g++){if(k){k+=","}k+=b(l[g])}k="["+k+"]"}else{for(f in l){if(l.hasOwnProperty(f)){if(k){k+=","}k+=b(f)+":"+b(l[f])}}k="{"+k+"}"}return k}if(l===h){return"null"}return""+l}function d(o){var r=false,f=null,k=null,g,h,i,q,j,m=0;try{try{k=new ActiveXObject("AgControl.AgControl");if(k.IsVersionSupported(o)){r=true}k=null}catch(n){var l=navigator.plugins["Silverlight Plug-In"];if(l){g=l.description;if(g==="1.0.30226.2"){g="2.0.30226.2"}h=g.split(".");while(h.length>3){h.pop()}while(h.length<4){h.push(0)}i=o.split(".");while(i.length>4){i.pop()}do{q=parseInt(i[m],10);j=parseInt(h[m],10);m++}while(m<i.length&&q===j);if(q<=j&&!isNaN(q)){r=true}}}}catch(p){r=false}return r}c.silverlight={trigger:function(j,f){var h=a[j],g,e;if(h){e=c.toArray(arguments).slice(1);e[0]="Silverlight:"+f;setTimeout(function(){h.trigger.apply(h,e)},0)}}};c.runtimes.Silverlight=c.addRuntime("silverlight",{init:function(l,m){var k,h="",j=l.settings.filters,g,f=document.body;if(!d("2.0.31005.0")||(window.opera&&window.opera.buildNumber)){m({success:false});return}a[l.id]=l;k=document.createElement("div");k.id=l.id+"_silverlight_container";c.extend(k.style,{position:"absolute",top:"0px",background:l.settings.shim_bgcolor||"transparent",zIndex:99999,width:"100px",height:"100px",overflow:"hidden",opacity:l.settings.shim_bgcolor?"":0.01});k.className="plupload silverlight";if(l.settings.container){f=document.getElementById(l.settings.container);f.style.position="relative"}f.appendChild(k);for(g=0;g<j.length;g++){h+=(h!=""?"|":"")+j[g].title+" | *."+j[g].extensions.replace(/,/g,";*.")}k.innerHTML='<object id="'+l.id+'_silverlight" data="data:application/x-silverlight," type="application/x-silverlight-2" style="outline:none;" width="1024" height="1024"><param name="source" value="'+l.settings.silverlight_xap_url+'"/><param name="background" value="Transparent"/><param name="windowless" value="true"/><param name="initParams" value="id='+l.id+",filter="+h+'"/></object>';function e(){return document.getElementById(l.id+"_silverlight").content.Upload}l.bind("Silverlight:Init",function(){var i,n={};l.bind("Silverlight:StartSelectFiles",function(o){i=[]});l.bind("Silverlight:SelectFile",function(o,r,p,q){var s;s=c.guid();n[s]=r;n[r]=s;i.push(new c.File(s,p,q))});l.bind("Silverlight:SelectSuccessful",function(){if(i.length){l.trigger("FilesAdded",i)}});l.bind("Silverlight:UploadChunkError",function(o,r,p,s,q){l.trigger("Error",{code:c.IO_ERROR,message:"IO Error.",details:q,file:o.getFile(n[r])})});l.bind("Silverlight:UploadFileProgress",function(o,s,p,r){var q=o.getFile(n[s]);if(q.status!=c.FAILED){q.size=r;q.loaded=p;o.trigger("UploadProgress",q)}});l.bind("Refresh",function(o){var p,q,r;p=document.getElementById(o.settings.browse_button);q=c.getPos(p,document.getElementById(o.settings.container));r=c.getSize(p);c.extend(document.getElementById(o.id+"_silverlight_container").style,{top:q.y+"px",left:q.x+"px",width:r.w+"px",height:r.h+"px"})});l.bind("Silverlight:UploadChunkSuccessful",function(o,r,p,u,t){var s,q=o.getFile(n[r]);s={chunk:p,chunks:u,response:t};o.trigger("ChunkUploaded",q,s);if(q.status!=c.FAILED){e().UploadNextChunk()}if(p==u-1){q.status=c.DONE;o.trigger("FileUploaded",q,{response:t})}});l.bind("Silverlight:UploadSuccessful",function(o,r,p){var q=o.getFile(n[r]);q.status=c.DONE;o.trigger("FileUploaded",q,{response:p})});l.bind("FilesRemoved",function(o,q){var p;for(p=0;p<q.length;p++){e().RemoveFile(n[q[p].id])}});l.bind("UploadFile",function(o,q){var r=o.settings,p=r.resize||{};e().UploadFile(n[q.id],c.buildUrl(o.settings.url,{name:q.target_name||q.name}),b({chunk_size:r.chunk_size,image_width:p.width,image_height:p.height,image_quality:p.quality||90,multipart:!!r.multipart,multipart_params:r.multipart_params||{},headers:r.headers}))});l.features={jpgresize:true,pngresize:true,chunks:true,progress:true};m({success:true})})}})})(plupload);(function(c){var a={};function b(){var d;try{d=navigator.plugins["Shockwave Flash"];d=d.description}catch(f){try{d=new ActiveXObject("ShockwaveFlash.ShockwaveFlash").GetVariable("$version")}catch(e){d="0.0"}}d=d.match(/\d+/g);return parseFloat(d[0]+"."+d[1])}c.flash={trigger:function(f,d,e){setTimeout(function(){var j=a[f],h,g;if(j){j.trigger("Flash:"+d,e)}},0)}};c.runtimes.Flash=c.addRuntime("flash",{init:function(g,l){var k,f,h,e,m=0,d=document.body;if(b()<10){l({success:false});return}a[g.id]=g;k=document.getElementById(g.settings.browse_button);f=document.createElement("div");f.id=g.id+"_flash_container";c.extend(f.style,{position:"absolute",top:"0px",background:g.settings.shim_bgcolor||"transparent",zIndex:99999,width:"100%",height:"100%"});f.className="plupload flash";if(g.settings.container){d=document.getElementById(g.settings.container);d.style.position="relative"}d.appendChild(f);h="id="+escape(g.id);f.innerHTML='<object id="'+g.id+'_flash" width="100%" height="100%" style="outline:0" type="application/x-shockwave-flash" data="'+g.settings.flash_swf_url+'"><param name="movie" value="'+g.settings.flash_swf_url+'" /><param name="flashvars" value="'+h+'" /><param name="wmode" value="transparent" /><param name="allowscriptaccess" value="always" /></object>';function j(){return document.getElementById(g.id+"_flash")}function i(){if(m++>5000){l({success:false});return}if(!e){setTimeout(i,1)}}i();k=f=null;g.bind("Flash:Init",function(){var p={},o,n=g.settings.resize||{};e=true;j().setFileFilters(g.settings.filters,g.settings.multi_selection);g.bind("UploadFile",function(q,r){var s=q.settings;j().uploadFile(p[r.id],c.buildUrl(s.url,{name:r.target_name||r.name}),{chunk_size:s.chunk_size,width:n.width,height:n.height,quality:n.quality||90,multipart:s.multipart,multipart_params:s.multipart_params,file_data_name:s.file_data_name,format:/\.(jpg|jpeg)$/i.test(r.name)?"jpg":"png",headers:s.headers})});g.bind("Flash:UploadProcess",function(r,q){var s=r.getFile(p[q.id]);if(s.status!=c.FAILED){s.loaded=q.loaded;s.size=q.size;r.trigger("UploadProgress",s)}});g.bind("Flash:UploadChunkComplete",function(q,s){var t,r=q.getFile(p[s.id]);t={chunk:s.chunk,chunks:s.chunks,response:s.text};q.trigger("ChunkUploaded",r,t);if(r.status!=c.FAILED){j().uploadNextChunk()}if(s.chunk==s.chunks-1){r.status=c.DONE;q.trigger("FileUploaded",r,{response:s.text})}});g.bind("Flash:SelectFiles",function(q,t){var s,r,u=[],v;for(r=0;r<t.length;r++){s=t[r];v=c.guid();p[v]=s.id;p[s.id]=v;u.push(new c.File(v,s.name,s.size))}if(u.length){g.trigger("FilesAdded",u)}});g.bind("Flash:SecurityError",function(q,r){g.trigger("Error",{code:c.SECURITY_ERROR,message:"Security error.",details:r.message,file:g.getFile(p[r.id])})});g.bind("Flash:GenericError",function(q,r){g.trigger("Error",{code:c.GENERIC_ERROR,message:"Generic error.",details:r.message,file:g.getFile(p[r.id])})});g.bind("Flash:IOError",function(q,r){g.trigger("Error",{code:c.IO_ERROR,message:"IO error.",details:r.message,file:g.getFile(p[r.id])})});g.bind("QueueChanged",function(q){g.refresh()});g.bind("FilesRemoved",function(q,s){var r;for(r=0;r<s.length;r++){j().removeFile(p[s[r].id])}});g.bind("StateChanged",function(q){g.refresh()});g.bind("Refresh",function(q){var r,s,t;j().setFileFilters(g.settings.filters,g.settings.multi_selection);r=document.getElementById(q.settings.browse_button);s=c.getPos(r,document.getElementById(q.settings.container));t=c.getSize(r);c.extend(document.getElementById(q.id+"_flash_container").style,{top:s.y+"px",left:s.x+"px",width:t.w+"px",height:t.h+"px"})});g.features={jpgresize:true,pngresize:true,chunks:true,progress:true};l({success:true})})}})})(plupload);(function(a){a.runtimes.BrowserPlus=a.addRuntime("browserplus",{init:function(g,i){var e=window.BrowserPlus,h={},d=g.settings,c=d.resize;function f(n){var m,l,j=[],k,o;for(l=0;l<n.length;l++){k=n[l];o=a.guid();h[o]=k;j.push(new a.File(o,k.name,k.size))}if(l){g.trigger("FilesAdded",j)}}function b(){g.bind("PostInit",function(){var m,k=d.drop_element,o=g.id+"_droptarget",j=document.getElementById(k),l;function p(r,q){e.DragAndDrop.AddDropTarget({id:r},function(s){e.DragAndDrop.AttachCallbacks({id:r,hover:function(t){if(!t&&q){q()}},drop:function(t){if(q){q()}f(t)}},function(){})})}function n(){document.getElementById(o).style.top="-1000px"}if(j){if(document.attachEvent&&(/MSIE/gi).test(navigator.userAgent)){m=document.createElement("div");m.setAttribute("id",o);a.extend(m.style,{position:"absolute",top:"-1000px",background:"red",filter:"alpha(opacity=0)",opacity:0});document.body.appendChild(m);a.addEvent(j,"dragenter",function(r){var q,s;q=document.getElementById(k);s=a.getPos(q);a.extend(document.getElementById(o).style,{top:s.y+"px",left:s.x+"px",width:q.offsetWidth+"px",height:q.offsetHeight+"px"})});p(o,n)}else{p(k)}}a.addEvent(document.getElementById(d.browse_button),"click",function(v){var t=[],r,q,u=d.filters,s;v.preventDefault();for(r=0;r<u.length;r++){s=u[r].extensions.split(",");for(q=0;q<s.length;q++){t.push(a.mimeTypes[s[q]])}}e.FileBrowse.OpenBrowseDialog({mimeTypes:t},function(w){if(w.success){f(w.value)}})});j=m=null});g.bind("UploadFile",function(n,k){var m=h[k.id],j={},l=n.settings.chunk_size,o,p=[];function r(s,u){var t;if(k.status==a.FAILED){return}j.name=k.target_name||k.name;if(l){j.chunk=s;j.chunks=u}t=p.shift();e.Uploader.upload({url:a.buildUrl(n.settings.url,j),files:{file:t},cookies:document.cookies,postvars:n.settings.multipart_params,progressCallback:function(x){var w,v=0;o[s]=parseInt(x.filePercent*t.size/100,10);for(w=0;w<o.length;w++){v+=o[w]}k.loaded=v;n.trigger("UploadProgress",k)}},function(w){var v,x;if(w.success){v=w.value.statusCode;if(l){n.trigger("ChunkUploaded",k,{chunk:s,chunks:u,response:w.value.body,status:v})}if(p.length>0){r(++s,u)}else{k.status=a.DONE;n.trigger("FileUploaded",k,{response:w.value.body,status:v});if(v>=400){n.trigger("Error",{code:a.HTTP_ERROR,message:"HTTP Error.",file:k,status:v})}}}else{n.trigger("Error",{code:a.GENERIC_ERROR,message:"Generic Error.",file:k,details:w.error})}})}function q(s){k.size=s.size;if(l){e.FileAccess.chunk({file:s,chunkSize:l},function(v){if(v.success){var w=v.value,t=w.length;o=Array(t);for(var u=0;u<t;u++){o[u]=0;p.push(w[u])}r(0,t)}})}else{o=Array(1);p.push(s);r(0,1)}}if(c&&/\.(png|jpg|jpeg)$/i.test(k.name)){BrowserPlus.ImageAlter.transform({file:m,quality:c.quality||90,actions:[{scale:{maxwidth:c.width,maxheight:c.height}}]},function(s){if(s.success){q(s.value.file)}})}else{q(m)}});g.features={dragdrop:true,jpgresize:true,pngresize:true,chunks:true,progress:true};i({success:true})}if(e){e.init(function(k){var j=[{service:"Uploader",version:"3"},{service:"DragAndDrop",version:"1"},{service:"FileBrowse",version:"1"},{service:"FileAccess",version:"2"}];if(c){j.push({service:"ImageAlter",version:"4"})}if(k.success){e.require({services:j},function(l){if(l.success){b()}else{i()}})}else{i()}})}else{i()}}})})(plupload);(function(b){function a(i,l,j,c,k){var e,d,h,g,f;e=document.createElement("canvas");e.style.display="none";document.body.appendChild(e);d=e.getContext("2d");h=new Image();h.onload=function(){var o,m,n;f=Math.min(l/h.width,j/h.height);if(f<1){o=Math.round(h.width*f);m=Math.round(h.height*f)}else{o=h.width;m=h.height}e.width=o;e.height=m;d.drawImage(h,0,0,o,m);g=e.toDataURL(c);g=g.substring(g.indexOf("base64,")+7);g=atob(g);e.parentNode.removeChild(e);k({success:true,data:g})};h.src=i}b.runtimes.Html5=b.addRuntime("html5",{init:function(g,i){var c={},d,h;function f(m){var k,j,l=[],n;for(j=0;j<m.length;j++){k=m[j];n=b.guid();c[n]=k;l.push(new b.File(n,k.fileName,k.fileSize))}if(l.length){g.trigger("FilesAdded",l)}}function e(){var j;if(window.XMLHttpRequest){j=new XMLHttpRequest();h=!!j.upload;return !!(j.sendAsBinary||j.upload)}return false}if(!e()){i({success:false});return}g.bind("Init",function(n){var r,p=[],m,q,k=n.settings.filters,l,o,j=document.body;r=document.createElement("div");r.id=n.id+"_html5_container";for(m=0;m<k.length;m++){l=k[m].extensions.split(/,/);for(q=0;q<l.length;q++){o=b.mimeTypes[l[q]];if(o){p.push(o)}}}b.extend(r.style,{position:"absolute",background:g.settings.shim_bgcolor||"transparent",width:"100px",height:"100px",overflow:"hidden",zIndex:99999,opacity:g.settings.shim_bgcolor?"":0});r.className="plupload html5";if(g.settings.container){j=document.getElementById(g.settings.container);j.style.position="relative"}j.appendChild(r);r.innerHTML='<input id="'+g.id+'_html5" style="width:100%;" type="file" accept="'+p.join(",")+'" '+(g.settings.multi_selection?'multiple="multiple"':"")+" />";document.getElementById(g.id+"_html5").onchange=function(){f(this.files);this.value=""}});g.bind("PostInit",function(){var j=document.getElementById(g.settings.drop_element);if(j){b.addEvent(j,"dragover",function(k){k.preventDefault()});b.addEvent(j,"drop",function(l){var k=l.dataTransfer;if(k&&k.files){f(k.files)}l.preventDefault()})}});g.bind("Refresh",function(j){var k,l,m;k=document.getElementById(g.settings.browse_button);l=b.getPos(k,document.getElementById(j.settings.container));m=b.getSize(k);b.extend(document.getElementById(g.id+"_html5_container").style,{top:l.y+"px",left:l.x+"px",width:m.w+"px",height:m.h+"px"})});g.bind("UploadFile",function(j,m){var q=new XMLHttpRequest(),l=q.upload,k=j.settings.resize,p,o=0;function n(r){var v="----pluploadboundary"+b.guid(),t="--",u="\r\n",s="";if(j.settings.multipart){q.setRequestHeader("Content-Type","multipart/form-data; boundary="+v);b.each(j.settings.multipart_params,function(x,w){s+=t+v+u+'Content-Disposition: form-data; name="'+w+'"'+u+u;s+=x+u});s+=t+v+u+'Content-Disposition: form-data; name="'+j.settings.file_data_name+'"; filename="'+m.name+'"'+u+"Content-Type: application/octet-stream"+u+u+r+u+t+v+t+u;o=s.length-r.length;r=s}q.sendAsBinary(r)}if(m.status==b.DONE||m.status==b.FAILED||j.state==b.STOPPED){return}if(l){l.onprogress=function(r){m.loaded=r.loaded-o;j.trigger("UploadProgress",m)}}q.onreadystatechange=function(){var r;if(q.readyState==4){try{r=q.status}catch(s){r=0}m.status=b.DONE;m.loaded=m.size;j.trigger("UploadProgress",m);j.trigger("FileUploaded",m,{response:q.responseText,status:r});if(r>=400){j.trigger("Error",{code:b.HTTP_ERROR,message:"HTTP Error.",file:m,status:r})}}};q.open("post",b.buildUrl(j.settings.url,{name:m.target_name||m.name}),true);q.setRequestHeader("Content-Type","application/octet-stream");b.each(j.settings.headers,function(s,r){q.setRequestHeader(r,s)});p=c[m.id];if(q.sendAsBinary){if(k&&/\.(png|jpg|jpeg)$/i.test(m.name)){a(p.getAsDataURL(),k.width,k.height,/\.png$/i.test(m.name)?"image/png":"image/jpeg",function(r){if(r.success){m.size=r.data.length;n(r.data)}else{n(p.getAsBinary())}})}else{n(p.getAsBinary())}}else{q.send(p)}});d=!!(File&&File.prototype.getAsDataURL);g.features={dragdrop:window.mozInnerScreenX!==undefined,jpgresize:d,pngresize:d,progress:h};i({success:true})}})})(plupload);(function(a){a.runtimes.Html4=a.addRuntime("html4",{init:function(f,g){var d={},c,b;function e(l){var k,j,m=[],n,h;h=l.value.replace(/\\/g,"/");h=h.substring(h.length,h.lastIndexOf("/")+1);n=a.guid();k=new a.File(n,h);d[n]=k;k.input=l;m.push(k);if(m.length){f.trigger("FilesAdded",m)}}f.bind("Init",function(p){var h,x,v,t=[],o,u,m=p.settings.filters,l,s,r=/MSIE/.test(navigator.userAgent),k="javascript",w,j=document.body,n;if(f.settings.container){j=document.getElementById(f.settings.container);j.style.position="relative"}c=(typeof p.settings.form=="string")?document.getElementById(p.settings.form):p.settings.form;if(!c){n=document.getElementById(f.settings.browse_button);for(;n;n=n.parentNode){if(n.nodeName=="FORM"){c=n}}}if(!c){c=document.createElement("form");c.style.display="inline";n=document.getElementById(f.settings.container);n.parentNode.insertBefore(c,n);c.appendChild(n)}c.setAttribute("method","post");c.setAttribute("enctype","multipart/form-data");a.each(p.settings.multipart_params,function(z,y){var i=document.createElement("input");a.extend(i,{type:"hidden",name:y,value:z});c.appendChild(i)});b=document.createElement("iframe");b.setAttribute("src",k+':""');b.setAttribute("name",p.id+"_iframe");b.setAttribute("id",p.id+"_iframe");b.style.display="none";a.addEvent(b,"load",function(B){var C=B.target,z=f.currentfile,A;try{A=C.contentWindow.document||C.contentDocument||window.frames[C.id].document}catch(y){p.trigger("Error",{code:a.SECURITY_ERROR,message:"Security error.",file:z});return}if(A.location.href=="about:blank"||!z){return}var i=A.documentElement.innerText||A.documentElement.textContent;if(i!=""){z.status=a.DONE;z.loaded=1025;z.percent=100;if(z.input){z.input.removeAttribute("name")}p.trigger("UploadProgress",z);p.trigger("FileUploaded",z,{response:i});if(c.tmpAction){c.setAttribute("action",c.tmpAction)}if(c.tmpTarget){c.setAttribute("target",c.tmpTarget)}}});c.appendChild(b);if(r){window.frames[b.id].name=b.name}x=document.createElement("div");x.id=p.id+"_iframe_container";for(o=0;o<m.length;o++){l=m[o].extensions.split(/,/);for(u=0;u<l.length;u++){s=a.mimeTypes[l[u]];if(s){t.push(s)}}}a.extend(x.style,{position:"absolute",background:"transparent",width:"100px",height:"100px",overflow:"hidden",zIndex:99999,opacity:0});w=f.settings.shim_bgcolor;if(w){a.extend(x.style,{background:w,opacity:1})}x.className="plupload_iframe";j.appendChild(x);function q(){v=document.createElement("input");v.setAttribute("type","file");v.setAttribute("accept",t.join(","));v.setAttribute("size",1);a.extend(v.style,{width:"100%",height:"100%",opacity:0});if(r){a.extend(v.style,{filter:"alpha(opacity=0)"})}a.addEvent(v,"change",function(i){var y=i.target;if(y.value){q();y.style.display="none";e(y)}});x.appendChild(v);return true}q()});f.bind("Refresh",function(h){var i,j,k;i=document.getElementById(f.settings.browse_button);j=a.getPos(i,document.getElementById(h.settings.container));k=a.getSize(i);a.extend(document.getElementById(f.id+"_iframe_container").style,{top:j.y+"px",left:j.x+"px",width:k.w+"px",height:k.h+"px"})});f.bind("UploadFile",function(h,i){if(i.status==a.DONE||i.status==a.FAILED||h.state==a.STOPPED){return}if(!i.input){i.status=a.ERROR;return}i.input.setAttribute("name",h.settings.file_data_name);c.tmpAction=c.getAttribute("action");c.setAttribute("action",a.buildUrl(h.settings.url,{name:i.target_name||i.name}));c.tmpTarget=c.getAttribute("target");c.setAttribute("target",b.name);this.currentfile=i;c.submit()});f.bind("FilesRemoved",function(h,k){var j,l;for(j=0;j<k.length;j++){l=k[j].input;if(l){l.parentNode.removeChild(l)}}});f.features={};g({success:true})}})})(plupload); | |
\ No newline at end of file |
@@ -1 +0,0 @@ | ||
1 | -(function(b){var c={};function a(i,e,k,j,d){var l,g,f,h;g=google.gears.factory.create("beta.canvas");g.decode(i);h=Math.min(e/g.width,k/g.height);if(h<1){e=Math.round(g.width*h);k=Math.round(g.height*h)}else{e=g.width;k=g.height}g.resize(e,k);return g.encode(d,{quality:j/100})}b.runtimes.Gears=b.addRuntime("gears",{init:function(g,i){var h;if(!window.google||!google.gears){return i({success:false})}try{h=google.gears.factory.create("beta.desktop")}catch(f){return i({success:false})}function d(k){var j,e,l=[],m;for(e=0;e<k.length;e++){j=k[e];m=b.guid();c[m]=j.blob;l.push(new b.File(m,j.name,j.blob.length))}g.trigger("FilesAdded",l)}g.bind("PostInit",function(){var j=g.settings,e=document.getElementById(j.drop_element);if(e){b.addEvent(e,"dragover",function(k){h.setDropEffect(k,"copy");k.preventDefault()});b.addEvent(e,"drop",function(l){var k=h.getDragData(l,"application/x-gears-files");if(k){d(k.files)}l.preventDefault()});e=0}b.addEvent(document.getElementById(j.browse_button),"click",function(o){var n=[],l,k,m;o.preventDefault();for(l=0;l<j.filters.length;l++){m=j.filters[l].extensions.split(",");for(k=0;k<m.length;k++){n.push("."+m[k])}}h.openFiles(d,{singleFile:!j.multi_selection,filter:n})})});g.bind("UploadFile",function(o,l){var q=0,p,m,n=0,k=o.settings.resize,e;m=o.settings.chunk_size;e=m>0;p=Math.ceil(l.size/m);if(!e){m=l.size;p=1}if(k&&/\.(png|jpg|jpeg)$/i.test(l.name)){c[l.id]=a(c[l.id],k.width,k.height,k.quality||90,/\.png$/i.test(l.name)?"image/png":"image/jpeg")}l.size=c[l.id].length;function j(){var u,w,s=o.settings.multipart,r=0,v={name:l.target_name||l.name};function t(y){var x,C="----pluploadboundary"+b.guid(),A="--",B="\r\n",z;if(s){u.setRequestHeader("Content-Type","multipart/form-data; boundary="+C);x=google.gears.factory.create("beta.blobbuilder");b.each(o.settings.multipart_params,function(E,D){x.append(A+C+B+'Content-Disposition: form-data; name="'+D+'"'+B+B);x.append(E+B)});x.append(A+C+B+'Content-Disposition: form-data; name="'+o.settings.file_data_name+'"; filename="'+l.name+'"'+B+"Content-Type: application/octet-stream"+B+B);x.append(y);x.append(B+A+C+A+B);z=x.getAsBlob();r=z.length-y.length;y=z}u.send(y)}if(l.status==b.DONE||l.status==b.FAILED||o.state==b.STOPPED){return}if(e){v.chunk=q;v.chunks=p}w=Math.min(m,l.size-(q*m));u=google.gears.factory.create("beta.httprequest");u.open("POST",b.buildUrl(o.settings.url,v));if(!s){u.setRequestHeader("Content-Disposition",'attachment; filename="'+l.name+'"');u.setRequestHeader("Content-Type","application/octet-stream")}b.each(o.settings.headers,function(y,x){u.setRequestHeader(x,y)});u.upload.onprogress=function(x){l.loaded=n+x.loaded-r;o.trigger("UploadProgress",l)};u.onreadystatechange=function(){var x;if(u.readyState==4){if(u.status==200){x={chunk:q,chunks:p,response:u.responseText,status:u.status};o.trigger("ChunkUploaded",l,x);if(x.cancelled){l.status=b.FAILED;return}n+=w;if(++q>=p){l.status=b.DONE;o.trigger("FileUploaded",l,{response:u.responseText,status:u.status})}else{j()}}else{o.trigger("Error",{code:b.HTTP_ERROR,message:"HTTP Error.",file:l,chunk:q,chunks:p,status:u.status})}}};if(q<p){t(c[l.id].slice(q*m,w))}}j()});g.features={dragdrop:true,jpgresize:true,pngresize:true,chunks:true,progress:true};i({success:true})}})})(plupload); | |
\ No newline at end of file |
@@ -1 +0,0 @@ | ||
1 | -(function(a){a.runtimes.Html4=a.addRuntime("html4",{init:function(f,g){var d={},c,b;function e(l){var k,j,m=[],n,h;h=l.value.replace(/\\/g,"/");h=h.substring(h.length,h.lastIndexOf("/")+1);n=a.guid();k=new a.File(n,h);d[n]=k;k.input=l;m.push(k);if(m.length){f.trigger("FilesAdded",m)}}f.bind("Init",function(p){var h,x,v,t=[],o,u,m=p.settings.filters,l,s,r=/MSIE/.test(navigator.userAgent),k="javascript",w,j=document.body,n;if(f.settings.container){j=document.getElementById(f.settings.container);j.style.position="relative"}c=(typeof p.settings.form=="string")?document.getElementById(p.settings.form):p.settings.form;if(!c){n=document.getElementById(f.settings.browse_button);for(;n;n=n.parentNode){if(n.nodeName=="FORM"){c=n}}}if(!c){c=document.createElement("form");c.style.display="inline";n=document.getElementById(f.settings.container);n.parentNode.insertBefore(c,n);c.appendChild(n)}c.setAttribute("method","post");c.setAttribute("enctype","multipart/form-data");a.each(p.settings.multipart_params,function(z,y){var i=document.createElement("input");a.extend(i,{type:"hidden",name:y,value:z});c.appendChild(i)});b=document.createElement("iframe");b.setAttribute("src",k+':""');b.setAttribute("name",p.id+"_iframe");b.setAttribute("id",p.id+"_iframe");b.style.display="none";a.addEvent(b,"load",function(B){var C=B.target,z=f.currentfile,A;try{A=C.contentWindow.document||C.contentDocument||window.frames[C.id].document}catch(y){p.trigger("Error",{code:a.SECURITY_ERROR,message:"Security error.",file:z});return}if(A.location.href=="about:blank"||!z){return}var i=A.documentElement.innerText||A.documentElement.textContent;if(i!=""){z.status=a.DONE;z.loaded=1025;z.percent=100;if(z.input){z.input.removeAttribute("name")}p.trigger("UploadProgress",z);p.trigger("FileUploaded",z,{response:i});if(c.tmpAction){c.setAttribute("action",c.tmpAction)}if(c.tmpTarget){c.setAttribute("target",c.tmpTarget)}}});c.appendChild(b);if(r){window.frames[b.id].name=b.name}x=document.createElement("div");x.id=p.id+"_iframe_container";for(o=0;o<m.length;o++){l=m[o].extensions.split(/,/);for(u=0;u<l.length;u++){s=a.mimeTypes[l[u]];if(s){t.push(s)}}}a.extend(x.style,{position:"absolute",background:"transparent",width:"100px",height:"100px",overflow:"hidden",zIndex:99999,opacity:0});w=f.settings.shim_bgcolor;if(w){a.extend(x.style,{background:w,opacity:1})}x.className="plupload_iframe";j.appendChild(x);function q(){v=document.createElement("input");v.setAttribute("type","file");v.setAttribute("accept",t.join(","));v.setAttribute("size",1);a.extend(v.style,{width:"100%",height:"100%",opacity:0});if(r){a.extend(v.style,{filter:"alpha(opacity=0)"})}a.addEvent(v,"change",function(i){var y=i.target;if(y.value){q();y.style.display="none";e(y)}});x.appendChild(v);return true}q()});f.bind("Refresh",function(h){var i,j,k;i=document.getElementById(f.settings.browse_button);j=a.getPos(i,document.getElementById(h.settings.container));k=a.getSize(i);a.extend(document.getElementById(f.id+"_iframe_container").style,{top:j.y+"px",left:j.x+"px",width:k.w+"px",height:k.h+"px"})});f.bind("UploadFile",function(h,i){if(i.status==a.DONE||i.status==a.FAILED||h.state==a.STOPPED){return}if(!i.input){i.status=a.ERROR;return}i.input.setAttribute("name",h.settings.file_data_name);c.tmpAction=c.getAttribute("action");c.setAttribute("action",a.buildUrl(h.settings.url,{name:i.target_name||i.name}));c.tmpTarget=c.getAttribute("target");c.setAttribute("target",b.name);this.currentfile=i;c.submit()});f.bind("FilesRemoved",function(h,k){var j,l;for(j=0;j<k.length;j++){l=k[j].input;if(l){l.parentNode.removeChild(l)}}});f.features={};g({success:true})}})})(plupload); | |
\ No newline at end of file |
@@ -1 +0,0 @@ | ||
1 | -(function(b){function a(i,l,j,c,k){var e,d,h,g,f;e=document.createElement("canvas");e.style.display="none";document.body.appendChild(e);d=e.getContext("2d");h=new Image();h.onload=function(){var o,m,n;f=Math.min(l/h.width,j/h.height);if(f<1){o=Math.round(h.width*f);m=Math.round(h.height*f)}else{o=h.width;m=h.height}e.width=o;e.height=m;d.drawImage(h,0,0,o,m);g=e.toDataURL(c);g=g.substring(g.indexOf("base64,")+7);g=atob(g);e.parentNode.removeChild(e);k({success:true,data:g})};h.src=i}b.runtimes.Html5=b.addRuntime("html5",{init:function(g,i){var c={},d,h;function f(m){var k,j,l=[],n;for(j=0;j<m.length;j++){k=m[j];n=b.guid();c[n]=k;l.push(new b.File(n,k.fileName,k.fileSize))}if(l.length){g.trigger("FilesAdded",l)}}function e(){var j;if(window.XMLHttpRequest){j=new XMLHttpRequest();h=!!j.upload;return !!(j.sendAsBinary||j.upload)}return false}if(!e()){i({success:false});return}g.bind("Init",function(n){var r,p=[],m,q,k=n.settings.filters,l,o,j=document.body;r=document.createElement("div");r.id=n.id+"_html5_container";for(m=0;m<k.length;m++){l=k[m].extensions.split(/,/);for(q=0;q<l.length;q++){o=b.mimeTypes[l[q]];if(o){p.push(o)}}}b.extend(r.style,{position:"absolute",background:g.settings.shim_bgcolor||"transparent",width:"100px",height:"100px",overflow:"hidden",zIndex:99999,opacity:g.settings.shim_bgcolor?"":0});r.className="plupload html5";if(g.settings.container){j=document.getElementById(g.settings.container);j.style.position="relative"}j.appendChild(r);r.innerHTML='<input id="'+g.id+'_html5" style="width:100%;" type="file" accept="'+p.join(",")+'" '+(g.settings.multi_selection?'multiple="multiple"':"")+" />";document.getElementById(g.id+"_html5").onchange=function(){f(this.files);this.value=""}});g.bind("PostInit",function(){var j=document.getElementById(g.settings.drop_element);if(j){b.addEvent(j,"dragover",function(k){k.preventDefault()});b.addEvent(j,"drop",function(l){var k=l.dataTransfer;if(k&&k.files){f(k.files)}l.preventDefault()})}});g.bind("Refresh",function(j){var k,l,m;k=document.getElementById(g.settings.browse_button);l=b.getPos(k,document.getElementById(j.settings.container));m=b.getSize(k);b.extend(document.getElementById(g.id+"_html5_container").style,{top:l.y+"px",left:l.x+"px",width:m.w+"px",height:m.h+"px"})});g.bind("UploadFile",function(j,m){var q=new XMLHttpRequest(),l=q.upload,k=j.settings.resize,p,o=0;function n(r){var v="----pluploadboundary"+b.guid(),t="--",u="\r\n",s="";if(j.settings.multipart){q.setRequestHeader("Content-Type","multipart/form-data; boundary="+v);b.each(j.settings.multipart_params,function(x,w){s+=t+v+u+'Content-Disposition: form-data; name="'+w+'"'+u+u;s+=x+u});s+=t+v+u+'Content-Disposition: form-data; name="'+j.settings.file_data_name+'"; filename="'+m.name+'"'+u+"Content-Type: application/octet-stream"+u+u+r+u+t+v+t+u;o=s.length-r.length;r=s}q.sendAsBinary(r)}if(m.status==b.DONE||m.status==b.FAILED||j.state==b.STOPPED){return}if(l){l.onprogress=function(r){m.loaded=r.loaded-o;j.trigger("UploadProgress",m)}}q.onreadystatechange=function(){var r;if(q.readyState==4){try{r=q.status}catch(s){r=0}m.status=b.DONE;m.loaded=m.size;j.trigger("UploadProgress",m);j.trigger("FileUploaded",m,{response:q.responseText,status:r});if(r>=400){j.trigger("Error",{code:b.HTTP_ERROR,message:"HTTP Error.",file:m,status:r})}}};q.open("post",b.buildUrl(j.settings.url,{name:m.target_name||m.name}),true);q.setRequestHeader("Content-Type","application/octet-stream");b.each(j.settings.headers,function(s,r){q.setRequestHeader(r,s)});p=c[m.id];if(q.sendAsBinary){if(k&&/\.(png|jpg|jpeg)$/i.test(m.name)){a(p.getAsDataURL(),k.width,k.height,/\.png$/i.test(m.name)?"image/png":"image/jpeg",function(r){if(r.success){m.size=r.data.length;n(r.data)}else{n(p.getAsBinary())}})}else{n(p.getAsBinary())}}else{q.send(p)}});d=!!(File&&File.prototype.getAsDataURL);g.features={dragdrop:window.mozInnerScreenX!==undefined,jpgresize:d,pngresize:d,progress:h};i({success:true})}})})(plupload); | |
\ No newline at end of file |
@@ -1 +0,0 @@ | ||
1 | -(function(){var c=0,h=[],j={},f={},a={"<":"lt",">":"gt","&":"amp",'"':"quot","'":"#39"},i=/[<>&\"\']/g,b;function e(){this.returnValue=false}function g(){this.cancelBubble=true}(function(k){var l=k.split(/,/),m,o,n;for(m=0;m<l.length;m+=2){n=l[m+1].split(/ /);for(o=0;o<n.length;o++){f[n[o]]=l[m]}}})("application/msword,doc dot,application/pdf,pdf,application/pgp-signature,pgp,application/postscript,ps ai eps,application/rtf,rtf,application/vnd.ms-excel,xls xlb,application/vnd.ms-powerpoint,ppt pps pot,application/zip,zip,application/x-shockwave-flash,swf swfl,application/vnd.openxmlformats,docx pptx xlsx,audio/mpeg,mpga mpega mp2 mp3,audio/x-wav,wav,image/bmp,bmp,image/gif,gif,image/jpeg,jpeg jpg jpe,image/png,png,image/svg+xml,svg svgz,image/tiff,tiff tif,text/html,htm html xhtml,text/rtf,rtf,video/mpeg,mpeg mpg mpe,video/quicktime,qt mov,video/x-flv,flv,video/vnd.rn-realvideo,rv,text/plain,asc txt text diff log,application/octet-stream,exe");var d={STOPPED:1,STARTED:2,QUEUED:1,UPLOADING:2,FAILED:4,DONE:5,GENERIC_ERROR:-100,HTTP_ERROR:-200,IO_ERROR:-300,SECURITY_ERROR:-400,INIT_ERROR:-500,FILE_SIZE_ERROR:-600,FILE_EXTENSION_ERROR:-700,mimeTypes:f,extend:function(k){d.each(arguments,function(l,m){if(m>0){d.each(l,function(o,n){k[n]=o})}});return k},cleanName:function(k){var l,m;m=[/[\300-\306]/g,"A",/[\340-\346]/g,"a",/\307/g,"C",/\347/g,"c",/[\310-\313]/g,"E",/[\350-\353]/g,"e",/[\314-\317]/g,"I",/[\354-\357]/g,"i",/\321/g,"N",/\361/g,"n",/[\322-\330]/g,"O",/[\362-\370]/g,"o",/[\331-\334]/g,"U",/[\371-\374]/g,"u"];for(l=0;l<m.length;l+=2){k=k.replace(m[l],m[l+1])}k=k.replace(/\s+/g,"_");k=k.replace(/[^a-z0-9_\-\.]+/gi,"");return k},addRuntime:function(k,l){l.name=k;h[k]=l;h.push(l);return l},guid:function(){var k=new Date().getTime().toString(32),l;for(l=0;l<5;l++){k+=Math.floor(Math.random()*65535).toString(32)}return(d.guidPrefix||"p")+k+(c++).toString(32)},buildUrl:function(l,k){var m="";d.each(k,function(o,n){m+=(m?"&":"")+encodeURIComponent(n)+"="+encodeURIComponent(o)});if(m){l+=(l.indexOf("?")>0?"&":"?")+m}return l},each:function(n,o){var m,l,k;if(n){m=n.length;if(m===b){for(l in n){if(n.hasOwnProperty(l)){if(o(n[l],l)===false){return}}}}else{for(k=0;k<m;k++){if(o(n[k],k)===false){return}}}}},formatSize:function(k){if(k===b){return d.translate("N/A")}if(k>1048576){return Math.round(k/1048576,1)+" MB"}if(k>1024){return Math.round(k/1024,1)+" KB"}return k+" b"},getPos:function(l,p){var q=0,o=0,s,r=document,m,n;l=l;p=p||r.body;function k(w){var u,v,t=0,z=0;if(w){v=w.getBoundingClientRect();u=r.compatMode==="CSS1Compat"?r.documentElement:r.body;t=v.left+u.scrollLeft;z=v.top+u.scrollTop}return{x:t,y:z}}if(l.getBoundingClientRect&&(navigator.userAgent.indexOf("MSIE")>0&&r.documentMode!==8)){m=k(l);n=k(p);return{x:m.x-n.x,y:m.y-n.y}}s=l;while(s&&s!=p&&s.nodeType){q+=s.offsetLeft||0;o+=s.offsetTop||0;s=s.offsetParent}s=l.parentNode;while(s&&s!=p&&s.nodeType){q-=s.scrollLeft||0;o-=s.scrollTop||0;s=s.parentNode}return{x:q,y:o}},getSize:function(k){return{w:k.clientWidth||k.offsetWidth,h:k.clientHeight||k.offsetHeight}},parseSize:function(k){var l;if(typeof(k)=="string"){k=/^([0-9]+)([mgk]+)$/.exec(k.toLowerCase().replace(/[^0-9mkg]/g,""));l=k[2];k=+k[1];if(l=="g"){k*=1073741824}if(l=="m"){k*=1048576}if(l=="k"){k*=1024}}return k},xmlEncode:function(k){return k?(""+k).replace(i,function(l){return a[l]?"&"+a[l]+";":l}):k},toArray:function(m){var l,k=[];for(l=0;l<m.length;l++){k[l]=m[l]}return k},addI18n:function(k){return d.extend(j,k)},translate:function(k){return j[k]||k},addEvent:function(l,k,m){if(l.attachEvent){l.attachEvent("on"+k,function(){var n=window.event;if(!n.target){n.target=n.srcElement}n.preventDefault=e;n.stopPropagation=g;m(n)})}else{if(l.addEventListener){l.addEventListener(k,m,false)}}}};d.Uploader=function(n){var l={},q,p=[],r,m;q=new d.QueueProgress();n=d.extend({chunk_size:0,max_file_size:"1gb",multi_selection:true,file_data_name:"file",filters:[]},n);function o(){var s;if(this.state==d.STARTED&&r<p.length){s=p[r++];if(s.status==d.QUEUED){this.trigger("UploadFile",s)}else{o.call(this)}}else{this.stop()}}function k(){var t,s;q.reset();for(t=0;t<p.length;t++){s=p[t];if(s.size!==b){q.size+=s.size;q.loaded+=s.loaded}else{q.size=b}if(s.status==d.DONE){q.uploaded++}else{if(s.status==d.FAILED){q.failed++}else{q.queued++}}}if(q.size===b){q.percent=p.length>0?Math.ceil(q.uploaded/p.length*100):0}else{q.bytesPerSec=Math.ceil(q.loaded/((+new Date()-m||1)/1000));q.percent=q.size>0?Math.ceil(q.loaded/q.size*100):0}}d.extend(this,{state:d.STOPPED,features:{},files:p,settings:n,total:q,id:d.guid(),init:function(){var x=this,y,u,t,w=0,v;n.page_url=n.page_url||document.location.pathname.replace(/\/[^\/]+$/g,"/");if(!/^(\w+:\/\/|\/)/.test(n.url)){n.url=n.page_url+n.url}n.chunk_size=d.parseSize(n.chunk_size);n.max_file_size=d.parseSize(n.max_file_size);x.bind("FilesAdded",function(z,C){var B,A,F=0,E,D=n.filters;if(D&&D.length){E={};d.each(D,function(G){d.each(G.extensions.split(/,/),function(H){E[H.toLowerCase()]=true})})}for(B=0;B<C.length;B++){A=C[B];A.loaded=0;A.percent=0;A.status=d.QUEUED;if(E&&!E[A.name.toLowerCase().split(".").slice(-1)]){z.trigger("Error",{code:d.FILE_EXTENSION_ERROR,message:"File extension error.",file:A});continue}if(A.size!==b&&A.size>n.max_file_size){z.trigger("Error",{code:d.FILE_SIZE_ERROR,message:"File size error.",file:A});continue}p.push(A);F++}if(F){x.trigger("QueueChanged");x.refresh()}});if(n.unique_names){x.bind("UploadFile",function(z,A){A.target_name=A.id+".tmp"})}x.bind("UploadProgress",function(z,A){if(A.status==d.QUEUED){A.status=d.UPLOADING}A.percent=A.size>0?Math.ceil(A.loaded/A.size*100):100;k()});x.bind("StateChanged",function(z){if(z.state==d.STARTED){m=(+new Date())}});x.bind("QueueChanged",k);x.bind("Error",function(z,A){if(A.file){A.file.status=d.FAILED;k();window.setTimeout(function(){o.call(x)})}});x.bind("FileUploaded",function(z,A){A.status=d.DONE;z.trigger("UploadProgress",A);o.call(x)});if(n.runtimes){u=[];v=n.runtimes.split(/\s?,\s?/);for(y=0;y<v.length;y++){if(h[v[y]]){u.push(h[v[y]])}}}else{u=h}function s(){var z=u[w++];if(z){z.init(x,function(C){var A,B;if(C&&C.success){A=x.settings.required_features;if(A){A=A.split(",");for(B=0;B<A.length;B++){if(!x.features[A[B]]){s();return}}}x.trigger("Init",{runtime:z.name});x.trigger("PostInit");x.refresh()}else{s()}})}else{x.trigger("Error",{code:d.INIT_ERROR,message:"Init error."})}}s()},refresh:function(){this.trigger("Refresh")},start:function(){if(this.state!=d.STARTED){r=0;this.state=d.STARTED;this.trigger("StateChanged");o.call(this)}},stop:function(){if(this.state!=d.STOPPED){this.state=d.STOPPED;this.trigger("StateChanged")}},getFile:function(t){var s;for(s=p.length-1;s>=0;s--){if(p[s].id===t){return p[s]}}},removeFile:function(t){var s;for(s=p.length-1;s>=0;s--){if(p[s].id===t.id){return this.splice(s,1)[0]}}},splice:function(u,s){var t;t=p.splice(u,s);this.trigger("FilesRemoved",t);this.trigger("QueueChanged");return t},trigger:function(t){var v=l[t.toLowerCase()],u,s;if(v){s=Array.prototype.slice.call(arguments);s[0]=this;for(u=0;u<v.length;u++){if(v[u].func.apply(v[u].scope,s)===false){return false}}}return true},bind:function(s,u,t){var v;s=s.toLowerCase();v=l[s]||[];v.push({func:u,scope:t||this});l[s]=v},unbind:function(s,u){var v=l[s.toLowerCase()],t;if(v){for(t=v.length-1;t>=0;t--){if(v[t].func===u){v.splice(t,1)}}}}})};d.File=function(n,l,m){var k=this;k.id=n;k.name=l;k.size=m;k.loaded=0;k.percent=0;k.status=0};d.Runtime=function(){this.init=function(k,l){}};d.QueueProgress=function(){var k=this;k.size=0;k.loaded=0;k.uploaded=0;k.failed=0;k.queued=0;k.percent=0;k.bytesPerSec=0;k.reset=function(){k.size=k.loaded=k.uploaded=k.failed=k.queued=k.percent=k.bytesPerSec=0}};d.runtimes={};window.plupload=d})(); | |
\ No newline at end of file |
@@ -1 +0,0 @@ | ||
1 | -(function(c){var a={};function b(l){var k,j=typeof l,h,e,g,f;if(j==="string"){k="\bb\tt\nn\ff\rr\"\"''\\\\";return'"'+l.replace(/([\u0080-\uFFFF\x00-\x1f\"])/g,function(n,m){var i=k.indexOf(m);if(i+1){return"\\"+k.charAt(i+1)}n=m.charCodeAt().toString(16);return"\\u"+"0000".substring(n.length)+n})+'"'}if(j=="object"){e=l.length!==h;k="";if(e){for(g=0;g<l.length;g++){if(k){k+=","}k+=b(l[g])}k="["+k+"]"}else{for(f in l){if(l.hasOwnProperty(f)){if(k){k+=","}k+=b(f)+":"+b(l[f])}}k="{"+k+"}"}return k}if(l===h){return"null"}return""+l}function d(o){var r=false,f=null,k=null,g,h,i,q,j,m=0;try{try{k=new ActiveXObject("AgControl.AgControl");if(k.IsVersionSupported(o)){r=true}k=null}catch(n){var l=navigator.plugins["Silverlight Plug-In"];if(l){g=l.description;if(g==="1.0.30226.2"){g="2.0.30226.2"}h=g.split(".");while(h.length>3){h.pop()}while(h.length<4){h.push(0)}i=o.split(".");while(i.length>4){i.pop()}do{q=parseInt(i[m],10);j=parseInt(h[m],10);m++}while(m<i.length&&q===j);if(q<=j&&!isNaN(q)){r=true}}}}catch(p){r=false}return r}c.silverlight={trigger:function(j,f){var h=a[j],g,e;if(h){e=c.toArray(arguments).slice(1);e[0]="Silverlight:"+f;setTimeout(function(){h.trigger.apply(h,e)},0)}}};c.runtimes.Silverlight=c.addRuntime("silverlight",{init:function(l,m){var k,h="",j=l.settings.filters,g,f=document.body;if(!d("2.0.31005.0")||(window.opera&&window.opera.buildNumber)){m({success:false});return}a[l.id]=l;k=document.createElement("div");k.id=l.id+"_silverlight_container";c.extend(k.style,{position:"absolute",top:"0px",background:l.settings.shim_bgcolor||"transparent",zIndex:99999,width:"100px",height:"100px",overflow:"hidden",opacity:l.settings.shim_bgcolor?"":0.01});k.className="plupload silverlight";if(l.settings.container){f=document.getElementById(l.settings.container);f.style.position="relative"}f.appendChild(k);for(g=0;g<j.length;g++){h+=(h!=""?"|":"")+j[g].title+" | *."+j[g].extensions.replace(/,/g,";*.")}k.innerHTML='<object id="'+l.id+'_silverlight" data="data:application/x-silverlight," type="application/x-silverlight-2" style="outline:none;" width="1024" height="1024"><param name="source" value="'+l.settings.silverlight_xap_url+'"/><param name="background" value="Transparent"/><param name="windowless" value="true"/><param name="initParams" value="id='+l.id+",filter="+h+'"/></object>';function e(){return document.getElementById(l.id+"_silverlight").content.Upload}l.bind("Silverlight:Init",function(){var i,n={};l.bind("Silverlight:StartSelectFiles",function(o){i=[]});l.bind("Silverlight:SelectFile",function(o,r,p,q){var s;s=c.guid();n[s]=r;n[r]=s;i.push(new c.File(s,p,q))});l.bind("Silverlight:SelectSuccessful",function(){if(i.length){l.trigger("FilesAdded",i)}});l.bind("Silverlight:UploadChunkError",function(o,r,p,s,q){l.trigger("Error",{code:c.IO_ERROR,message:"IO Error.",details:q,file:o.getFile(n[r])})});l.bind("Silverlight:UploadFileProgress",function(o,s,p,r){var q=o.getFile(n[s]);if(q.status!=c.FAILED){q.size=r;q.loaded=p;o.trigger("UploadProgress",q)}});l.bind("Refresh",function(o){var p,q,r;p=document.getElementById(o.settings.browse_button);q=c.getPos(p,document.getElementById(o.settings.container));r=c.getSize(p);c.extend(document.getElementById(o.id+"_silverlight_container").style,{top:q.y+"px",left:q.x+"px",width:r.w+"px",height:r.h+"px"})});l.bind("Silverlight:UploadChunkSuccessful",function(o,r,p,u,t){var s,q=o.getFile(n[r]);s={chunk:p,chunks:u,response:t};o.trigger("ChunkUploaded",q,s);if(q.status!=c.FAILED){e().UploadNextChunk()}if(p==u-1){q.status=c.DONE;o.trigger("FileUploaded",q,{response:t})}});l.bind("Silverlight:UploadSuccessful",function(o,r,p){var q=o.getFile(n[r]);q.status=c.DONE;o.trigger("FileUploaded",q,{response:p})});l.bind("FilesRemoved",function(o,q){var p;for(p=0;p<q.length;p++){e().RemoveFile(n[q[p].id])}});l.bind("UploadFile",function(o,q){var r=o.settings,p=r.resize||{};e().UploadFile(n[q.id],c.buildUrl(o.settings.url,{name:q.target_name||q.name}),b({chunk_size:r.chunk_size,image_width:p.width,image_height:p.height,image_quality:p.quality||90,multipart:!!r.multipart,multipart_params:r.multipart_params||{},headers:r.headers}))});l.features={jpgresize:true,pngresize:true,chunks:true,progress:true};m({success:true})})}})})(plupload); | |
\ No newline at end of file |
@@ -1,2 +0,0 @@ | ||
1 | -<?php | |
2 | - define('NP_DRAGANDDROPUPLOADER_DESCRIPTION', 'This plugin can upload multiple files using Google Gears, Silverlight, Flash, BrowserPlus or HTML5'); |
@@ -1,2 +0,0 @@ | ||
1 | -<?php | |
2 | - define('NP_DRAGANDDROPUPLOADER_DESCRIPTION', 'このプラグインはGoogle Gears, Silverlight, Flash, BrowserPlus, HTML5等を使って複数のファイルを一度にアップロードすることができます。'); |
@@ -1,2 +0,0 @@ | ||
1 | -<?php | |
2 | - define('NP_DRAGANDDROPUPLOADER_DESCRIPTION', 'このプラグインはGoogle Gears, Silverlight, Flash, BrowserPlus, HTML5等を使って複数のファイルを一度にアップロードすることができます。'); |
@@ -1,9 +1,9 @@ | ||
1 | -#!/bin/bash -x | |
2 | - | |
3 | -FILES=`find . -name '*japanese-utf8*'` | |
4 | - | |
5 | -for utf8file in $FILES | |
6 | -do | |
7 | - eucfile=`echo $utf8file | sed 's/japanese-utf8/japanese-euc/'` | |
8 | - nkf -e -W -d < $utf8file > $eucfile | |
9 | -done | |
1 | +#!/bin/bash -x | |
2 | + | |
3 | +FILES=`find . -name '*japanese-utf8*'` | |
4 | + | |
5 | +for utf8file in $FILES | |
6 | +do | |
7 | + eucfile=`echo $utf8file | sed 's/japanese-utf8/japanese-euc/'` | |
8 | + nkf -e -W -d < $utf8file > $eucfile | |
9 | +done |
@@ -1,51 +0,0 @@ | ||
1 | -<script type="text/javascript" src="http://www.google.com/jsapi"></script> | |
2 | -<script type="text/javascript"> | |
3 | - google.load("jquery", "1.4"); | |
4 | -</script> | |
5 | - | |
6 | -<!-- Load the queue CSS --> | |
7 | -<style type="text/css">@import url({{plugindirurl}}css/plupload.queue.css);</style> | |
8 | - | |
9 | -<!-- Thirdparty intialization scripts, needed for the Google Gears and BrowserPlus runtimes --> | |
10 | -<script type="text/javascript" src="{{plugindirurl}}js/gears_init.js"></script> | |
11 | -<script type="text/javascript" src="http://bp.yahooapis.com/2.4.21/browserplus-min.js"></script> | |
12 | - | |
13 | -<!-- Load plupload core and all of it's runtimes and finally the jQuery queue widget --> | |
14 | -<script type="text/javascript" src="{{plugindirurl}}js/plupload.full.min.js"></script> | |
15 | -<script type="text/javascript" src="{{plugindirurl}}js/jquery.plupload.queue.min.js"></script> | |
16 | - | |
17 | -<script> | |
18 | -$(function() { | |
19 | - function getUploaderSettings(){ | |
20 | - return { | |
21 | - // General settings | |
22 | - runtimes: '{{runtimes|}}', | |
23 | - url: '{{plugindirurl}}upload.php?action=image_upload' + '&collection=' + $('#plugin_draganddropuploader').val(), | |
24 | - multipart: true, | |
25 | - | |
26 | - flash_swf_url: '{{plugindirurl}}js/plupload.flash.swf', | |
27 | - silverlight_xap_url: '{{plugindirurl}}js/plupload.silverlight.xap', | |
28 | - | |
29 | - // Specify what files to browse for | |
30 | - filters :[ | |
31 | - {title : "Image files", extensions : "jpg,gif,png"}, | |
32 | - ] | |
33 | - }; | |
34 | - } | |
35 | - | |
36 | - function setup(){ | |
37 | - $("#uploader").pluploadQueue(getUploaderSettings()); | |
38 | - } | |
39 | - | |
40 | - setup(); | |
41 | - | |
42 | - $("#plugin_draganddropuploader").change(function () { | |
43 | - setup(); | |
44 | - }); | |
45 | - | |
46 | - $("#uploader_reset").click(function(e) { | |
47 | - setup(); | |
48 | - e.preventDefault(); | |
49 | - }); | |
50 | -}); | |
51 | -</script> |
@@ -1,51 +0,0 @@ | ||
1 | -<script type="text/javascript" src="http://www.google.com/jsapi"></script> | |
2 | -<script type="text/javascript"> | |
3 | - google.load("jquery", "1.4"); | |
4 | -</script> | |
5 | - | |
6 | -<!-- Load the queue CSS --> | |
7 | -<style type="text/css">@import url({{plugindirurl}}css/plupload.queue.css);</style> | |
8 | - | |
9 | -<!-- Thirdparty intialization scripts, needed for the Google Gears and BrowserPlus runtimes --> | |
10 | -<script type="text/javascript" src="{{plugindirurl}}js/gears_init.js"></script> | |
11 | -<script type="text/javascript" src="http://bp.yahooapis.com/2.4.21/browserplus-min.js"></script> | |
12 | - | |
13 | -<!-- Load plupload core and all of it's runtimes and finally the jQuery queue widget --> | |
14 | -<script type="text/javascript" src="{{plugindirurl}}js/plupload.full.min.js"></script> | |
15 | -<script type="text/javascript" src="{{plugindirurl}}js/jquery.plupload.queue.min.js"></script> | |
16 | - | |
17 | -<script> | |
18 | -$(function() { | |
19 | - function getUploaderSettings(){ | |
20 | - return { | |
21 | - // General settings | |
22 | - runtimes: '{{runtimes|}}', | |
23 | - url: '{{plugindirurl}}upload.php?action=image_upload' + '&collection=' + $('#plugin_draganddropuploader').val(), | |
24 | - multipart: true, | |
25 | - | |
26 | - flash_swf_url: '{{plugindirurl}}js/plupload.flash.swf', | |
27 | - silverlight_xap_url: '{{plugindirurl}}js/plupload.silverlight.xap', | |
28 | - | |
29 | - // Specify what files to browse for | |
30 | - filters :[ | |
31 | - {title : "Image files", extensions : "jpg,gif,png"}, | |
32 | - ] | |
33 | - }; | |
34 | - } | |
35 | - | |
36 | - function setup(){ | |
37 | - $("#uploader").pluploadQueue(getUploaderSettings()); | |
38 | - } | |
39 | - | |
40 | - setup(); | |
41 | - | |
42 | - $("#plugin_draganddropuploader").change(function () { | |
43 | - setup(); | |
44 | - }); | |
45 | - | |
46 | - $("#uploader_reset").click(function(e) { | |
47 | - setup(); | |
48 | - e.preventDefault(); | |
49 | - }); | |
50 | -}); | |
51 | -</script> |
@@ -1,9 +0,0 @@ | ||
1 | -<h3>Drag And Drop Uploader</h3> | |
2 | -<p> | |
3 | - <label for="plug_ping_check">Collection:</label> | |
4 | - {{collections}}<br /> | |
5 | - <div id="uploader"> | |
6 | - <p>You browser doesn't have Flash, Silverlight, Gears, BrowserPlus or HTML5 support.</p> | |
7 | - </div> | |
8 | - <a id="uploader_reset" href="#">Reset Uploader</a> | |
9 | -</p> |
@@ -1,9 +0,0 @@ | ||
1 | -<h3>Drag And Drop Uploader</h3> | |
2 | -<p> | |
3 | - <label for="plug_ping_check">Collection:</label> | |
4 | - {{collections}}<br /> | |
5 | - <div id="uploader"> | |
6 | - <p>You browser doesn't have Flash, Silverlight, Gears, BrowserPlus or HTML5 support.</p> | |
7 | - </div> | |
8 | - <a id="uploader_reset" href="#">Reset Uploader</a> | |
9 | -</p> |