Advanced search  

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]

Pages: [1]   Go Down

Author Topic: Keywords (anycontent.php) on category pages  (Read 2128 times)

0 Members and 1 Guest are viewing this topic.

masuimi

  • Coppermine newbie
  • Offline Offline
  • Posts: 2
Keywords (anycontent.php) on category pages
« on: November 15, 2013, 08:14:14 am »

Hello,

Is it possible to display the anycontent.php Keywords on category pages?

If not, would it be possible to include a feature in a future update where we can display the anycontent.php Keywords on category pages? Right now, I have it on the homepage of my gallery and it works great!

Thank you for your time
Logged

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15764
Re: Keywords (anycontent.php) on category pages
« Reply #1 on: November 21, 2013, 12:37:20 pm »

Have a look at the bottom of index.php, you'll find
Code: [Select]
                case 'anycontent':
                    if ($cat == 0) {
                        ob_start();
                        /**
                         * Any php code or HTML can be put in this file and will be displayed
                         */
                        include('anycontent.php');
                        $anycontent = CPGPluginAPI::filter('anycontent', ob_get_contents());
                        ob_end_clean();
                        echo $anycontent;
                    }
                    break;

I haven't tested that, but it should work as requested if you replace it with
Code: [Select]
                case 'anycontent':
                    ob_start();
                    /**
                     * Any php code or HTML can be put in this file and will be displayed
                     */
                    include('anycontent.php');
                    $anycontent = CPGPluginAPI::filter('anycontent', ob_get_contents());
                    ob_end_clean();
                    echo $anycontent;
                    break;
Logged
Pages: [1]   Go Up
 

Page created in 0.018 seconds with 19 queries.