How To Automatically Generate Node Titles from cck fields ?

  0 comments
Share

There are many possible reasons to replace the title, but most of them come down to this ... the title field is not very flexible.

Let's take an example that you're creating a content type for adding the details of employee to your site. In this case, you'd like the employee's name to be the title of each page. you can replace the default title with specific "First Name" and "Last Name" fields. The greatest advantage is that You will give no extra effort to add title field to completing a form.

Installation

To take the advantage of Automatically Generate Node Titles, You need to install these two modules:

Configure Automatic Nodetitles for your Content Type

  • After installing these two modules. Go to Structure ? Content types
  • Select "Automatically generate the title and hide the title field" radio button under "automatic title generation" area

    configure_0.png

  • Set the Pattern for the title(which will comes from other cck fields).
    Add pattern like this [node:field_first_name] [node:field_last_name], which automatically replace the title with the First name and Last name fields.

    Set pattern Image

Create the content for that content type

  • Click Add content and create an example of your content type
  • You will Notice that the title field is completely missing

    Add content

  • Save the content and your title will be automatically generated:

    Automatic nodetitles output

Add new comment