From ff31226fdeb972aac2f37f0098240cb366a9bb26 Mon Sep 17 00:00:00 2001 From: brettp Date: Wed, 5 May 2010 19:14:48 +0000 Subject: Merged 18_new_admin branch to trunk. git-svn-id: http://code.elgg.org/elgg/trunk@5977 36083f99-b078-4883-b0ff-0f9b5a30f544 --- views/default/admin/components/plugin.php | 155 ++++++++++++++++++++++++++++++ 1 file changed, 155 insertions(+) create mode 100644 views/default/admin/components/plugin.php (limited to 'views/default/admin/components/plugin.php') diff --git a/views/default/admin/components/plugin.php b/views/default/admin/components/plugin.php new file mode 100644 index 000000000..e56cdd4ef --- /dev/null +++ b/views/default/admin/components/plugin.php @@ -0,0 +1,155 @@ + 10) { + $top_url = "{$vars['url']}action/admin/plugins/reorder?plugin={$plugin}&order=1&__elgg_token=$token&__elgg_ts=$ts"; + $top_link = '' . elgg_echo('top') . ''; + + $order = $vars['order'] - 11; + + $up_url = "{$vars['url']}action/admin/plugins/reorder?plugin={$plugin}&order=$order&__elgg_token=$token&__elgg_ts=$ts"; + $up_link = '' . elgg_echo('up') . ''; +} + +if ($vars['order'] < $vars['maxorder']) { + $order = $vars['order'] + 11; + $down_url = "{$vars['url']}action/admin/plugins/reorder?plugin={$plugin}&order=$order&__elgg_token=$token&__elgg_ts=$ts"; + $down_link = '' . elgg_echo('down') . ''; + + $order = $vars['maxorder'] + 11; + $bottom_url = "{$vars['url']}action/admin/plugins/reorder?plugin={$plugin}&order=$order&__elgg_token=$token&__elgg_ts=$ts"; + $bottom_link = '' . elgg_echo('bottom') . ''; +} + +if ($active) { + $url = "{$vars['url']}action/admin/plugins/disable?plugin=$plugin&__elgg_token=$token&__elgg_ts=$ts"; + $enable_disable = '' . elgg_echo('disable') . ''; +} else { + $url = "{$vars['url']}action/admin/plugins/enable?plugin=$plugin&__elgg_token=$token&__elgg_ts=$ts"; + $enable_disable = '' . elgg_echo('enable') . ''; +} + + +$categories_list = ''; +if ($manifest['category']) { + $categories_arr = array(); + $base_url = "{$vars['url']}pg/admin/plugins?category="; + + foreach($manifest['category'] as $category) { + $url = $base_url . urlencode($category); + $categories_arr[] = "" . htmlspecialchars($category) . ''; + } + + $categories_list = implode(', ', $categories_arr); +} + +$screenshots = ''; +if ($manifest['screenshot']) { + $base_url = "{$vars['url']}mod/"; + + $limit = 4; + foreach ($manifest['screenshot'] as $screenshot) { + if ($limit <= 0) { + break; + } + + $screenshot_src = $base_url . $plugin . "/$screenshot"; + $screenshots .= "
  • "; + + $limit--; + } +} + +?> + +
    +
    + +
    + +
    + + [". elgg_echo('settings') ."]"; + } + ?> +

    + +
    $manifest['description'])); ?>
    +
    : ". htmlspecialchars($manifest['author']) ?>
    +
    : ". htmlspecialchars($manifest['version']) ?>
    + +

    + + +
    \ No newline at end of file -- cgit v1.2.3