anycontent - 'n' times in album page plse ? anycontent - 'n' times in album page plse ?
 

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

anycontent - 'n' times in album page plse ?

Started by oneoddsock, February 11, 2006, 03:26:54 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

oneoddsock

hi,

firstly thanks for a neat gallery solution  8)

secondly I searched but I couldn't see this specific question (well I did but it wasn't in feature requests)

basically would like to have the ability to include the anycontent block multiple times in the album page, at the moment I've put it into my 1.4 index.php as a hack


                    case 'anycontent':
                        if ($cat == 0) {
                            ob_start();
                            /**
                             * Any php code or HTML can be put in this file and will be displayed
                             */
// oneoddsock - use the matches number here
                    if($matches[2]) {
                      include("anycontent_$matches[2].php");
                    }
//                            include('anycontent.php');
                            $anycontent = CPGPluginAPI::filter('anycontent',ob_get_contents());
                            ob_end_clean();
                            echo ($anycontent);
                        }


so essentially when I define the content of the main page in Album list config I set 'anycontent,1/breadcrumb/catlist/alblist/anycontent,2' which allows me to have files anycontent_1.php and anycontent_2.php (or anycontent_'n'.php) pulled into different parts of the album page.

works @ http://oneoddsock.co.uk/gallery but perhaps there's a better way going forward ?  :)

Thanks!

oos