views:

317

answers:

3

in my website each manger(role) needs a webform, to get enquiries from users.. the webform which have created is for complete website...

how to do this...

+1  A: 

It sounds like you should use the contact module in core drupal rather than a webform. You can turn it on, and configure permissions so that every manager can be contacted through that form.

If you need additional fields than what the contact form comes with, then a little work with hook_form_alter() should allow you to add additional fields.

Unless part of the requirements is to keep a record of each contact sent?

John Fiala
Correct. Just to clarify your post for others, there's an option in the Contact module so that each user can have his or her specific contact form that only goes to him/her. This sounds like exactly what the OP is after, except perhaps if it's a requirement for records to be kept (as you mentioned), as the Contact module simply sends the email and other than that doesn't save it anywhere.
Mike Crittenden
A: 

If you are not set on using Webform module, this could be a more complex, but suitable method for doing what you require.

  1. Set up a custom content type with the fields you require for your form with CCK
  2. Use a User Reference field to indicate which site user the form should be sent to
    • NodeReference URL could help in automatically populating the forms if you use Content Profile as well. Unfortunately there doesn't seem to be a 'UserReference URL' module.
    • PrePopulate will allow you to set the form's values from a link using GET parameters, though the links aren't as clean as NodeReference URL's method.
  3. Use Actions to send a message to the user specified on the from when it is submitted

It may be helpful to create a View which will list for each user the forms they have been sent, so that they can easily find them from one location.

You probably also want to set up a content access module so that not everybody can view the submitted forms. You will have to find one that suits your needs, but you should be able to set the content type to only be viewable by its recipient (and author, if necessary) or by certain roles (eg., all managers can see all requests)

GApple
A: 

thanks a lot i have done the same thing the only problem now i have is to the populate the fields with right content.

when the users sees one of the profile page or content created by the manager the recipient address should populate atomatically, i dono how do this.

can u give the summary how to do that..

rakesh