1
GRRRR
user and groups (permission) table relationships...
  • 2006/8/2 17:14

  • GRRRR

  • Just popping in

  • Posts: 3

  • Since: 2006/8/2 2


I'm an amateur at this, so I thought I'd tap your collective infinite wisdom.
What I'm trying to do is have select photo's show up on a page/block/module/whatever, depending on the XOOPS group permissions.
I've used image manager and set up 4 categories of photos (i.e. 1,2,3 & 4).

I would like the photo's to be displayed per the user group permissions that exist in xoops.
So, in other words, an Anonymous user sees all photo's in Category 1.
A Registered user see's all photo's in Category 1 & 2.
A 3rd User Group could see all photo's in Category 1,2 & 3.

I see the tables in phpmyadmin, but I can't figure out the relationship of the user table and the groups table. I think the key has to be in the groups_users_link table, but thus far it has eluded me. Perhaps _group_permission table is involved too?

I guess what I'm looking for is an "if" statement that says...
if uname belongs to groupid 1
then run the sql statement and spit out Category 1 photos.

Am I trying to recreate the wheel here? Is anyone aware of a photo module that can do this?

Many thanks in advance for your input.

2
rassim
Re: user and groups (permission) table relationships...
  • 2006/8/2 18:43

  • rassim

  • Just popping in

  • Posts: 38

  • Since: 2006/4/28


I'm using xoopsgallery module and you can set up all permissions that you're looking for.

3
snow77
Re: user and groups (permission) table relationships...
  • 2006/8/2 18:47

  • snow77

  • Just can't stay away

  • Posts: 864

  • Since: 2003/7/23


I'm not so sure if it's what you're looking for but you could check out this thread click here

4
GRRRR
Re: user and groups (permission) table relationships...
  • 2006/8/3 9:29

  • GRRRR

  • Just popping in

  • Posts: 3

  • Since: 2006/8/2 2


Excellent!!!
Thanks so much for the quick responses.
<color me impressed>!

I'll definitely check out the xoopsgallery module Rassim.
Thanks very much.

And thanks for that thread link snow77. I can almost understand it. LOL I'll save that code snippet for future use for sure!

Oh, and just to let you know.
I found that the imagemanager.php file does everything I need (and much more) within it's "list" function. So I'm in the middle of doing some copy & pasting and reformatting (into a new file) for display purposes.

Thanks again!!

Login

Who's Online

52 user(s) are online (25 user(s) are browsing Support Forums)


Members: 0


Guests: 52


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Aug 31
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits