forum.coppermine-gallery.net

Support => cpg1.5.x Support => cpg1.5 themes (visuals) => Topic started by: P on October 23, 2013, 05:52:56 pm

Title: How to hide 'rating' and 'file information' ?
Post by: P on October 23, 2013, 05:52:56 pm
How to hide 'rating' and 'file information' ?
I need to hide them completely. Please help.
Title: Re: How to hide 'rating' and 'file information' ?
Post by: Jeff Bailey on October 23, 2013, 09:06:54 pm
Try
in your custom theme.php
Code: [Select]
/******************************************************************************
** Section <<<$template_image_rating>>> - START
******************************************************************************/
// HTML template for the image rating box
$template_image_rating = ''
/******************************************************************************
** Section <<<$template_image_rating>>> - END
******************************************************************************/
and (or just this)
Code: [Select]
/******************************************************************************
** Section <<<theme_display_image>>> - START
******************************************************************************/
function theme_display_image($nav_menu, $picture, $votes, $pic_info, $comments, $film_strip)
{
    global $CONFIG, $LINEBREAK;

    $superCage = Inspekt::makeSuperCage();

    $width = $CONFIG['picture_table_width'];

    echo '<a name="top_display_media"></a>'; // set the navbar-anchor
    starttable();
    echo $nav_menu;
    endtable();

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



   echo $LINEBREAK

    echo '<a name="comments_top"></a>';
    echo '<div id="comments">' . $LINEBREAK;
        echo $comments;
        echo '</div>' . $LINEBREAK;

}
/******************************************************************************
** Section <<<theme_display_image>>> - END
******************************************************************************/
paste before the closing ?>

If this doesn't help please provide a link and a copy of your custom theme.php attached to this thread as theme.php.txt
Untested.
Title: Re: How to hide 'rating' and 'file information' ?
Post by: P on October 24, 2013, 12:17:13 am
Hi Jeff, thanks for suggestion.

Which position in theme.php I should put those code?
Title: Re: Re: How to hide 'rating' and 'file information' ?
Post by: Jeff Bailey on October 24, 2013, 01:30:35 am
paste before the closing ?>
Title: Re: How to hide 'rating' and 'file information' ?
Post by: P on October 24, 2013, 02:09:26 am
it doesn't work, thanks anyway
Title: Re: Re: How to hide 'rating' and 'file information' ?
Post by: Jeff Bailey on October 24, 2013, 02:35:51 am
If this doesn't help please provide a link and a copy of your custom theme.php attached to this thread as theme.php.txt

What exactly happened?
Title: Re: How to hide 'rating' and 'file information' ?
Post by: P on October 24, 2013, 03:07:52 am
this is how I put code .. in attach file.
Title: Re: How to hide 'rating' and 'file information' ?
Post by: P on October 24, 2013, 03:10:00 am
and the result is.. (in below pic)

if i'm wrong, please show me how to put code correctly
Title: Re: How to hide 'rating' and 'file information' ?
Post by: Jeff Bailey on October 24, 2013, 03:45:19 am
Sorry forgot a semi colon.

don't forget to rename it back to theme.php.
Title: Re: How to hide 'rating' and 'file information' ?
Post by: P on October 24, 2013, 04:11:19 am
I try to save again, now the result is 'white blank page'. (rename to theme.php already)
Title: Re: How to hide 'rating' and 'file information' ?
Post by: Jeff Bailey on October 24, 2013, 04:45:08 am
Try this one.

Unfortunately I don't have a gallery to test on at the moment, so please bear with my mistakes.
Title: Re: How to hide 'rating' and 'file information' ?
Post by: P on October 24, 2013, 05:37:21 pm
OK. It's work now. Thank you very much Jeff! I appreciate your help.

*put these code between EOT; and ?> (at the bottom of your theme.php), so I can hide rating and file information boxes*

Quote
EOT;

/******************************************************************************
** Section <<<theme_display_image>>> - START
******************************************************************************/
function theme_display_image($nav_menu, $picture, $votes, $pic_info, $comments, $film_strip)
{
    global $CONFIG, $LINEBREAK;

    $superCage = Inspekt::makeSuperCage();

    $width = $CONFIG['picture_table_width'];

    echo '<a name="top_display_media"></a>'; // set the navbar-anchor
    starttable();
    echo $nav_menu;
    endtable();

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

    echo $LINEBREAK;

    echo '<a name="comments_top"></a>';
    echo '<div id="comments">' . $LINEBREAK;
        echo $comments;
        echo '</div>' . $LINEBREAK;

}
/******************************************************************************
** Section <<<theme_display_image>>> - END
******************************************************************************/

?>