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: only registered users can view original (full) image  (Read 1843 times)

0 Members and 1 Guest are viewing this topic.

papak

  • Coppermine newbie
  • Offline Offline
  • Posts: 2
only registered users can view original (full) image
« on: February 10, 2009, 01:21:25 pm »

Hello,

the previous mod no longer applies for the new version (i am using latest version with stamm mod).

I understand how to include the if (!USER_ID) but can't seem to find where in displayimage.php it would be appropriate (can't find where the link is generated) (if still in the displayimage.php) at all ...

can somenone please help? to clarify again => i would like only the registered users to be able to view the full image (original) and the non-registered users only to be able to view the thumbs and _normal image ...

Thank you in advance.
Logged

papak

  • Coppermine newbie
  • Offline Offline
  • Posts: 2
[SOLVED] only registered users can view original (full) image
« Reply #1 on: February 10, 2009, 02:46:10 pm »

I managed to find it ... sort of :)

what I did in case someone else is interested:

in displayimage.php changed
Code: [Select]
if (isset($_GET['fullsize'])) {
theme_display_fullsize_pic();
ob_end_flush();
to
if (isset($_GET['fullsize'])) {
if (!USER_ID) theme_display_nofullsize_pic();
else theme_display_fullsize_pic();
ob_end_flush();

and than i also added the custom theme_display_nofullsize_pic in includes/themes.inc.php, which contains the message that user must register.
Logged
Pages: [1]   Go Up
 

Page created in 0.016 seconds with 19 queries.