With using 7.x-3.x-dev and inserting a video into a paragraph, with all tags allowed in my text format and on a clean Drupal 7.34 site, I am getting the following error:

Notice: Undefined index: attributes in theme_video_filter_iframe() (line 322 of /[my-path]/sites/all/modules/contrib/video_filter/video_filter.module).

The video still shows up but with this error on saving the node. Might be related to the issue indicated (https://www.drupal.org/node/786774). Anyhow know what this error is from?

Thanks.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

joep.hendrix’s picture

The problem is caused by:

  if ($video['attributes']) {
    $attributes = drupal_attributes($video['attributes']);
  }

This should be:

  if (!empty($video['attributes'])) {
    $attributes = drupal_attributes($video['attributes']);
  }
rajmataj’s picture

Issue summary: View changes
rajmataj’s picture

Status: Active » Needs review

@joep.hendrix

Good catch. I tried that out and it works. Hopefully the contributors will get this into dev and then into the stable release before long. Most videos are https (from YouTube) so this module definitely needs the update to stay with the times. The last stable release was 2012. Anyhow, thanks for your sleuthing.

mherchel’s picture

Confirmed #1 fixes the issue. Patch attached.

emmonsaz’s picture

I believe you missed one...

loopduplicate’s picture

Status: Needs review » Closed (duplicate)

Closing this as a duplicate of https://www.drupal.org/node/2338423 . Both issues have the same fix and the other issue is already marked RTBC.
Cheers,
loopduplicate