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: Download Resized question  (Read 4785 times)

0 Members and 1 Guest are viewing this topic.

Hot Rides

  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Gender: Male
  • Posts: 108
  • I am
    • Hot Rides Show & Cruise
Download Resized question
« on: June 04, 2008, 05:30:22 pm »

I have the mod set up to work with only registered users, but I really want to limit it to certain user groups but I can't for the life of me figure out the code ???

right now im using a simple if statement
Code: [Select]
if(!USER_ID) return $pic_data;
thanks in advance
Logged

Stramm

  • Dev Team member
  • Coppermine addict
  • ****
  • Country: 00
  • Offline Offline
  • Gender: Male
  • Posts: 6006
    • Bettis Wollwelt
Re: Download Resized question
« Reply #1 on: June 04, 2008, 07:57:40 pm »

tried something like that?

Code: [Select]
if (USER_GROUP != 'my_group' || USER_GROUP != 'my_other_group' )  return $pic_data;

Hot Rides

  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Gender: Male
  • Posts: 108
  • I am
    • Hot Rides Show & Cruise
Re: Download Resized question
« Reply #2 on: June 04, 2008, 08:14:25 pm »

just tried it, it doesnt work because its a bridged install, it has to call up the smf users, im searching for the correct way unless you have an idea
Logged

Stramm

  • Dev Team member
  • Coppermine addict
  • ****
  • Country: 00
  • Offline Offline
  • Gender: Male
  • Posts: 6006
    • Bettis Wollwelt
Re: Download Resized question
« Reply #3 on: June 04, 2008, 08:23:16 pm »

shouldn't make a difference... the constant USER_GROUP is defined in the bridge file and holds the users group (as the name indicates).
Logged in as admin the constant has stored eg. 'Administrators' (when using coppermine bridge file).

Do an
Code: [Select]
echo "User Group: ".USER_GROUP;somewhere to check

Hot Rides

  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Gender: Male
  • Posts: 108
  • I am
    • Hot Rides Show & Cruise
Re: Download Resized question
« Reply #4 on: June 04, 2008, 08:45:17 pm »

i get this displayed, see attachment
Logged

Stramm

  • Dev Team member
  • Coppermine addict
  • ****
  • Country: 00
  • Offline Offline
  • Gender: Male
  • Posts: 6006
    • Bettis Wollwelt
Re: Download Resized question
« Reply #5 on: June 04, 2008, 10:07:55 pm »

weird... when I have a bridged test environment again, I'll have a look
Pages: [1]   Go Up
 

Page created in 0.022 seconds with 19 queries.