<script> $('[class*="lfm"]').each(function() { $(this).filemanager('image', {prefix: route_prefix}); }); </script>