1

My case is this: I have a content type called 'Test Type' with 2 fields: Body (text area), Slideshow (Unlimited list of images) When I create an instance of Test Type and it renders, my goal would be to have the content of the Slideshow field go to a different region, let's say the header. First thought was to create a custom block that would hold a reference to the field content, but that does not seem to be an option. Is this possible to do through the UI with certain settings or would I be better off writing a module. The module Field as Block is pretty much exactly what I was looking for but it seems not work right now.

1
  • You could create a view with a Block display that filters to a particular node and displays only the Slideshow field.
    – mradcliffe
    May 5 '16 at 17:55
2

this can be possible by using views which is now in core in drupal 8

step 1 :: go to structure->views->add new views

step 2 :: Add new view ui will be opened

2.1.enter view name

2.2.under view settings select show content of type (the content type whose field you would like to place in an block ex:your required content type)

  1. 3.only check the check box create a block under block settings

    2.3.1.under BLOCK DISPLAY SETTINGS select the display format most likely (unformatted list) of fields

    2.3.2 now save and edit and you are good to go...

step 3 :: now views ui is opened

3.1.on the top left hand side of the page under title

3.2. under fields select add (an pop up ui will open)

3.3. select type content ->select the field types of your content you want to display in your block ex-body and so on and so forth as required by you now apply and save..

3.4. configure field will now open configure as required..you can also rewrite the fields so better follow this link rewrite fields

step 4 :: go to structure->blocks->place the block as per your required region->and find the block(it will be the same name as block name or view name unless changed)

4.1. place the block as per your wish there are many boundaries like selecting content type etc ...but for now select pages under visibility leave the check box as default and inside pages type <front> **remember to add less than and greater than sign as well

4.2.now save the block

step 5 :: in the block ui at the bottom also click save blocks and finally go back to the site

if all goes right you will see the content of a field from the content type in a block using views

1
  • Brilliant, had not ventured toward Views. Got exactly what I needed and more with some contextual filters. Thank you for the advice.
    – Kucerak
    May 5 '16 at 20:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.