I have been struggling on how to add a content type that adds content to two different regions/blocks for one node or page. One content would go to the normal content region and photo/images would go to the right sidebar region in a block. You can obviously create a content type with added images in all sorts of ways but just to one region normally the content region. Each node in my case must show mostly text in the content region middle column and photos in the right sidebar in a block. The photos will be different from page to page etc. Any ideas?

Comments

nevets’s picture

Sure create a content type with the fields you want including one for the images. Under 'Display fields' check 'Exclude" for the image field (for both teaser and Full Node).

Now you can make the block in two ways, CCK Blocks and Views. I have not tried CCK Blocks but it sounds easy to use. With views you will want a unformatted view with a row style of 'fields'. You would need an argument on Node: Nid, set "Action to take if argument is not present" to "Provide default argument" and "Default argument type" to "Node ID from URL". For "Validator" pick "node" and select the appropriate type under "Types". Under Fields add your image field.

Funkwarrior’s picture

Hello nevets,

I'm in the same condition and I don't want to use CCK Blocks, I don't like the approach. Can you help me to understand better the Views solution please?
Thank you so much.

seanray’s picture

It would be good if you can draw a picture about what you want, but in general, i think Drupal can do it in couple hours development. This is not a hard job for Drupal.

Best Drupal Hosting | Affordable Web Hosting | Drupal Tutorials

nsurround’s picture

Thanks for your response. I am sure your right that with the right coding development that this can be done. However it seems that this should be better covered in the CCK, filefield, and imagefield modules themselves without extra code modifications and development.
I am still learning drupal and how and what to use for modules etc. but it does seem a bit convoluted to do this type of thing. I looked at other posts in this regards and were not much help for drupal 6.x version. Thanks again.

nevets’s picture

I do not think it convoluted, see my comment above.

nsurround’s picture

After checking out the cc block module for drupal 6.x, found it did mostly what I was looking for. Thanks. I originally thought that the views module would also a solution and it probably does. However I am not quite familiar with this extensive module yet and thought there might be something else that addressed this issue in an easier way. The cck block module did the trick! Very easy to use and with your other tips got things up and running in no time. Thanks again.