diff --git a/e107_admin/plugin.php b/e107_admin/plugin.php
index 8e7e644f7..32987b48c 100644
--- a/e107_admin/plugin.php
+++ b/e107_admin/plugin.php
@@ -44,6 +44,7 @@ if(e_AJAX_REQUEST && isset($_GET['src'])) // Ajax
$dir = basename($unarc[0]['filename']);
+ /* Cannot use this yet until 'folder' is included in feed.
if($dir != $p['plugin_folder'])
{
@@ -52,6 +53,7 @@ if(e_AJAX_REQUEST && isset($_GET['src'])) // Ajax
echo "
pfolder=".$p['plugin_folder'];
exit;
}
+ */
if($unarc[0]['folder'] ==1 && is_dir($unarc[0]['filename']))
{
@@ -70,6 +72,7 @@ if(e_AJAX_REQUEST && isset($_GET['src'])) // Ajax
{
print_a($unarc);
$status = "There was a problem";
+ //unlink(e_UPLOAD.$localfile);
}
echo $status;
@@ -94,7 +97,6 @@ require_once (e_HANDLER.'message_handler.php');
$plugin = new e107plugin;
-$frm = new e_form();
$pman = new pluginManager;
define("e_PAGETITLE",ADLAN_98." - ".$pman->pagetitle);
require_once("auth.php");
@@ -126,6 +128,11 @@ class pluginManager{
$this -> action = ($tmp[0]) ? $tmp[0] : "installed";
$this -> id = varset($tmp[1]) ? intval($tmp[1]) : "";
$this -> titlearray = array('installed'=>EPL_ADLAN_22,'avail'=>EPL_ADLAN_23, 'upload'=>EPL_ADLAN_38);
+
+ if(isset($_GET['mode']))
+ {
+ $this->action = $_GET['mode'];
+ }
$keys = array_keys($this -> titlearray);
$this->pagetitle = (in_array($this->action,$keys)) ? $this -> titlearray[$this->action] : $this -> titlearray['installed'];
@@ -137,6 +144,8 @@ class pluginManager{
"plugin_icon" => array("title" => EPL_ADLAN_82, "type"=>"icon", "width" => "5%", "thclass" => "middle center",'class'=>'center', "url" => ""),
"plugin_name" => array("title" => EPL_ADLAN_10, "type"=>"text", "width" => "30", "thclass" => "middle", "url" => ""),
"plugin_version" => array("title" => EPL_ADLAN_11, "type"=>"numeric", "width" => "5%", "thclass" => "middle", "url" => ""),
+ "plugin_date" => array("title" => "Release ".LAN_DATE, "type"=>"text", "width" => "auto", "thclass" => "middle"),
+
"plugin_folder" => array("title" => EPL_ADLAN_64, "type"=>"text", "width" => "10%", "thclass" => "middle", "url" => ""),
"plugin_category" => array("title" => LAN_CATEGORY, "type"=>"text", "width" => "15%", "thclass" => "middle", "url" => ""),
"plugin_author" => array("title" => EPL_ADLAN_12, "type"=>"text", "width" => "auto", "thclass" => "middle", "url" => ""),
@@ -259,61 +268,84 @@ class pluginManager{
function pluginOnline()
{
- global $plugin, $frm;
+ global $plugin;
+ $tp = e107::getParser();
+ $frm = e107::getForm();
+
$caption = "Search Online";
$e107 = e107::getInstance();
$xml = e107::getXml();
$mes = e107::getMessage();
- $mes->addWarning("Experimental: Release plugin must be installed and contain data in order to bug-test this mechanism");
- // $file = "http://www.e107.org/releases.php"; //pluginfeed.php or similar.
-
- $file = SITEURLBASE.e_PLUGIN_ABS."release/release.php"; // temporary testing
+ $mes->addWarning("This area is experimental and may produce unpredictable results.");
+ $from = intval($_GET['frm']);
+
+ // $file = SITEURLBASE.e_PLUGIN_ABS."release/release.php"; // temporary testing
+ $file = "http://e107.org/feed?frm=".$from;
$xml->setOptArrayTags('plugin'); // make sure 'plugin' tag always returns an array
$xdata = $xml->loadXMLfile($file,'advanced');
+ $total = $xdata['@attributes']['total'];
+
//TODO use admin_ui including filter capabilities by sending search queries back to the xml script.
// XML data array.
+ $c = 1;
foreach($xdata['plugin'] as $r)
{
$row = $r['@attributes'];
$data[] = array(
- 'plugin_icon' => $row['icon'],
+ 'plugin_id' => $c,
+ 'plugin_icon' => vartrue($row['icon'],e_IMAGE."admin_images/plugins_32.png"),
'plugin_name' => $row['name'],
'plugin_folder' => $row['folder'],
- 'plugin_version' => $row['version'],
- 'plugin_description' => vartrue($row['description']),
- 'plugin_category' => vartrue($row['category']),
+ 'plugin_date' => vartrue($row['date']),
+ 'plugin_category' => vartrue($r['category'][0]),
'plugin_author' => vartrue($row['author']),
+ 'plugin_version' => $row['version'],
+ 'plugin_description' => $tp->text_truncate(vartrue($r['description'][0]),200),
+
+
'plugin_website' => vartrue($row['authorUrl']),
'plugin_url' => $row['url'],
'plugin_notes' => ''
);
+ $c++;
}
-
+// print_a($data);
+ $fieldList = $this->fields;
+ unset($fieldList['plugin_checkboxes']);
$text = "