Status
Not open for further replies.
The checkbox was forced to the far right on purpose. I didn't want it checked by accident, wanted it to be a conscious decision.
I'll check why it's not deleting though.
 
Open
dbtech/gallery/actions/doeditimage.php

Find
PHP:
DBTECH_GALLERY::delete_item($vbulletin->GPC['imageid'], 'image');
Replace with
PHP:
DBTECH_GALLERY::delete_item($vbulletin->GPC['imageid'], 'images');

That should do it :)
 
The checkbox was forced to the far right on purpose. I didn't want it checked by accident, wanted it to be a conscious decision.
I'll check why it's not deleting though.

I think it looks odd but that's just me. :p
How about moving the word delete to the far right as well and maybe change it to delete image

or another option tucking the check box right under delete on the left and moving save to the right...we can make this better.:)

Yes, this indeed deleted the image...mmm...is there some kind of cron job to clean up the images from the server?
 
Hmm, what about removing the checkbox and doing a Delete Image button on the right side, same level as the save? That might be better actually. I can do a popup are you sure you want to delete this? and then do it through ajax.

When you delete the image it removes all the image files from the server. Or it should, let me know if it's leaving any behind.
 
Yeah, that would be better.
Yes, the images are left behind.


Oh this just convinced me about that other thread...follow the vBulletin default layout. :cool: the Edit Picture there works.
 
Last edited:
Open dbtech/gallery/includes/class_core.php

On about line 366 you'll see

PHP:
            if (file_exists($pic_thumb_name) && !is_dir($pic_thumb_name))
            {
                @unlink($pic_thumb_name);
            }

            if (file_exists($pic_full_name) && !is_dir($pic_full_name))
            {
                @unlink($pic_full_name);
            }

            if (file_exists($pic_wm_name) && !is_dir($pic_wm_name))
            {
                @unlink($pic_wm_name);
            }

Change it to

PHP:
            if (file_exists($pic_thumb_name) && !is_dir($pic_thumb_name))
            {
                unlink($pic_thumb_name);
            }

            if (file_exists($pic_full_name) && !is_dir($pic_full_name))
            {
                unlink($pic_full_name);
            }

            if (file_exists($pic_wm_name) && !is_dir($pic_wm_name))
            {
                unlink($pic_wm_name);
            }

Then try and delete an image. It should give you an error. Let me know what it is :)
 
hmm, could I get ftp access and an account that can upload images? Sounds like it's just skipping over the image delete code for some reason.
 
Yeah, I left a couple old ones there, so when I get the ACP option to clean up orphaned images you'll have some to test with :)
But if you create a new image and delete it, the files should go away now
 
Status
Not open for further replies.

Similar threads

Legacy DragonByte Gallery

vBulletin 4.x.x
Seller
DragonByte Technologies
Release date
Last update
Total downloads
865
Customer rating
0.00 star(s) 0 ratings
Top