Execute rule on CCK file field changing

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

I'm not sure whether i should post this here or on the issue tracker but...

I want to execute a rule to populate a field whenever a user changes the CCK file field of a node. This does happen with the rule i have set up, but, the rule also executes when any other CCK field is edited, which is obviously not intended. The rule is set up to execute when contetn is going to be saved (though after updating seems to yield the same result), IF the field field_file has been changed. I really cannot see why this seemingly simple rule is not working as expected. What am i missing?

Comments

Some more testing shows that

Dirk's picture

Some more testing shows that the rule does work when i use it ony any other field, it's just the file field that is the problem. Any ideas why this is happening?

No clear answer

itangalo's picture

I have no clear answer, but I know that the file fields do have quite some data in them. It could be that some of this data actually changes on each node save, and that Rules interprets this as the field as a whole has changed.

This is a loose guess. You could try activating Devel and having a look at the file field on the node's devel tab. If it changes between saves you probably found the reason for the problem. Even if you can't fix the problem, it would make it much easier for coders to fix the bug.

Anyway, this seems like a bug, and once confirmed it should be reported to the issue queue.

Don't give up!
//Johan Falk, NodeOne, Sweden

Did anybody get an answer to

cockers's picture

Did anybody get an answer to this? I'm experiencing the same problem with Drupal 7.

Rules

Group organizers

Group categories

Categories

Group notifications

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