Karel-Jan Misseghers
Karel-Jan Misseghers

Reputation: 807

Fill in Form Field from Node-Field using Rules in Drupal 7

I am looking for a way to populate some fields in an (entity)form (for example name and email) once a client has filled in his tax-number (or another configurable field). The field to compare it to is in another node or entity.

For example:

A registration form for an event => when a user is registrating: check if the filled in tax number allready exists in one of the nodes 'attendees last year'. If it finds a match, it takes the date in the 'name' field of the node, and puts it in the 'name' field in the form (in the next step, see underneath)

For the forms I am using the EntityForms-module (which creates a form with the fields of an entity, so users can create new entity objects) and a custom module which allows me to go through the form in multiple steps, a rules event is triggered when the 'continue' button in a form-step is clicked.

I have rules and rules-forms-support enabled, I try to make a rule:

I can't hardcode this because it has to be configurable (have to make multiple different forms..)

Upvotes: 1

Views: 1340

Answers (1)

tedbow
tedbow

Reputation: 151

You may be able to do this via a value in the URL. Checkout Prepopulate module http://drupal.org/project/prepopulate

There is a dev version for Drupal 7.

You should be to add the extra info in the URL in the Rule.

Upvotes: 1

Related Questions