SPGM-Vid Module for SPGM

Installing SPGM-Vid:

1) Download SPGM-Vid using the link in the menu.
2) Unzip the file.
3) Copy all of the SPGM-Vid files to your web space (see below for more information).
4) Make the required changes to your SPGM files (see below for more information).
5) Make any required set-up changes.
6) If you are hosting your video gallery on a Windows based web server, see this post on the Support forum for important information.

Copying the SPGM-Vid files, additional information:

Below is a list of the files required, and the location they should be copied to relative to your existing "spgm.php" file.

SPGM-Vid File  Copy To  Location Relative to "spgm.php"
spgm-vid.php --> spgm-vid.php
spgm-vid.lib.php --> spgm-vid.lib.php
video.php --> video.php
flavors/default/mp.png --> flavors/default/mp.png
flavors/default/qt.png --> flavors/default/qt.png
flavors/default/rp.png --> flavors/default/rp.png
flavors/default/sw.png --> flavors/default/sw.png
flavors/default/mp.gif --> flavors/default/mp.gif
flavors/default/qt.gif --> flavors/default/qt.gif
flavors/default/qt.gif --> flavors/default/qt.gif
flavors/default/rp.gif --> flavors/default/rp.gif
flavors/default/thb_mp.jpg --> flavors/default/thb_mp.jpg
flavors/default/thb_qt.jpg --> flavors/default/thb_qt.jpg
flavors/default/thb_rp.jpg --> flavors/default/thb_rp.jpg
flavors/default/thb_sw.jpg --> flavors/default/thb_sw.jpg
getid3/*.* --> getid3/*.*
vid/*.* --> vid/*.*

Required changes to your SPGM files, additional information:

Depending on your comfort level with editing files, the version of SPGM you are running and whether you are running the default flavor, one of the following three procedures should be done to make the required changes to SPGM.

1) If you are currently running SPGM v1.4.5, the default flavor and you want to get up and running quick, do the following.

Supplied SPGM Changed Files  Copy To  Location Relative to "spgm.php"
spgm.php --> spgm.php
flavors/default/spgm.thm --> flavors/default/spgm.thm
lang/*.* --> lang/*.*

2) If you feel comfortable making the required changes, here are the changes required.

Open: spgm.php
Find: define('FILE_GAL_TITLE', 'gal-title.txt');
Before Add: // Begin SPGM-Vid Add
define('USE_SPGMVID';, true); // toggles SPGM-Vid Support
// End SPGM-Vid Add

Find: ###### REPORTING FUNCTIONS #######
Before Add: // Begin SPGM-Vid Add
  if ( USE_SPGMVID ) require_once ('spgm-vid.lib.php');
// End SPGM-Vid Add

Find: } // endfor

if ($iGalleryDepth == 1 && $_max > 0) {
Before Add: // Begin SPGM-Vid Add
if ( ($_max-1) == $i && function_exists('spgmvid_GalleryAdd') )
  spgmvid_GalleryAdd($i, $strPathToGallery);
// End SPGM-Vid Add

Find: if ($iGalleryDepth == 1 && $_max > 0) {
  print ' </tr>'."\n";
  print '</table>'."\n";
}
Before Add: // Begin SPGM-Vid Add
$strFileVideoGallery = $strPathToGallery.'/'.FILE_VID_GAL;
if ( $_max == 0 && function_exists('spgmvid_GalleryAdd') && is_readable($strFileVideoGallery) )
  spgmvid_GalleryAdd(-1, $strPathToGallery);
// End SPGM-Vid Add

Open: flavors/default/spgm.thm
Find: ?>
Before Add: # Begin SPGM-Vid Add
# image icon for Media Player
$spgm_cfg['theme']['MPVideoImage'] = 'mp.gif';

# image icon for QuickTime
$spgm_cfg['theme']['QTVideoImage'] = 'qt.gif';

# image icon for Real Player
$spgm_cfg['theme']['RPVideoImage'] = 'rp.gif';

# image icon for Shockwave Player
$spgm_cfg['theme']['SWVideoImage'] = 'sw.gif';

# default thumbnail for Media Player Videos
$spgm_cfg['theme']['MPVideoTHB'] = 'thb_mp.jpg';

# default thumbnail for QuickTime Videos
$spgm_cfg['theme']['QTVideoTHB'] = 'thb_qt.jpg';

# default thumbnail for Real Player Videos
$spgm_cfg['theme']['RPVideoTHB'] = 'thb_rp.png';

# default thumbnail for Shockwave Player Videos
$spgm_cfg['theme']['SWVideoTHB'] = 'thb_sw.png';

Open: lang/lang.en
Find: ?>
Before Add: # Begin SPGM-Vid Add
# main video gallery label
$spgm_cfg['locale']['VideoGallery'] = 'Video gallery';

# videos navi bar
$spgm_cfg['locale']['videoNaviBar'] = 'video >CURRENT_VID< of >NB_VIDS<';

# video label (as in '1 video')
$spgm_cfg['locale']['video'] = 'video';

# videos label (as in '2 videos')
$spgm_cfg['locale']['videos'] = 'videos';

# new video label (as in '1 new video')
$spgm_cfg['locale']['newVideo'] = 'new video';

# new videos label (as in '2 new videos')
$spgm_cfg['locale']['newVideos'] = 'new videos';

# save link IE
$spgm_cfg['locale']['SaveLinkIE'] = 'To save a copy, Right click here and Select "Save Target As..."';

# save link NS
$spgm_cfg['locale']['SaveLinkNS'] = 'To save a copy, Right click here and Select "Save Link As..."';

3) You might need to do a combination of 1 and 2.

If you have any questions, feel free to ask for help by clicking on the "Support" link in the menu.



Valid xhtml 1.0!    Valid CSS!