git.shiar.nl
/
minimedit.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
thumb: ?backend option to override resize callback
[minimedit.git]
/
thumb
/
index.php
diff --git
a/thumb/index.php
b/thumb/index.php
index f7c36d9d0a6d776bde1a4ff3008b2f401958e770..066e88d7cf9561227d96f8b6a2fe9ff80afacc21 100644
(file)
--- a/
thumb/index.php
+++ b/
thumb/index.php
@@
-38,8
+38,16
@@
exit;
function mkthumb($source, $target, $width, $height)
{
function mkthumb($source, $target, $width, $height)
{
+ if (isset($_GET['backend'])) {
+ $backend = $_GET['backend'];
+ }
+ else {
+ $backend = 'exec';
+ }
+ $backend = "mkthumb_$backend";
+
@mkdir(dirname($target), 0777, TRUE);
@mkdir(dirname($target), 0777, TRUE);
-
return mkthumb_exec
($source, $target, $width, $height);
+
$backend
($source, $target, $width, $height);
}
function mkthumb_exec($source, $target, $width, $height)
}
function mkthumb_exec($source, $target, $width, $height)