Skip to content

Commit 19b9613

Browse files
committed
Merge pull request #18 from tsawler/Development
Development
2 parents ff0b456 + 56387e0 commit 19b9613

File tree

3 files changed

+14
-5
lines changed

3 files changed

+14
-5
lines changed

README.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@ This package is written specifically for Laravel 5, and will integrate seamlessl
1616

1717
1. This package only supports Laravel 5.x
1818
1. Requires `"intervention/image": "2.*"`
19-
1. Requires `"francodacosta/phmagick": "0.4.*@dev"`
2019
1. Requires PHP 5.5 or later
2120

2221
## Installation

composer.json

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,7 @@
1111
"require": {
1212
"php": ">=5.5.0",
1313
"illuminate/support": "5.0.*",
14-
"intervention/image": "2.*",
15-
"francodacosta/phmagick": "0.4.*@dev"
14+
"intervention/image": "2.*"
1615
},
1716
"autoload": {
1817
"psr-4": {

src/views/index.blade.php

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ class="fa fa-list"></i> List</a>
118118
<div class="modal-header">
119119
<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span
120120
aria-hidden="true">&times;</span></button>
121-
<h4 class="modal-title" id="fileLabel">View Fiile</h4>
121+
<h4 class="modal-title" id="fileLabel">View File</h4>
122122
</div>
123123
<div class="modal-body" id="fileview_body">
124124

@@ -426,11 +426,22 @@ function resizeImage(x) {
426426
});
427427
428428
function fileView(x){
429+
var rnd = makeRandom();
429430
$('#fileview_body').html(
430-
"<img class='img img-responsive center-block' src='{!! Config::get('lfm.images_url') !!}" + $("#working_dir").val() + "/" + x + "'>"
431+
"<img class='img img-responsive center-block' src='{!! Config::get('lfm.images_url') !!}" + $("#working_dir").val() + "/" + x + "?id=" + rnd + "'>"
431432
);
432433
$('#fileViewModal').modal();
433434
}
435+
436+
function makeRandom()
437+
{
438+
var text = "";
439+
var possible = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";
440+
441+
for( var i=0; i < 20; i++ )
442+
text += possible.charAt(Math.floor(Math.random() * possible.length));
443+
return text;
444+
}
434445
</script>
435446
</body>
436447
</html>

0 commit comments

Comments
 (0)