Jump to content

Feature request - new file storage system


Recommended Posts

I have over 3Gb monthly uploads, original IPB storage system isn't convenient!
I make my own storage system, but each updating of the forum version it's necessary to waste time on modification of a large quantity of files.

Please, make universal storage!

My idea (it's work on my forum):

All uploads in uploads/monthly*/ , no other special dirs

Under monthly* dirs - system & component dirs:
(based on $type from class_attach)

/monthly/post (image, thumb)
/monthly/profile (avatars, photos, bg's)
/monthly/gallery (image, med, thumb)

Under every components dir - subdirs for images, thumb, screenshots..
Directory setup - in ACP for all components in one settings group.

Only two functions in core:
One returns array of dirs based on file upload time (or time()) and type ( i use IPSLib::getAppUploadPath($time, $type); ).
One for creating new monthly directory structure (with check for installed components, i call it from scheduler in the end of month).

Readable code

		$app_path = IPSLib::getAppUploadPath( $image['idate'], 'gallery' );

		@unlink( $app_path['image'] . $image['masked_file_name'] );

 		@unlink( $app_path['thumb'] . $image['masked_file_name'] );

No tn_, _med and other addition to file name, all file store as is.
No superfluous records in db, one filename for all, thumb (med) saved as tinyint, not as filename, no dirname store.
Easy search, easy backup, easy administration..

Link to comment
Share on other sites


This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Create New...