I use the latest media 7.x-2.x-dev and when adding a youtube video, the node title is the youtube id e.g. "_vfsnZwu2iI" instead of the movie title.

The movie-title is imported correctly into the field "media_title" defined here "admin/config/media/file-types/manage/video/fields".

Members fund testing for the Drupal project. Drupal Association Learn more


Dave Reid’s picture

Title: Youtube title with media 7.x-2.x-dev » Set $file->filename as video title
Project: Media » Media: YouTube
Version: 7.x-2.x-dev » 7.x-1.x-dev
Category: bug » support

The Media module doesn't actually change anything about the node title? Note that with the latest changes in File entity you can now manually change the File name yourself. Moving this issue to Media: Youtube since I wonder if we can get the Youtube stream wrapper to have the Video title as $file->filename.

Dave Reid’s picture

Category: support » feature
Status: Active » Needs review
646 bytes

Something like this I think would work but would need to be tested.

andorraclaim’s picture

Worked for me using with media-7.x-2.x-dev

valderama’s picture

I tested this patch with media_youtube 7.x-1.0-rc3 and it seems to work even there.

As the media module allows (and somehow forces) the user to re-use the same video, each video needs a name which can be recognized. Therefor this tiny change in the module should really go into the next version of media_youtube, both 1.x and 2.x

If there is any way I can help, let me know.


Anonymous’s picture

Patched the 7.x-1.x-dev version and it works nice. Thanks for the Patch.

Ghelici’s picture

Great Patch !
For the thumbnail, it's still have the youtube part of the link as filename. Is there a patch for that?

Dave Reid’s picture

Status: Needs review » Fixed

Status: Fixed » Closed (fixed)

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