$b) ? 1 : -1); } function sort_plugins() { global $PLUGINS; usort($PLUGINS, 'plugin_cmp'); } function plugin_header() { global $PACKAGE, $PLUGINS, $PAGE, $DOCROOT; // Output plugin foreach ($PLUGINS as $plugin) { if ($plugin['id'] != $PAGE) continue; echo "

" . htmlspecialchars($plugin['description']) . "

\n"; $fmt = array(); if (isset($plugin['clap_uid']) && ($plugin['clap_uid'])) array_push($fmt, 'CLAP'); if (isset($plugin['gst_uid']) && ($plugin['gst_uid'])) array_push($fmt, 'GST'); if (isset($plugin['jack']) && ($plugin['jack'])) array_push($fmt, 'JACK'); if (isset($plugin['ladspa_label']) && (strlen($plugin['ladspa_label']) > 0)) array_push($fmt, 'LADSPA'); if ((isset($plugin['lv2_uri'])) && (strlen($plugin['lv2_uri']) > 0)) array_push($fmt, 'LV2'); if ((isset($plugin['vst2_uid'])) && (strlen($plugin['vst2_uid']) > 0)) array_push($fmt, 'VST2'); if ((isset($plugin['vst3_uid'])) && (strlen($plugin['vst3_uid']) > 0)) array_push($fmt, 'VST3'); $full_name = htmlspecialchars("{$PACKAGE['short']} {$plugin['description']} ({$plugin['acronym']})"); $author = htmlspecialchars($plugin['author']); echo "\"{$plugin['name']}\"\n"; echo "

Detailed: {$full_name}

\n"; echo "

Formats: " . implode(', ', $fmt) . "

\n"; echo "

Categories: " . implode(', ', $plugin['groups']) . "

\n"; echo "

Developer: {$author}

\n"; echo "

Description: 

\n"; break; } } function out_image($id, $alt) { global $DOCROOT; echo "\"{$alt}\"\n"; } function plugin_ref($id) { global $DOCROOT, $PACKAGE; $page = find_menu_item($id); if (!isset($page)) return; $header = htmlspecialchars("{$PACKAGE['short']} {$page['text']}"); print("{$header}"); } ?>