First I want to thank Vuud for his help in getting this figured out via e-mail.
Installing CpmFetch and PHPBB using the PHPBB template system (NO EXTRA MODS NEEDED). There are other solutions on this website that require the install of other mods like Extreme Styles inorder for this to work. This soultion uses the phpbb template system with out the need for additional mods to be installed.
Everything that I reference below I did on my website
http://www.felineadvice.com to get cpmfetch working with the phpbb templates. I am using Smartor's EZportal but you can use this method to intergrate cpmfetch on any phpbb file you wish.
Open the phpbb file you wish to have cpmfetch included in. In my example I am using portal.php but you can use index.php or any other phpbb file.
FIND:
$template->assign_vars(array(
ADD BEFORE:
include "./cpmfetch/coppermine.php";
$objCpm = new cpm("/gallery");
$objCpm->cpm_setReturnType('html');
Where ./cpmfetch/coppermine.php is the path to the coppermine file installed when you uploaded cpmfetch and /gallery is the path to your coppermine gallery. In my example my forum is installed in the root of my web space so the gallery is one level up aswell as the cpmfetch install.
FIND:
$template->assign_vars(array(
ADD AFTER:
'RANDOM_IMAGE' => $objCpm->cpm_viewRandomMedia(1,3),
FIND:
);
This is the closing bracket for the template array.
ADD AFTER:
$objCpm->cpm_close();
SAVE FILE
Now open the assocated template file. In my example I am using portal_body.tpl Locate where you want the images to appear and insert the approprate HTML and
{RANDOM_IMAGE} where you want the images to appear.
If you follow the above you will end up with one row of images and three across. Edit the $objCpm->cpm_viewRandomMedia(1,3), in your file if you want more rows or more images.