I tried to use audio_attach on a testsite and had this problem: if i upload a file from the node creation form of a cck playlist node, the uploaded audio file gets no title. this happens with tokens as well as with a manually entered title. also, the title enter field has no "red star", as you would expect from a required field.
upload through node/add/audio works well, also attaching existing audio nodes to a playlist node works.
using drupal 5.3.
i tried this with audio 5.x-1.3 and also with audio 5.x-2.x-dev.

CommentFileSizeAuthor
#5 audio_attach.zip3.77 KBjaymallison

Comments

zirafa’s picture

Make sure Get ID3 is installed and turned on. I have observed this behavior as well.

ju.ri’s picture

yes, getID3 is installed and the path is set in /settings/audio/getid3. it works when uploading through /node/add/audio.

michel3’s picture

well, same problem. solution for it?

id3 installed and works correctly throu node/add/audio, not from attachment

zzolo’s picture

same problem here.

jaymallison’s picture

Status: Active » Needs review
StatusFileSize
new3.77 KB

I don't know how to role a patch. But I did get this to work for me. I've attached a version of audio_attach.module that is working for me. This copy of the module is from the 2.x-dev codebase. The code that I added is below:

      // Flush the token cache, otherwise when importing multiple nodes they'll all
      // have the same title.
      token_get_values('node', $audio, TRUE);
      $audio->title = token_replace($audio->title_format, 'node', $audio);

I added it to the audio_attach_nodeapi function, it was a farely simple fix actually. I haven't tested it thoroughly but it appears to work fine. As far as I could tell, the module wasn't even trying to set the title of the uploaded file.