summaryrefslogtreecommitdiff
path: root/lib/plugins/extension/helper/list.php
diff options
context:
space:
mode:
authorAndreas Gohr <andi@splitbrain.org>2013-08-11 11:52:47 +0200
committerAndreas Gohr <andi@splitbrain.org>2013-08-11 11:52:47 +0200
commit7ca0915cf61dd8ff297bf1d3ebd6aafcab88a618 (patch)
treebdec1ec461676821ec8b6a8332c406a463f0d92b /lib/plugins/extension/helper/list.php
parente445eeb3b675b350b4cebeeea610d4f7cd2e8f19 (diff)
downloadrpg-7ca0915cf61dd8ff297bf1d3ebd6aafcab88a618.tar.gz
rpg-7ca0915cf61dd8ff297bf1d3ebd6aafcab88a618.tar.bz2
fixed donation link
Diffstat (limited to 'lib/plugins/extension/helper/list.php')
-rw-r--r--lib/plugins/extension/helper/list.php18
1 files changed, 12 insertions, 6 deletions
diff --git a/lib/plugins/extension/helper/list.php b/lib/plugins/extension/helper/list.php
index 7ecd5b267..ef589dedd 100644
--- a/lib/plugins/extension/helper/list.php
+++ b/lib/plugins/extension/helper/list.php
@@ -343,6 +343,14 @@ class helper_plugin_extension_list extends DokuWiki_Plugin {
$default = $this->getLang('unknown');
$return = '<dl class="details">';
+ if ($extension->getDonationURL()) {
+ $return .= '<dt>'.$this->getLang('donate').'</dt>';
+ $return .= '<dd>';
+ $return .= '<a href="'.$extension->getDonationURL().'" class="donate">'.$this->getLang('donate_action').'</a>';
+ $return .= '</dd>';
+ }
+
+
if (!$extension->isBundled()) {
$return .= '<dt>'.$this->getLang('downloadurl').'</dt>';
$return .= '<dd>';
@@ -393,6 +401,7 @@ class helper_plugin_extension_list extends DokuWiki_Plugin {
foreach ($extension->getCompatibleVersions() as $date => $version) {
$return .= $version['label'].' ('.$date.'), ';
}
+ $return = rtrim($return, ', ');
$return .= '</dd>';
}
if($extension->getDependencies()) {
@@ -415,9 +424,6 @@ class helper_plugin_extension_list extends DokuWiki_Plugin {
$return .= $this->make_linklist($extension->getConflicts());
$return .= '</dd>';
}
- if ($extension->getDonationURL()) {
- $return .= '<a href="'.hsc($extension->getDonationURL()).'" class="donate" title="'.$this->getLang('donate').'"></a>';
- }
$return .= '</dl>';
return $return;
}
@@ -431,9 +437,9 @@ class helper_plugin_extension_list extends DokuWiki_Plugin {
function make_linklist($ext) {
$return = '';
foreach ($ext as $link) {
- $return .= '<a href="'.$this->gui->tabURL('search', array('q'=>'ext:'.$link)).'">'.hsc($link).'</a> ';
+ $return .= '<a href="'.$this->gui->tabURL('search', array('q'=>'ext:'.$link)).'">'.hsc($link).'</a>, ';
}
- return $return;
+ return rtrim($return, ', ');
}
/**
@@ -482,7 +488,7 @@ class helper_plugin_extension_list extends DokuWiki_Plugin {
}
}
- if (!$extension->isInstalled()) {
+ if (!$extension->isInstalled() && $extension->getDownloadURL()) {
$return .= ' <span class="version">'.$this->getLang('available_version').' ';
$return .= ($extension->getLastUpdate() ? hsc($extension->getLastUpdate()) : $this->getLang('unknown')).'</span>';
}