New users are unable to install the module if the wpaudioplayer files are located at drupal_get_path('module', 'mp3player') . '/mp3player'. I put those files in my libraries folder. As a result, mp3player_requirements() does not find them and refuses to enable the module. #880050: Configurable location for mp3players external files. added this requirement to the install file at the same time it added libraries support.

function mp3player_requirements($phase) {
  $t = get_t();
  $path = variable_get('mp3player_library_path', drupal_get_path('module', 'mp3player') . '/mp3player');
  $has_mp3player = file_exists($path .'/audio-player.js') && file_exists($path .'/player.swf');
  $requirements['mp3player'] = array(
    'title' => $t('MP3 Player'),
    'value' => $has_mp3player ? $t('Installed') : $t('Not found'),
  );
  if (!$has_mp3player) {
    $requirements['mp3player']['severity'] = REQUIREMENT_ERROR;
    $requirements['mp3player']['description'] = $t("MP3 Player requires the <a href='!mp3_url'>standalone WordPress Audio Player</a>.", array('!mp3_url' => 'http://wpaudioplayer.com/download'));
  }

  return $requirements;
}

My quick workaround was to edit the above function in mp3player.install so it wouldn't complain if the files weren't where it expected them to be. That way, I could enable the module and then set the path to my wpaudioplayer files in my libraries folder.

A more permanent fix is necessary.

Comments

markie’s picture

Version: 6.x-1.1 » 6.x-1.x-dev
Status: Active » Closed (duplicate)

In the new dev versions the libraries module is used.