Thursday, September 26, 2013

Install a contact me form on Drupal

These instructions helped me out.

Enabling the Contact Module in Drupal 7:
  1. Log into your Drupal 7 dashboard
  2. Go to Modules
  3. Find the “Contact” module, place a check mark next to it and click "Save configuration"
    drupal_contact_1
  4. Close the overlay by clicking the “X” in the right corner
  5. Now that your contact form is enabled, you’ll have to change the permissions so everyone can use it. Click “People” in the top admin menu bar
  6. Click the the “Permissions” Tab in the right corner
    drupal_contact_2
  7. Scroll down to the contact section and check the boxes you want to apply to the permissions. If you want everyone to be able to use your form, set Use the site-wide contact form to both ANONYMOUS USER and AUTHENTICATED USER.
    drupal_contact_3
  8. Click “Save Permissions” at the bottom of the overlay
Your default contact form is now ready to use. However, there’s no link on your website for it. For more information on configuring the contact form and adding a link in your menu to it, please see our other articles.
Now that you have installed the “contact” module in Drupal 7, it’s time to create and configure the contact form.
  1. Log into your Drupal Dashboard
  2. Go to Structure >> Contact form
  3. Click Edit next to the default Website feedback category
    drupal_contact_config_1
  4. Fill in the fields appropriately.

    CategoryEnter a category (more like a title) for your feedback form.
    RecipientsEnter the email addresses that you would like the results of the form emailed to. If sending to more than one email address, put each email address on its own line.
    Auto-replyIf you would like an auto reply message sent, enter it here. For example, some users prefer to get an email similar to, "We have received your feedback and will get back to you soon."
    WeightOn pages that list the available forms, you can change where this form is listed by adjusting the weight here.
    SelectedIf you would like this to be the default form, set Selected to yes.

    drupal_contact_config_2
  5. Now you can see if the form is created. If you need to edit the form in the future, simply click “Edit” from this screen or if you want to permanently delete the form click “Delete
    drupal_contact_config_3
The form will be available if you visit yourdomain.com/contact but will not show up on your website until you add it to the navigation. For more information on adding the contact link to your website’s navigation, please see our article.

Before being able to add the contact form into your main menu, you should have already installed the contact module and configured the settings. Now, you need to create a way for your website’s visitors to actually find and access the form. You can add a contact link to your main menu via the Drupal dashboard.
  1. Log into your Drupal 7 Dashboard
  2. Go to Structure >> Menu
  3. Click Edit Menu next to Main Menu
    drupal_contact_nav_1
  4. Click on the List Links tab in the top right
  5. Ensure you are on the LIST LINKS tab (tabs are shown in the top right) and then click Add Link in the top left
  6. Fill out the desired fields with the appropriate data.

    Menu link titleThis is going to be the actual text the users click on in the menu to get to this page.
    PathAs the contact form by default is located at http://domain.com/contact, entercontact as the path.
    DescriptionThe Description field will display its contents when using the mouse to hover over the menu link.
    EnabledThe Enabled box must be checked for the menu item to be visible.
    Show as expandedIf this menu item has children, always show the children.
    Parent linkParent Link is for use if you want to place the menu under another menu item as a child. By default, this is set to <Main Menu> so it is on the top level.
    WeightWeight is a numerical designation for where the item will display in the menu. The lower the number, the higher or more to the left the menu item is placed.
    drupal_contact_nav_2
  7. Click Save

    Now, when you visit your website, you’ll see that there is now a link to your contact from in the menu bar. 
    drupal_contact_nav_3




No comments: