+
+ trigger('onInstallerViewBeforeFirstTab', array()); ?>
+
+
+ trigger('onInstallerViewAfterLastTab', array()); ?>
+
diff --git a/administrator/components/com_installer/views/install/view.html.php b/administrator/components/com_installer/views/install/view.html.php
index ddd58a8802295..6b12116a9434b 100644
--- a/administrator/components/com_installer/views/install/view.html.php
+++ b/administrator/components/com_installer/views/install/view.html.php
@@ -30,6 +30,12 @@ function display($tpl=null)
$this->assignRef('paths', $paths);
$this->assignRef('state', $state);
+ $this->showJedAndWebInstaller = JComponentHelper::getParams('com_installer')->get('show_jed_info', 1);
+
+ JPluginHelper::importPlugin('installer');
+
+ JDispatcher::getInstance()->trigger('onInstallerBeforeDisplay', array(&$this->showJedAndWebInstaller, $this));
+
parent::display($tpl);
}
diff --git a/administrator/language/en-GB/en-GB.com_installer.ini b/administrator/language/en-GB/en-GB.com_installer.ini
index 9634beb375130..fe30d569f4bd0 100644
--- a/administrator/language/en-GB/en-GB.com_installer.ini
+++ b/administrator/language/en-GB/en-GB.com_installer.ini
@@ -123,6 +123,11 @@ COM_INSTALLER_NO_INSTALL_TYPE_FOUND="No Install Type Found"
COM_INSTALLER_PACKAGE_DOWNLOAD_FAILED="Package download failed: %s"
COM_INSTALLER_PACKAGE_FILE="Package File"
COM_INSTALLER_PURGED_UPDATES="Purged updates"
+COM_INSTALLER_SHOW_JED_INFORMATION_DESC="Show or hide the information at the top of the installer page about the Joomla! Extensions Directory."
+COM_INSTALLER_SHOW_JED_INFORMATION_HIDE_MESSAGE="Hide message"
+COM_INSTALLER_SHOW_JED_INFORMATION_LABEL="Joomla! Extensions Directory"
+COM_INSTALLER_SHOW_JED_INFORMATION_SHOW_MESSAGE="Show message"
+COM_INSTALLER_SHOW_JED_INFORMATION_TOOLTIP="Opens Installer Options for setting to hide this Joomla! Extensions Directory message."
COM_INSTALLER_SUBMENU_DATABASE="Database"
COM_INSTALLER_SUBMENU_DISCOVER="Discover"
COM_INSTALLER_SUBMENU_INSTALL="Install"
@@ -168,6 +173,14 @@ COM_INSTALLER_VALUE_FOLDER_NONAPPLICABLE="N/A"
COM_INSTALLER_VALUE_FOLDER_SELECT="- Select Folder -"
COM_INSTALLER_VALUE_STATE_SELECT="- Select Status -"
COM_INSTALLER_VALUE_TYPE_SELECT="- Select Type -"
+COM_INSTALLER_WEBINSTALLER_INSTALL_WEB_CONFIRM="Please confirm the installation by clicking on the Install button"
+COM_INSTALLER_WEBINSTALLER_INSTALL_WEB_CONFIRM_NAME="Extension Name"
+COM_INSTALLER_WEBINSTALLER_INSTALL_WEB_CONFIRM_URL="Install from"
+COM_INSTALLER_WEBINSTALLER_INSTALL_WEB_LOADING="Loading..."
+COM_INSTALLER_WEBINSTALLER_INSTALL_WEB_LOADING_ERROR="Cannot connect to the Joomla! server. Please try again later."
+COM_INSTALLER_WEBINSTALLER_LOAD_APPS="Click here to load extensions browser"
+COM_INSTALLER_WEBINSTALLER_INSTALL_OBSOLETE="The Install from Web plugin has become obsolete and needs to be updated."
+COM_INSTALLER_WEBINSTALLER_INSTALL_UPDATE_AVAILABLE="There is a new update available for the Install from Web plugin. It is advisable that you update as soon as possible."
COM_INSTALLER_XML_DESCRIPTION="Installer component for adding, removing and upgrading extensions"
JLIB_RULES_SETTING_NOTES="1. If you change the setting, it will apply to this component. Note that:
Inherited means that the permissions from global configuration and parent group will be used.
Denied means that no matter what the global configuration or parent group settings are, the group being edited cannot take this action on this component.
Allowed means that the group being edited will be able to take this action for this component (but if this is in conflict with the global configuration or parent group it will have no impact; a conflict will be indicated by
Not Allowed (Locked) under Calculated Settings).
2. If you select a new setting, click
Save to refresh the calculated settings."
COM_INSTALLER_PREFERENCES_LABEL="Preferences"
@@ -182,3 +195,8 @@ COM_INSTALLER_HEADER_LANGUAGES="Install Accredited Language Translations"
COM_INSTALLER_HEADING_DETAILS_URL="Details URL"
COM_INSTALLER_MSG_LANGUAGES_NOLANGUAGES="There are no available languages to install at the moment. Please click on the "Purge Cache" and "Find languages" buttons to check for updates on the Joomla Languages server. You will need an internet connection for this to work."
COM_INSTALLER_LANGUAGES_FILTER_SEARCH_DESC="Search by language name."
+COM_INSTALLER_INSTALL_FROM_WEB="Install from Web"
+COM_INSTALLER_INSTALL_FROM_WEB_INFORMATION="
Joomla! Extensions Directory now available with
Install from Web on this page:
"
+COM_INSTALLER_INSTALL_FROM_WEB_ADD_TAB="Add "Install from Web" option"
+COM_INSTALLER_INSTALL_FROM_WEB_INFO="
Joomla! Extensions Directory (JED) now available with
Install from Web on this page."
+COM_INSTALLER_INSTALL_FROM_WEB_TOS="By clicking "_QQ_"Add Install from Web option"_QQ_" below, you agree to the JED
Terms of Service and all applicable third party license terms."
diff --git a/administrator/language/en-GB/en-GB.plg_installer_webinstaller.ini b/administrator/language/en-GB/en-GB.plg_installer_webinstaller.ini
new file mode 100644
index 0000000000000..2022446c8f600
--- /dev/null
+++ b/administrator/language/en-GB/en-GB.plg_installer_webinstaller.ini
@@ -0,0 +1,11 @@
+; Joomla! Project
+; Copyright (C) 2005 - 2013 Open Source Matters. All rights reserved.
+; License GNU General Public License version 2 or later; see LICENSE.txt, see LICENSE.php
+; Note : All ini files need to be saved as UTF-8
+
+PLG_INSTALLER_WEBINSTALLER="Installer - Install from Web"
+PLG_INSTALLER_WEBINSTALLER_TAB_POSITION_DESC="Indicate whether to place the Install from Web tab first or last"
+PLG_INSTALLER_WEBINSTALLER_TAB_POSITION_LABEL="Tab Position"
+PLG_INSTALLER_WEBINSTALLER_TAB_POSITION_FIRST="First"
+PLG_INSTALLER_WEBINSTALLER_TAB_POSITION_LAST="Last"
+PLG_INSTALLER_WEBINSTALLER_XML_DESCRIPTION="This plugin offers functionality for the 'Install from Web' tab."
diff --git a/administrator/language/en-GB/en-GB.plg_installer_webinstaller.sys.ini b/administrator/language/en-GB/en-GB.plg_installer_webinstaller.sys.ini
new file mode 100644
index 0000000000000..7d9476fd80351
--- /dev/null
+++ b/administrator/language/en-GB/en-GB.plg_installer_webinstaller.sys.ini
@@ -0,0 +1,7 @@
+; Joomla! Project
+; Copyright (C) 2005 - 2013 Open Source Matters. All rights reserved.
+; License GNU General Public License version 2 or later; see LICENSE.txt, see LICENSE.php
+; Note : All ini files need to be saved as UTF-8
+
+PLG_INSTALLER_WEBINSTALLER="Installer - Install from Web"
+PLG_INSTALLER_WEBINSTALLER_XML_DESCRIPTION="This plugin offers functionality for the 'Install from Web' tab."
diff --git a/libraries/joomla/installer/helper.php b/libraries/joomla/installer/helper.php
index c1c11a493a8a2..7942f14202582 100644
--- a/libraries/joomla/installer/helper.php
+++ b/libraries/joomla/installer/helper.php
@@ -75,6 +75,7 @@ public static function downloadPackage($url, $target = false)
$response->body = $php_errormsg;
}
+ JLog::add(JText::sprintf('JLIB_INSTALLER_ERROR_DOWNLOAD_SERVER_CONNECT', $response->code), JLog::WARNING, 'jerror');
JError::raiseWarning(42, JText::sprintf('JLIB_INSTALLER_ERROR_DOWNLOAD_SERVER_CONNECT', $response->body));
return false;
@@ -113,13 +114,14 @@ public static function downloadPackage($url, $target = false)
* Unpacks a file and verifies it as a Joomla element package
* Supports .gz .tar .tar.gz and .zip
*
- * @param string $p_filename The uploaded package filename or install directory
+ * @param string $p_filename The uploaded package filename or install directory
+ * @param boolean $alwaysReturnArray If should return false (and leave garbage behind) or return $retval['type']=false
*
* @return array Two elements: extractdir and packagefile
*
* @since 11.1
*/
- public static function unpack($p_filename)
+ public static function unpack($p_filename, $alwaysReturnArray = false)
{
// Path to the archive
$archivename = $p_filename;
@@ -136,6 +138,13 @@ public static function unpack($p_filename)
if ($result === false)
{
+ if ($alwaysReturnArray)
+ {
+ $retval['extractdir'] = null;
+ $retval['packagefile'] = $archivename;
+ $retval['type'] = false;
+ return $retval;
+ }
return false;
}
@@ -173,7 +182,7 @@ public static function unpack($p_filename)
* Get the extension type and return the directory/type array on success or
* false on fail.
*/
- if ($retval['type'] = self::detectType($extractdir))
+ if (($retval['type'] = self::detectType($extractdir)) || $alwaysReturnArray)
{
return $retval;
}
@@ -262,7 +271,7 @@ public static function cleanupInstall($package, $resultdir)
$config = JFactory::getConfig();
// Does the unpacked extension directory exist?
- if (is_dir($resultdir))
+ if ($resultdir && is_dir($resultdir))
{
JFolder::delete($resultdir);
}
diff --git a/plugins/installer/index.html b/plugins/installer/index.html
new file mode 100644
index 0000000000000..2efb97f319a35
--- /dev/null
+++ b/plugins/installer/index.html
@@ -0,0 +1 @@
+