Got questions, comments, patches, etc.?
Contact Jason Woofenden
gitweb
/
wfpl-cms.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
db_upgrade rework, admin_header, cleanup
[wfpl-cms.git]
/
cms_images_autoresize.php
diff --git
a/cms_images_autoresize.php
b/cms_images_autoresize.php
index
922b3cf
..
0d3e667
100644
(file)
--- a/
cms_images_autoresize.php
+++ b/
cms_images_autoresize.php
@@
-1,8
+1,7
@@
<?php
<?php
-define('DOCROOT', __DIR__ .'/');
-require_once(DOCROOT . 'config.php');
-require_once(DOCROOT . 'inc/wfpl/upload.php');
+require_once(__DIR__.'/'.'config.php');
+require_once(__DIR__.'/'.'inc/wfpl/upload.php');
function cms_images_autoresize_main_abort_404() {
http_response_code('404');
function cms_images_autoresize_main_abort_404() {
http_response_code('404');
@@
-26,8
+25,8
@@
function cms_images_autoresize_main() {
$width = (int)$matches[2];
$ext = $matches[3];
$in_fn = "$basename.$ext";
$width = (int)$matches[2];
$ext = $matches[3];
$in_fn = "$basename.$ext";
- $in_path = DOCROOT . 'cms_images/' . $in_fn;
- $out_path = DOCROOT . 'cms_images/' . $out_fn;
+ $in_path = __DIR__.'/'.'cms_images/' . $in_fn;
+ $out_path = __DIR__.'/'.'cms_images/' . $out_fn;
$lock_path = $out_path . '.lock';
if (!in_array($width, $GLOBALS['wfpl_image_widths'], true)) {
$lock_path = $out_path . '.lock';
if (!in_array($width, $GLOBALS['wfpl_image_widths'], true)) {