Im using Drupal 7.

I want my users to either create a node or flag a node before that can access the rest of the site.

I have created a view of content, and added filter either current user is node author, or node is flagged by current user, if the view is empty I execute php which redirects the user to a list of content which can be flagged. I now load this view on every page execpt the page containing nodes to flag or created content pages.

So basically when a logged in user is navigating my site I am checking if the view is empty, if it is I redirect them to a certain page.

Is their a better way of acheiving this?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.