I created a view to display a grid of video thumbnails, but nodes that have not been populated with any video content(but have an em field of course) are also appearing in the view. Is this a problem with EM field? The guidelines for the views issues asks that I post this here first.

The view has two fields, the episode video and a node title link to accompany it. Thanks for reading.

Comments

alex ua’s picture

Status: Active » Closed (fixed)

There is a Views filter for Emfield which does this for you. Under filters you should find something like (obviously your content type and field will have a different name):
Content: video_emfield (field_video_emfield)
Embedded Video - Appears in: External Video

highvoltage’s picture

Hey there, thanks for the quick response. ^_^

That is what I'm using for the field within views. Screenshot of my fields in the view:

http://img196.imageshack.us/img196/8042/view02.png

alex ua’s picture

I understand, but you are asking how to filter out nodes without emfield content, so you need to do that under filters, not fields.

highvoltage’s picture

Ugh, well I feel like an idiot. I read that as field not filter. I set filter to Is not empty(NULL) and it's working properly. Thank you.

kbeck303’s picture

Title: EM fields with no content are appearing in views. » EM fields thumbnails with no content are appearing in views.
Version: 6.x-1.0 » 6.x-1.18
Component: Miscellaneous » Embedded Media Thumbnail
Status: Closed (fixed) » Active

I have a similar issue.

I have a blog view - title, body, photos, and video embed. Not all blog post have photos or video, so I set the field setting to "hide if empty".

The photo "hide if empty" hides the entire photo field div (div class="views-field-field-blog-photos-fid"). But the video "hide if empty" hides the (div class="field-content"), but leaves the main div (div class="views-field-field-blog-video-embed")

jaarong’s picture

I have the same issue. My users can post a photo or a video. Views has fields for both and just hides the one that is empty. The imagefield works nicely when nothing is there (and there is video), but the field with a video ends up looking for a thumbnail that isn't there when there is an image but no video.

I don't see how a filter would work for me, since if there was an image and no video, it would just filter it out. I want an either/or situation to be displayed.

mattfielding’s picture

I'm facing the same issue as subnet_rx. It seems as though the video thumbnail field has something in it for every node and hence the 'hide if empty' option in views has no effect, showing a broken image link instead.

mattfielding’s picture

I had to use Views Custom Field to work around the issue

gordon’s picture

subscribe

gordon’s picture

Assigned: Unassigned » gordon
Status: Active » Needs review
StatusFileSize
new2.21 KB

Here is a fix for this issue which will return NULL when there is no embedded link. Good for optional fields

vthirteen’s picture

Version: 6.x-1.18 » 6.x-1.25
Status: Needs review » Reviewed & tested by the community

the patch at #10 works for me.

aaron’s picture

Status: Reviewed & tested by the community » Fixed

committed, thanks @gordon!

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.