Place to store the code and config used for the next-Iterations live event.
https://iterations.space/live/
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
28 lines
930 B
28 lines
930 B
5 years ago
|
<script type="text/javascript">
|
||
|
// File picker plugin
|
||
|
// Author: https://github.com/pepijndevos/
|
||
|
|
||
|
$script("//api.filepicker.io/v1/filepicker.js", function () {
|
||
|
var network = kiwi.components.Network();
|
||
|
var control = kiwi.components.ControlInput();
|
||
|
|
||
|
filepicker.setKey("YOUR_API_KEY");
|
||
|
|
||
|
function uploaded(files) {
|
||
|
var area = $("#kiwi .controlbox textarea");
|
||
|
|
||
|
for (var i = 0; files.length>i; i++) {
|
||
|
var f = files[i];
|
||
|
area.val(area.val() + " " + f.url + "+" + encodeURIComponent(f.filename));
|
||
|
}
|
||
|
}
|
||
|
|
||
|
filepicker.makeDropPane($("#kiwi .panels")[0], { onSuccess: uploaded });
|
||
|
|
||
|
var $icon = $("<a class=\"upload\" title=\"Send File\"><i class=\"fa fa-upload\"></i></a>");
|
||
|
$icon.click(function () { filepicker.pickMultiple(uploaded); });
|
||
|
|
||
|
control.addPluginIcon($icon);
|
||
|
});
|
||
|
</script>
|