SPECIAL OFFER: Only $69 for access to everything in OSTraining for 1 year! You save $75! 
Join today and get access to 1,000's of books and videos. Learn WordPress, Drupal, Magento, Joomla and more! Sign up today!

Node reference - image

5 years 11 months ago #117990 by ahmedsiddiq
Node reference - image was created by ahmedsiddiq
Hi

Using node reference, when I reference another node, how can I pull its image as an out put.

That is currently when I am using the node reference , referencing another node, in the output I get Title of that referenced node, while what I want is a image of that node.

In following I use Title.



please guide

regards

This message has an attachment image.
Please log in or register to see it.

Please Log in to join the conversation.

5 years 11 months ago #117996 by steve
Replied by steve on topic Node reference - image
Hi Ahmed

The node reference module is not much used these days.

The Entity Reference module can do the same thing and it can pull in images using Views:
www.drupal.org/project/entityreference_view_widget

Please Log in to join the conversation.

5 years 10 months ago #118378 by ahmedsiddiq
Replied by ahmedsiddiq on topic Node reference - image
Hi Steve

I am on the Entity reference view widget.

I am targeting a field of my content that is in this case a poster.

However, only the Title is appearing in the final content, even if I remove Content: Title (Title) from FIELDS and that leaves the field with 1) Entity Reference View Widget Checkbox: Content (Content) , 2) Content: Poster (Poster) , even in this case the Title appears in the final content page , while I want a poster/image there.



Please guide as how can I get in the poster/ image here.

regards
Ahmed

This message has an attachment image.
Please log in or register to see it.

Please Log in to join the conversation.

5 years 10 months ago #118380 by steve
Replied by steve on topic Node reference - image
Hi Ahmed

It looks like you've done almost everything this right. Take a look at this video below. Have you altered the field settings as shown from 5.30?

Please Log in to join the conversation.

5 years 10 months ago #118403 by ahmedsiddiq
Replied by ahmedsiddiq on topic Node reference - image
Hi Steve

I am a bit confused here& need your help.

As at the beginning of this post I was advised to use www.drupal.org/project/entityreference_view_widget .

In the second and last post by you, you have referred a entity reference video. ( they are two different things )

Moreover, the second video ( last post by you ) , does not mentions any thing about replacing the "TITLE" with the "POSTER" field.

Please guide.

regards
Ahmed

Please Log in to join the conversation.

5 years 10 months ago #118418 by Valentin
Replied by Valentin on topic Node reference - image
Hi Ahmed,

May you clarify with step by step details what do you need to achieve, please

Looking forward to help you

Kind regards,
Valentín

Follow us on Twitter - twitter.com/OSTraining
Like us on Facebook - facebook.com/ostraining

Please Log in to join the conversation.

5 years 10 months ago #118423 by ahmedsiddiq
Replied by ahmedsiddiq on topic Node reference - image
Hi

I am on the Entity reference view widget.

I am targeting a field of my content that is in this case a poster.

However, only the Title is appearing in the final content, even if I remove Content: Title (Title) from FIELDS and that leaves the field with following.
1) Entity Reference View Widget Checkbox: Content (Content)
2) Content: Poster (Poster) ,

even in this case the Title appears in the final content page , while I want a poster/image there.




Please let me know if further elaboration is required.

kindly guide.

regards

This message has an attachment image.
Please log in or register to see it.

Please Log in to join the conversation.

5 years 10 months ago #118425 by Valentin
Replied by Valentin on topic Node reference - image
Please double check the poster field is related to the same content type from the title.
I made this mistake while I learn Drupal a couple of times.

Kind regards,
Valentín

Follow us on Twitter - twitter.com/OSTraining
Like us on Facebook - facebook.com/ostraining

Please Log in to join the conversation.

5 years 10 months ago #118430 by ahmedsiddiq
Replied by ahmedsiddiq on topic Node reference - image
Yes , Title & Poster are two fields of same node.

I have two nodes A & B

Node A has certain fields , while Node B has two fields Title & poster.

Now I want to bring in the poster of Node B into display of node A , using entity reference view widget, kindly refer to the image in my last reply in this post.

regards
Ahmed

Please Log in to join the conversation.

5 years 10 months ago #118431 by Valentin
Replied by Valentin on topic Node reference - image
Do you have this site in a live server, so I can take a look?

Follow us on Twitter - twitter.com/OSTraining
Like us on Facebook - facebook.com/ostraining

Please Log in to join the conversation.

5 years 10 months ago #118435 by ahmedsiddiq
Replied by ahmedsiddiq on topic Node reference - image
no I am on a local host

regards

Please Log in to join the conversation.

5 years 10 months ago - 5 years 10 months ago #118444 by ahmedsiddiq
Replied by ahmedsiddiq on topic Node reference - image
Using Entity Reference Auto fill, I was able to achieve this.

However, a major drawback it has is that it works when the number of value is 1 , when its changed to higher then one , the functionality does not works.




& I want the number of values to be atleast 5 or unlimited.
Please guide.

This message has an attachment image.
Please log in or register to see it.

Please Log in to join the conversation.

5 years 10 months ago #118445 by ahmedsiddiq
Replied by ahmedsiddiq on topic Node reference - image
As per www.drupal.org/project/entityreference_autofill , the same would work just for 1 field.

However as per this www.drupal.org/node/2481739

I would like to try this out ( above link ) , can you please guide how administrator content permission can be enabled.

please guide.

regards
Ahmed

Please Log in to join the conversation.

5 years 10 months ago #118452 by Valentin
Replied by Valentin on topic Node reference - image
Did you tried to set unlimited?

Unfortunately I would have more chances to see what's going on by having this project in a live server.

Kind regards,
Valentín

Follow us on Twitter - twitter.com/OSTraining
Like us on Facebook - facebook.com/ostraining

Please Log in to join the conversation.

Join today and get access to 1,000's of books and videos. Learn WordPress, Drupal, Magento, Joomla and more! Sign up today!