HELP: Two Fields As one

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

Hi everyone,

How can I come up to display two fields as one, or a 'textfield' and a 'select list' displayed as one.

Here's the scenario:

Fields:

Field 1: [integer]
Field 2: [select list: gram, kilogram, pound]

Display/Output field:

Weight: 100 grams

You know, something like that.

So, what I'd like to do is display them as one in a node. I know I can do this using views but I don't like to use views.

Is there a module that combine 2 fields into 1 on display? Not group but combine (add one to another; prefix/suffix).

Hope you guys understand my noobish question.

Thank you and mabuhay.

Comments

Use computed field..

greenrmor's picture

Theming can do the trick, but the best answer .... 'computed field module' ... Try to explore in Views module not keep on relying node only :)

You could do this in CCK

killer_tilapia's picture
  1. Create a custom content type
  2. Add 1 textfield for the number
  3. Add 1 dropdown list and supply the values manually. Taxonomy terms would also work.

When the node is submitted then you fudge the output via theming or a preprocess hook.

Philippines

Group organizers

Group categories

Post category

Group notifications

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

Hot content this week