I get the following errors when trying to create a playlist.

* warning: Illegal offset type in isset or empty in mysite\includes\bootstrap.inc on line 831.
* warning: Illegal offset type in mysite\includes\bootstrap.inc on line 832.
* warning: Illegal offset type in mysite\includes\bootstrap.inc on line 836.

Comments

svogel’s picture

As far as I see, there is a problem in audio_playlist.module (function audio_playlist_add_form line 80)

drupal_set_message("At least one content type must have <a href='!url'>audio attachments enabled</a> for playlists to work.", array('!url' => url('admin/content/types')));

Seems to me as this should look like this:

drupal_set_message(t("At least one content type must have <a href='!url'>audio attachments enabled</a> for playlists to work.", array('!url' => url('admin/content/types'))));

Pay attention to the t(..)-function.
Well, at least now you should be able to read the error-message :-)

By the way: Audio attachments can be enabled under the "workflow"-group in the content-type-form

Turns out to be of no use. Now the error-message is:

Fatal error: Cannot use object of type stdClass as array in C:\svogel\Programme\xampp\htdocs\downloadmymusic\includes\form.inc on line 110

Best regards
Stefan

drewish’s picture

Title: Cannot create playlist » Update audio_playlist for D6

yeah as per the release notes (http://drupal.org/node/262540) it hasn't been updated.

svogel’s picture

Ok, now that you said ... :-)
It seems also to be a duplicate to #316794: warning: Illegal offset type in isset or empty bootstrap.inc

svogel’s picture

StatusFileSize
new3.23 KB

I just give it a quick shot and tried Deadwood on audio_playlist-module.
After some corrections "something" is working. For all outta there, that want to give it a quick start, I attach my half-working version.

But another questions arises. I added "attach audio" to the story-content-type. When trying to "add-to-playlist" I got the error "function audio_prepare unknown" (in file audio_attach.module line 153).
Simply uncommenting this call (I didn't find the function as well ;-) helped.

So hopefully someone with more Drupal 6 knowledge catches this up.

drewish’s picture

svogel, please do not post zip files. post a patch because i'm not going to download the zip file and extract it just to figure out what you changed to get it working.

svogel’s picture

Version: 6.x-1.x-dev » 6.x-1.0-unstable3

Ok, I tried a diff (against unstable-2), there is a lot of output (all due to comments inserted by deadwood). Reducing it to the essential change:

77c77
< function audio_playlist_add_form(&$form_state, $node = NULL) {
---
> function audio_playlist_add_form($node = NULL) {
80c80
<     drupal_set_message(t("At least one content type must have <a href='!url'>audio attachments enabled</a> for playlists to work.", array('!url' => url('admin/content/types'))));
---
>     drupal_set_message("At least one content type must have <a href='!url'>audio attachments enabled</a> for playlists to work.", array('!url' => url('admin/content/types')));
160c160
<     $rows[$node->nid] = $node->title ."<small> " . l("(i)", 'node/'. $node->nid, array('attributes' => array("target" => "_blank"))) ."</small>";
---
>     $rows[$node->nid] = $node->title ."<small> " . l("(i)", 'node/'. $node->nid, array("target" => "_blank")) ."</small>";

Hope that helps a bit.

svogel’s picture

Version: 6.x-1.0-unstable3 » 6.x-1.x-dev

Hi drewish,

in audio_playlist from Dec, 9 there is a function call to audio_attach_add_child (line #128).
But no such function is in the audio_attach.module.
Sorry for bugging you, but I like this module and I really like to get that into my drupal 6 installation (in fact it's the only module left stopping the upgrade to 6)

Thanks and best regards
Stefan

RamMohanSakhamuri’s picture

Version: 6.x-1.0-unstable3 » 6.x-1.x-dev

Hi,

Iam getting this message "At least one content type must have audio attachments enabled for playlists to work."after changing the code to

drupal_set_message(t("At least one content type must have audio attachments enabled for playlists to work.", array('!url' => url('admin/content/types'))));..where should i add the audio attachment

Thanks

svogel’s picture

Hi RamMohanSakhamuri,

you have to specifiy a content-type for your playlist.
Got to Administer > Content type
choose a content-type and open the "workflow settings"-part and "enable" "attach audio files".

azeliteit’s picture

I get this when i attempt to create a playlist "At least one content type must have audio attachments enabled for playlists to work."

I followed this

"you have to specifiy a content-type for your playlist.
Got to Administer > Content type
choose a content-type and open the "workflow settings"-part and "enable" "attach audio files"."

but I still get the error

Stan.Ezersky’s picture

I can't see

enable "attach audio files"

Where is it?

lozamonte’s picture

I can't see , Where is it?. I feel stupid.

Please I need help.

Waven’s picture

i get similar errors. Im using the most recent version of audio 6. Ive created playlist in content type, im logged in as administrator, ive created a playlist on administrator, I click add to play list on uploaded audio file, then get the following results

warning: Illegal offset type in unset in /html/includes/bootstrap.inc on line 855.
warning: Illegal offset type in /html/includes/bootstrap.inc on line 856.
warning: Illegal offset type in /html/includes/bootstrap.inc on line 860.

Does anyone know how to fix this?

Stan.Ezersky’s picture

warning: Illegal offset type in unset in /html/includes/bootstrap.inc on line 855.
warning: Illegal offset type in /html/includes/bootstrap.inc on line 856.
warning: Illegal offset type in /html/includes/bootstrap.inc on line 860.

Does anyone know how to fix this?

See post #4

solam’s picture

to see the "Attach audio files:" field you need to go back to Audio Attach 6.x-1.0-unstable2 instead of UNSTABLE3 or latest version
but then this error arises: user warning: Table 'drupal.audio_attach' doesn't exist query: SELECT aid, weight FROM audio_attach WHERE nid = 6 ORDER BY weight ASC in \drupal\sites\all\modules\audio\contrib\attach\audio_attach.module on line 248.
(on my config: every audio components are at version 6.x-1.0-unstable3 except Audio Attach 6.x-1.0-unstable2 + patched version of svogel's audio_playlist 6.x-1.0-unstable2.)

plato1123’s picture

Has anyone gotten the playlist function working yet? I've followed all the steps including those mentioned in #4 and #15 and am... well the same place Solam is, lots of error messages and it doesn't appear to work unless I don't know how to use it.

johnflower’s picture

I just found the audio module todat. it's very cool. I'm looking forward to the playlists working

hugafish’s picture

Have the same errors as in this thread except with different line numbers because it is a newer version. It appears this problem has not been fixed or it has reappeared or is related to some other patch on my system. I am using Drupal version Drupal 6.10 but will soon be going to version 6.13. I am using Audio 6.x-1.0-unstable4, and I installed the Audio Form Override 6.x-1.x patch from Drupal forum to get rid of all the token stuff during the audio upload process. My users do not need to see all of these options. Perhaps this patch is causing this problem with the add to playlist feature. Here is the error I am getting:

* warning: Illegal offset type in isset or empty in /home/jamacast/public_html/includes/bootstrap.inc
on line 865.
* warning: Illegal offset type in /home/jamacast/public_html/includes/bootstrap.inc on line 866.
* warning: Illegal offset type in /home/jamacast/public_html/includes/bootstrap.inc on line 870.

need this problem solved soon hopefully with some help from everyone. Thanks

Eric

hugafish’s picture

This is the most confusing and run around like experience I have seen yet to date with Drupal. Does the Add to Playlist work or not work with the current version? It so far looks as if it does not, even though it gives the impression as if it does by simply showing the Add to Playlist link? The link is there but returns just errors. Post 15 says: to see the "Attach audio files:" field you need to go back to Audio Attach 6.x-1.0-unstable2. Does this mean that then the add to playlist will work if I can "see the "Attach audio files:" option. I am assuming I will see this during the process of creating audio content as an option somewhere. How does one go back to an earlier version? is this done the same way as going forward, disable module, remove module, upload older module, activate older module then run update PHP ?

One idea to implement motivation would be for this Drupal site to have a paypal contrib link per module. This way modules such as audio module could be ranked and prioritized via it's actual importance to site owners and Developers. This beats the heck out of just trying to find some coder to hack your site for a fee, only to not have a standard grip on to what was done and/or possibly blowing out their code with some future update and then scrambling to fix. This would keep the modules flowing smoothly forward and developed quicker into a standard upload to site and turn on process, which was what attracted me to Drupal in the first place.

Eric

amartya’s picture

Version: 6.x-1.x-dev » 6.x-1.0-unstable4
Component: audio_playlist » audio_attach
Priority: Normal » Critical

Hi Guys,

I did every this article says... I still get "At least one content type must have audio attachments enabled for playlists to work.".... where do you download Audio Attach 6.x-1.0-unstable2 from... all the links i came across leads to Audio Attach 6.x-1.0-unstable4....

I'm REALLY confused... my issue is still not resolved, friends... can anyone guide me?

Respectfully,
Amartya

amartya’s picture

Assigned: Unassigned » amartya
Status: Active » Closed (fixed)

Issue: "At least one content type must have audio attachments enabled for playlists to work." after updating audio_playlist.info and audio_playlist.module from the zip file provided in a comment before...

It was suggested that in "Workflow" settings (under content type) "Attach audio files" needs to be enabled for at least one content type. But most never found "Attach audio files"... It was therefore suggested that the "/sites/all/modules/audio" be replaced with "Audio Attach 6.x-1.0-unstable2"...

However, no link to "Audio Attach 6.x-1.0-unstable2" was given... Here is one... http://ftp.drupal.org/files/projects/audio-5.x-1.4.tar.gz
I know this works because I've used it... don't forget to update audio_playlist.info and audio_playlist.module again... The issue is resolved and we now get the "Attach audio files" option... Though we get the error:

* user warning: Table 'poemsnpr_drupal.audio_attach' doesn't exist query: SELECT aid, weight FROM audio_attach WHERE nid = 77 ORDER BY weight ASC in /home/poemsnpr/public_html/sites/all/modules/audio/contrib/attach/audio_attach.module on line 248.
* user warning: Table 'poemsnpr_drupal.audio_attach' doesn't exist query: SELECT aid, weight FROM audio_attach WHERE nid = 371 ORDER BY weight ASC in /home/poemsnpr/public_html/sites/all/modules/audio/contrib/attach/audio_attach.module on line 248.
* user warning: Table 'poemsnpr_drupal.audio_attach' doesn't exist query: SELECT aid, weight FROM audio_attach WHERE nid = 74 ORDER BY weight ASC in /home/poemsnpr/public_html/sites/all/modules/audio/contrib/attach/audio_attach.module on line 248.

Obviously, the audio_attach.module file needs to be tricked more... But the playlist does got updated...

Therefore the discussion can be closed...

Respectfully,
Amartya

PS: I'm using this in http://www.poemsnprose.com/ so you may take a look...

amartya’s picture

Assigned: amartya » Unassigned
Status: Closed (fixed) » Active

we need to reopen this... it's concerning the audio_playlist.zip .... I get an error

Fatal error: Call to undefined function audio_attach_add_child() in /home/poemsnpr/public_html/sites/all/modules/audio/contrib/playlist/audio_playlist.module on line 187 ....

I did check audio_playlist.module where the function is called but did not find it defined anywhere in the file... it needs a fix

Amartya Ray

tim.plunkett’s picture

Version: 6.x-1.0-unstable4 » 6.x-1.x-dev
Component: audio_attach » audio_playlist
Category: bug » task
Priority: Critical » Normal

"This version is incompatible with the 6.13 version of Drupal core."

Probably because it hasn't be updated yet.

theohawse’s picture

So with the new release of unstable version 5 has this been re-visited yet? I've spent quite a few hours over the last few weeks playing with xspf playlist, and I can't get it to find attached audio files on nodes, even after applying the filefield patch from somewhere in their issue queue.

Ultimately I'd love to be able to have a playlist generated with views, say top 100 or even a nodequeue -sort of an editors picks. Perhaps it could work with a node referencing other nodes so playlists could come from audio albums. Then we could have popup players and the complaints about non-continuous playback would be gone forever.

There's so much that could be done after d6 audio playlists are working, although not necessary -this feature would really slam the drupal drop into the puddle when it comes to using audio vs other cms systems.

BTW Congratulations on on AMAZING module, have used it for many sites now and I don't know what I'd do without you guys. Thanks a million.

Here's what I've been doing with the Audio Module so far: http://www.discoverrock.com/carey-ott

vann’s picture

StatusFileSize
new2.43 KB

I attached a session-based version of this playlist module here, but I decided to remove comments on how to use it, and to submit it as a unique module.

zenrei’s picture

What are we supposed to do with this? How do we get it to work with the Audio Module?

zenrei’s picture

While we're waiting on a solution, is there a way to remove the "Add to playlist" link from the node?

Where can this be found: <a title="Add to playlist" href="/audio_playlist/1?destination=node/1">Add to playlist</a> I see it on the page, but I don't know where to go to find it in the node to remove it.

zenrei’s picture

ah, nevermind, I just had to disable the playlist mod.

jamesialford’s picture

I am haveing this problem also

darthcheeta’s picture

I need some more cowbell here. I need the playlist function for a site i had working in 5 and am redoing in 6. I've cut up 30 minute radio horror shows we did years ago into scenes and am re-rolling them out a scene at a time as podcasts. i need the playlist to stitch them all back together as complete episodes once they're all posted.

Has anyone got a clear, concise method to get it working? this queue is too muddled with misleads.

daj

darthcheeta’s picture

I need some more cowbell here. I need the playlist function for a site i had working in 5 and am redoing in 6. I've cut up 30 minute radio horror shows we did years ago into scenes and am re-rolling them out a scene at a time as podcasts. i need the playlist to stitch them all back together as complete episodes once they're all posted.

Has anyone got a clear, concise method to get it working? this queue is too muddled with misleads.

daj

kindbuds’s picture

Version: 6.x-1.0-unstable6 » 6.x-1.x-dev

Having same 'Add to Playlist' errors but different line numbers.
warning: Illegal offset type in isset or empty in /home2/kindbuds/public_html/includes/bootstrap.inc on line 873.
warning: Illegal offset type in /home2/kindbuds/public_html/includes/bootstrap.inc on line 874.
warning: Illegal offset type in /home2/kindbuds/public_html/includes/bootstrap.inc on line 878.

I am also having a horrible time getting any video player to actually show a video, other then embedded youtube. I have done everything the dash player tutorials have asked!!! it almost works.... but it just doesn't work.

Just wondering if it might be related to the Audio playlist issue or if anyone has the dash thread link with solution.

I am willing to trade a free room for a weekend in Tahoe or Martha's Vineyard for some experienced Drupal assistance.

theohawse’s picture

Priority: Normal » Critical

I'm also having this problem when clicking "add to playlist":

warning: Illegal offset type in isset or empty in /includes/bootstrap.inc on line 873.
warning: Illegal offset type in /includes/bootstrap.inc on line 874.
warning: Illegal offset type in /includes/bootstrap.inc on line 878.

using latest dev version of audio module, this issue has got to be the cat that just wouldn't stay away,
...or at least since 08

Karlheinz’s picture

Version: 6.x-1.x-dev » 6.x-1.0-unstable6

I'm getting those illegal offset errors as well. From the PHP documentation, this error occurs when you try to use an array (or object) as a key to another array.

The core function that is throwing this error is drupal_set_message(). Looking in the audio_playlist.module I can see an error at Line 80:

drupal_set_message("At least one content type must have <a href='!url'>audio attachments enabled</a> for playlists to work.", array('!url' => url('admin/content/types')));

What this is doing, is passing an array as the second value to drupal_set_message(), which is expecting a string value, thus causing the illegal offset error.

The code should be this:

drupal_set_message(t("At least one content type must have <a href='!url'>audio attachments enabled</a> for playlists to work.", array('!url' => url('admin/content/types'))));

Notice the inclusion of t(), which will substitute !url for the Drupal path to the Content Types page.

I changed this in my local copy, and it worked.

However - this is actually another bug now, because I got there by trying to add an audio node to the playlist. Since it's an audio node, audio attachments are naturally enabled, and I shouldn't be getting this error at all.

The code to check if audio attachments are enabled is at the bottom of audio_playlist.module:

/**
 *  Return the content types which have audio_attach enabled.
 */
function audio_playlist_get_playlist_types() {
  $node_types = node_get_types();
  $playlist_types = array();
  foreach ($node_types as $type => $name) {
    if (variable_get('audio_attach_'. $type, 0)) {
      $playlist_types[] = $type;
    }
  }
  return $playlist_types;
}

It looks like, even though audio attachments are enabled, the variable audio_attach_audio is not being set or retrieved correctly.

EDIT:
I just tried a temporary workaround, by making the first element of the array be "audio" no matter what:

function audio_playlist_get_playlist_types() {
  $node_types = node_get_types();
  $playlist_types = array();
  $playlist_types[] = 'audio';
  (...etc)

...but that just led to more errors, so I reverted.

EDIT 2:
Just to be clear - this only effects the "Add to playlist" link. The M3U, PLS, and XSPF playlist links all work fine for me.

DollarSign’s picture

Version: 6.x-1.x-dev » 6.x-1.0-unstable6

I realize I am not the first person to ask this, but this module seems not to work at all. Has there been a fix or series of fixes that leads to a working playlist solution? thanks!

yannickoo’s picture

I need the audio_playlist.module for a site, because you can't create multiple playlists with flag.

But the problem is, that this module doesn't work.

Any news?

yannickoo’s picture

While we're waiting on a solution, is there a way to remove the "Add to playlist" link from the node?

Where can this be found: Add to playlist I see it on the page, but I don't know where to go to find it in the node to remove it.

You can comment out the few lines in the module.

spyderpie’s picture

This is very frustrating. Has anyone been able to get this working?

yannickoo’s picture

I done it with the relativity module. I never more use the audio module. CCK + Filefield / Imagefield + GetID3 + Mediafront is better!

Yannnick

yngens’s picture

subscribe

akobashikawa’s picture

StatusFileSize
new249.21 KB

Hello, today I try made working playlist.
I attach a version I currently using.
Additionally, you need to define a content type (may be named playlist) with Audio Feeds:enable.
I hope this help you while working in better version.

regards