Bug Stop thumbnail from clearing everytime download file is updated/changed

Status
Not open for further replies.

bzcomputers

Customer
Every time you update/change the download file, the thumbnail for that download are always cleared and have to be reuploaded too. It would be great if they would stay the same unless you choose to change/delete them.
 
If you edit dbtech/downloads/modules/uploadModule.php

At about line 493 you will find

PHP:
        $this->registry->db->query_write("
                UPDATE " . TABLE_PREFIX . "dbtech_downloads_filegroup
                    SET
                        image         = IF(image = 0, '" . $imageid . "', image),
                        files         = '" . implode(',', (array)$fileids) . "',
                        filecount     = " . intval($filecount['files']) . "
                WHERE groupid = " . intval($this->groupid) . "
            ");

replace it with

PHP:
        $this->registry->db->query_write("
                UPDATE " . TABLE_PREFIX . "dbtech_downloads_filegroup
                    SET
                        files         = '" . implode(',', (array)$fileids) . "',
                        filecount     = " . intval($filecount['files']) . "
                WHERE groupid = " . intval($this->groupid) . "
            ");

That's some old left over code that David had in there when he was trying to make the first image be the thumbnail. Now that it's uploaded from it's own area that can be removed.
 
Status
Not open for further replies.

Similar threads

  • Locked
  • Support ticket Support ticket
Replies
8
Views
2K
  • Locked
  • thread_type.dbtech_ecommerce_suggestion thread_type.dbtech_ecommerce_suggestion
Replies
0
Views
1K
  • Locked
  • thread_type.dbtech_ecommerce_suggestion thread_type.dbtech_ecommerce_suggestion
Replies
4
Views
832

Legacy vBDownloads

vBulletin 3.8.x vBulletin 4.x.x
Seller
DragonByte Technologies
Release date
Last update
Total downloads
1,717
Customer rating
0.00 star(s) 0 ratings
Back
Top