JasonWoof Got questions, comments, patches, etc.? Contact Jason Woofenden
link to archived versions from page edit page
[wfpl-cms.git] / admin_images.php
index e9d3169..443aae9 100644 (file)
@@ -4,8 +4,8 @@
 
 define('ADMIN_IMAGES_DB_FIELDS', 'image,name,caption');
 
-require_once(DOCROOT . 'inc/wfpl/format.php');
-require_once(DOCROOT . 'inc/wfpl/upload.php');
+require_once(__DIR__.'/'.'inc/wfpl/format.php');
+require_once(__DIR__.'/'.'inc/wfpl/upload.php');
 
 # example: 200x300
 function format_width_height($str) {
@@ -39,8 +39,6 @@ function admin_images_get_fields() {
        } else {
                if(_REQUEST_cut('delete_image') == 'Yes') {
                        $data['image'] = '';
-               } else {
-                       $data['image'] = format_image_w_h(_REQUEST_cut('old_image'));
                }
        }
        unset($_FILES['image']);