0
votes

I have a CCK content type Event which has a privacy text field to describe if its a 'public' or 'private'. I'm also using the RSVP module so users can invite their friends to an event they have created.

I need to be able to block access to an Event node if its private and the user attempting to view the node has not been invited.

I thought this would be easy enough by implementing hook_access which would check if the privacy field is private. If it is I would make a quick database call to check if the user has been invited. If not return false and block node access.

Imagine my horror when I discovered that this hook cannot be used for CCK content types and only works for content types the node module owns.

Can anyone point me in the right direction to do some custom node access validation 'the drupal way' when using CCK content types. Using drupal 6 by the way.

1

1 Answers

0
votes

maybe you'll be lucky with the content access - module.

I didn't try it yet, but it seems to be the solution to your problem.