Create a gist now

Instantly share code, notes, and snippets.

What would you like to do?
Multi-image with drag and drop sorting in Elefant.
<!-- apps/test/views/images.html -->
{! filemanager/util/multi-image !}
<script>
$(function () {
$('#sub').click (function () {
console.log ($('#images').val ().split ('|'));
});
$.multi_image ({
field: '#images',
preview: '#preview'
});
});
</script>
<p>
{"Attach images"}:
<div id="preview"></div>
<input type="hidden" name="images" id="images" />
</p>
<button id="sub">Show Data</button>
<?php // apps/test/handlers/images.php
$page->layout = 'admin';
$this->require_admin ();
echo $tpl->render ('test/images');
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment