Perform task for all nodes of a certain type

Events happening in the community are now at Drupal community events on www.drupal.org.
Goofy2k's picture

Hi,

I want to perform a task for all nodes of a certain type.

Can I do this with Rules?

Who can give me a hint how to do this.

thanks
Fred

Comments

re: Perform task for all nodes of a certain type

Ashford's picture

First you need to decide on a trigger event. The events are listed as options when you create a new rule. Your node type is a condition.

    Example
  1. Events: after Saving a node
  2. Conditions: node type = my_node_type
    You can have as many conditions added as you need.
  3. Action: Send me a message
    You can have as many conditions added as you need.

So what you are doing with a Rule is saying...when this Event occurs and these Conditions are true, do this Action.

Hi Ashford, Thanks for your

Goofy2k's picture

Hi Ashford,

Thanks for your reply.

My problem is in the actions: let's say that I have a large number (hundreds) of nodes. The actual number of them varies because they can be created and deleted by other users. At the moment I have to include an action for every node. So I get a rule set with a very large number of actions.

Explain more about what you are trying to do

Ashford's picture

If your nodes content_type is the same and the condition you want to use is the same, you can apply the same action to all the nodes matching those values. I must be misunderstanding what you are trying to do. Terminology can often obscure the questions and answers.

Try to explain in more detail what it is you are working with and what you want to accomplish.

Ashford

Rules

Group organizers

Group categories

Categories

Group notifications

This group offers an RSS feed. Or subscribe to these personalized, sitewide feeds: