Advanced search  

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Pages: [1]   Go Down

Author Topic: Disable PICINFO for non registered users  (Read 4445 times)

0 Members and 1 Guest are viewing this topic.

Vinicius Machado

  • Coppermine novice
  • *
  • Offline Offline
  • Gender: Male
  • Posts: 37
Disable PICINFO for non registered users
« on: February 16, 2010, 02:03:54 pm »

How can I disable the PICINFO just for non registered users ?

I know almost nothing in PHP. But I've tried a lot of ting like copying other codes and testing in different ways but I Can't change this.

Thx
Logged

Jeff Bailey

  • Dev Team member
  • Coppermine addict
  • ****
  • Country: us
  • Offline Offline
  • Gender: Male
  • Posts: 1322
  • Fishing relaxes me.
    • Bailey Family Co.
Re: Disable PICINFO for non registered users
« Reply #1 on: February 16, 2010, 03:45:47 pm »

Logged
Thinking is the hardest work there is, which is probably the reason why so few engage in it. - Henry Ford

Vinicius Machado

  • Coppermine novice
  • *
  • Offline Offline
  • Gender: Male
  • Posts: 37
Re: Disable PICINFO for non registered users
« Reply #2 on: February 16, 2010, 05:54:09 pm »

Sorry, I fogrgot that.

www.viniciusmachado.com/crisevini/album

user: tester
password: tester123
Logged

Nibbler

  • Guest
Re: Disable PICINFO for non registered users
« Reply #3 on: February 16, 2010, 06:13:59 pm »

Add the following code to your custom theme's theme.php

Code: [Select]
function theme_display_image($nav_menu, $picture, $votes, $pic_info, $comments, $film_strip)
{
    global $CONFIG;

    $width = $CONFIG['picture_table_width'];

    starttable();
    echo $nav_menu;
    endtable();

    starttable();
    echo $picture;
    endtable();
    if ($CONFIG['display_film_strip'] == 1) {
        echo $film_strip;
    }


    echo $votes;


    if (USER_ID) {
        $picinfo = isset($_COOKIE['picinfo']) ? $_COOKIE['picinfo'] : ($CONFIG['display_pic_info'] ? 'block' : 'none');
        echo "<div id=\"picinfo\" style=\"display: $picinfo;\">\n";
        starttable();
        echo $pic_info;
        endtable();
        echo "</div>\n";
    }
   
    echo "<div id=\"comments\">\n";
        echo $comments;
        echo "</div>\n";

}
Logged

Vinicius Machado

  • Coppermine novice
  • *
  • Offline Offline
  • Gender: Male
  • Posts: 37
Re: Disable PICINFO for non registered users
« Reply #4 on: February 17, 2010, 01:09:09 am »

Thx buddy. Thats it ! Issue solved !
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: Disable PICINFO for non registered users
« Reply #5 on: February 18, 2010, 07:42:06 am »

Sorry, I fogrgot that.
You always "forget" that. You have been around long enough and supporters had to remind you of board rules countless times already, so I'm no longer willing to accept your apologies. If you fail to respect board rules in the future, you'll get banned. Locking
Logged
Pages: [1]   Go Up
 

Page created in 0.02 seconds with 19 queries.