Flash gallery Flash gallery
 

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Main Menu

Flash gallery

Started by addar800, May 01, 2007, 04:35:55 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

addar800

i want to make a flash gallery instead of an image gallery but i will have an image section i wanna know is there a mod so users can upload thier flash animations/cartoons and games

addar800


SaWey

You can add flah files without a mod, easy as that.

SaWey

If you want to have screenshots as thumbnails of your flash files, then I have a quick 'n dirty hack.

First a little info:

When adding this hack,
you will have to upload a picture (screenshot) with the same name of your flash file but with the '.jpg' extension.

If no thumbnail is uploaded, then the default flash icon is used.

Now for the coding:
open include/functions.inc.php and add the following code around line 1968:

Find:

foreach ($thumb_extensions as $extension) {
   // Check for extension-specific thumbs
   if (file_exists($default_thumb_path.$CONFIG['thumb_pfx'].$mime_content['extension'].$extension)) {
   $filepathname = $default_thumb_path.$CONFIG['thumb_pfx'].$mime_content['extension'].$extension;


After add:

if($mime_content['extension'] == 'swf'){
        $filepathname = $pic_row['filepath'].str_replace('swf', 'jpg', $pic_row['filename']);
        if (!file_exists($filepathname)){
               $filepathname = $default_thumb_path.$CONFIG['thumb_pfx'].$mime_content['extension'].$extension;
        }
}




Joachim Müller

Thread has originally been posted on the feature requests sub-board (where it shouldn't have gone, as it is not a valid feature suggestion).

addar800

well i just want it so you cant add images just flash

SaWey

I don't understand what you mean, maybe some extra explanation?

Joachim Müller

If you want to disallow uploading image files and others (in fact everything but flash), set the content of the fields "Allowed image types", "Allowed audio types" and "Allowed document types" in Coppermine's config to be empty. Set "Allowed movie types" to "swf"

No mod needed - just use Coppermine's built-in features.

addar800