diff --git a/administrator/components/com_joomlaupdate/tmpl/upload/default.php b/administrator/components/com_joomlaupdate/tmpl/upload/default.php
new file mode 100644
index 0000000000000..0890992250931
--- /dev/null
+++ b/administrator/components/com_joomlaupdate/tmpl/upload/default.php
@@ -0,0 +1,100 @@
+
+ * @license GNU General Public License version 2 or later; see LICENSE.txt
+ */
+
+defined('_JEXEC') or die;
+
+use Joomla\CMS\HTML\HTMLHelper;
+use Joomla\CMS\Language\Text;
+use Joomla\CMS\Updater\Update;
+use Joomla\CMS\Utility\Utility;
+use Joomla\Component\Joomlaupdate\Administrator\View\Joomlaupdate\HtmlView;
+
+/** @var HtmlView $this */
+
+/** @var WebAssetManager $wa */
+$wa = $this->document->getWebAssetManager();
+$wa->useScript('core')
+ ->useScript('com_joomlaupdate.default')
+ ->useScript('bootstrap.popover');
+
+HTMLHelper::_('behavior.core');
+Text::script('COM_INSTALLER_MSG_INSTALL_PLEASE_SELECT_A_PACKAGE', true);
+Text::script('COM_INSTALLER_MSG_WARNINGS_UPLOADFILETOOBIG', true);
+Text::script('JGLOBAL_SELECTED_UPLOAD_FILE_SIZE', true);
+
+$latestJoomlaVersion = $this->updateInfo['latest'];
+$currentJoomlaVersion = isset($this->updateInfo['current']) ? $this->updateInfo['current'] : JVERSION;
+?>
+
+
+
+
+
+ updateInfo['object']) && ($this->updateInfo['object'] instanceof Update)) : ?>
+
+
+ updateInfo['object']->downloadurl->_data); ?>
+
+
+
+warnings)) : ?>
+
+ warnings as $warning) : ?>
+
+
+
+
+
+
+
diff --git a/administrator/language/en-GB/com_installer.ini b/administrator/language/en-GB/com_installer.ini
index eef36f7e3612e..5f2708706a478 100644
--- a/administrator/language/en-GB/com_installer.ini
+++ b/administrator/language/en-GB/com_installer.ini
@@ -182,10 +182,10 @@ COM_INSTALLER_MSG_WARNINGS_JOOMLATMPNOTSET="The Joomla temporary folder is not s
COM_INSTALLER_MSG_WARNINGS_JOOMLATMPNOTSETDESC="This folder is where Joomla copies an extension, extracts the extension and the files are then copied into the correct directories. If this location is not set in configuration.php ($tmp_path) then you won't be able to upload extensions. Create a folder to enable Joomla to write to the folder to fix the issue."
COM_INSTALLER_MSG_WARNINGS_JOOMLATMPNOTWRITEABLE="The Joomla temporary folder is not writable or does not exist."
COM_INSTALLER_MSG_WARNINGS_JOOMLATMPNOTWRITEABLEDESC="This may cause issues when trying to upload extensions to Joomla. If you are having issues uploading extensions, make sure the folder defined in your configuration.php exists or check the '%s' and set it to be writeable and see if this fixes the issue."
-COM_INSTALLER_MSG_WARNINGS_LOWMEMORYDESC="Low PHP memory limit."
-COM_INSTALLER_MSG_WARNINGS_LOWMEMORYWARN="Your PHP memory limit is set below 8MB which may cause some issues when installing large extensions. Please set your memory limit to at least 16MB."
-COM_INSTALLER_MSG_WARNINGS_MEDMEMORYDESC="Potentially low PHP memory limit."
-COM_INSTALLER_MSG_WARNINGS_MEDMEMORYWARN="Your PHP memory limit is set below 16MB which may cause some issues when installing large extensions. Please set your memory limit to at least 16MB."
+COM_INSTALLER_MSG_WARNINGS_LOWMEMORYDESC="Your PHP memory limit is set below 16MB which may cause some issues when installing large extensions. Please set your memory limit to at least 32MB."
+COM_INSTALLER_MSG_WARNINGS_LOWMEMORYWARN="Low PHP memory limit."
+COM_INSTALLER_MSG_WARNINGS_MEDMEMORYDESC="Your PHP memory limit is set below 24MB which may cause some issues when installing large extensions. Please set your memory limit to at least 32MB."
+COM_INSTALLER_MSG_WARNINGS_MEDMEMORYWARN="Potentially low PHP memory limit."
COM_INSTALLER_MSG_WARNINGS_NONE="No warnings detected."
COM_INSTALLER_MSG_WARNINGS_NOTCOMPLETE="
Warning: Update Not Complete!
The update is only partially complete. Please do the second update to complete the process.
"
COM_INSTALLER_MSG_WARNINGS_PHPUPLOADNOTSET="The PHP temporary folder is not set."
diff --git a/administrator/language/en-GB/com_joomlaupdate.ini b/administrator/language/en-GB/com_joomlaupdate.ini
index ac4620cb47182..eb46c9b94849e 100644
--- a/administrator/language/en-GB/com_joomlaupdate.ini
+++ b/administrator/language/en-GB/com_joomlaupdate.ini
@@ -3,6 +3,7 @@
; License GNU General Public License version 2 or later; see LICENSE.txt
; Note : All ini files need to be saved as UTF-8
+COM_JOOMLAUPDATE_CAPTIVE_HEADLINE="Confirm your credentials"
COM_JOOMLAUPDATE_CHECKED_UPDATES="Checked for updates."
COM_JOOMLAUPDATE_CONFIG_CUSTOMURL_LABEL="Custom URL"
COM_JOOMLAUPDATE_CONFIG_SOURCES_DESC="Configure where Joomla gets its update information from."
@@ -15,8 +16,11 @@ COM_JOOMLAUPDATE_CONFIG_UPDATESOURCE_NEXT="Joomla Next"
COM_JOOMLAUPDATE_CONFIG_UPDATESOURCE_TESTING="Testing"
COM_JOOMLAUPDATE_CONFIGURATION="Joomla Update: Options"
COM_JOOMLAUPDATE_CONFIRM="Confirm"
+COM_JOOMLAUPDATE_EMPTYSTATE_APPEND="Update your site by manually uploading the update package."
+COM_JOOMLAUPDATE_EMPTYSTATE_BUTTON_ADD="Check for Updates"
+COM_JOOMLAUPDATE_EMPTYSTATE_CONTENT="Select the button below to check for updates."
+COM_JOOMLAUPDATE_EMPTYSTATE_TITLE="Check if an update is available."
COM_JOOMLAUPDATE_FAILED_TO_CHECK_UPDATES="Failed to check for updates."
-COM_JOOMLAUPDATE_LOGIN="Login"
COM_JOOMLAUPDATE_MINIMUM_STABILITY_ALPHA="Alpha"
COM_JOOMLAUPDATE_MINIMUM_STABILITY_BETA="Beta"
COM_JOOMLAUPDATE_MINIMUM_STABILITY_DESC="The minimum stability of the Joomla updates you would like to see. Development is the least stable, Stable is production quality. If an update doesn't specify a level it is assumed to be Stable."
@@ -24,17 +28,33 @@ COM_JOOMLAUPDATE_MINIMUM_STABILITY_DEV="Development"
COM_JOOMLAUPDATE_MINIMUM_STABILITY_LABEL="Minimum Stability"
COM_JOOMLAUPDATE_MINIMUM_STABILITY_RC="Release Candidate"
COM_JOOMLAUPDATE_MINIMUM_STABILITY_STABLE="Stable"
+COM_JOOMLAUPDATE_NODOWNLOAD_EMPTYSTATE_APPEND="Update your site by manually uploading the update package."
+COM_JOOMLAUPDATE_NODOWNLOAD_EMPTYSTATE_BUTTON_ADD="Retry check for update"
+COM_JOOMLAUPDATE_NODOWNLOAD_EMPTYSTATE_CONTENT="An update to Joomla %1$s was found, but it wasn't possible to fetch the download URL for that update. Either the update to Joomla %1$s is not available for your stability level or there is a problem with the Joomla Update Server.
Please try to download the update package from
the official Joomla download page and use the Upload and Update function."
+COM_JOOMLAUPDATE_NODOWNLOAD_EMPTYSTATE_TITLE="We can't find a download URL"
COM_JOOMLAUPDATE_OVERVIEW="Joomla Update"
COM_JOOMLAUPDATE_PREUPDATE_CHECK_CAPTION="Table of server settings to check before update."
-COM_JOOMLAUPDATE_PREUPDATE_CHECK_COMPLETED_YOU_HAVE_DANGEROUS_PLUGINS="There are plugins installed and enabled that could interfere with the Joomla upgrade and result in a failed upgrade that leaves the site inaccessible.
You are strongly advised to upgrade, disable or uninstall these plugins before upgrading."
+COM_JOOMLAUPDATE_PREUPDATE_CHECK_COMPLETED_YOU_HAVE_DANGEROUS_PLUGINS="There are plugins installed and enabled that could interfere with the Joomla update and result in a failed update that leaves the site inaccessible.
You are strongly advised to update, disable or uninstall these plugins before upgrading."
COM_JOOMLAUPDATE_PREUPDATE_CHECK_EXTENSION_AUTHOR_URL="Extension Author URL"
COM_JOOMLAUPDATE_PREUPDATE_CHECK_NOT_COMPLETE="Pre-Update checks have not been completed yet - please wait."
+COM_JOOMLAUPDATE_PREUPDATE_EXTENSIONS="Extensions"
COM_JOOMLAUPDATE_PREUPDATE_HEADING_CHECKED="Checked"
COM_JOOMLAUPDATE_PREUPDATE_HEADING_REQUIREMENT="Requirement"
+COM_JOOMLAUPDATE_PREUPDATE_REQUIRED_SETTINGS="Required Settings"
+COM_JOOMLAUPDATE_PREUPDATE_RECOMMENDED_SETTINGS="Recommended Settings"
COM_JOOMLAUPDATE_PREUPDATE_UNKNOWN_EXTENSION_MANIFESTCACHE_VERSION="Unknown Version"
+COM_JOOMLAUPDATE_REINSTALL_EMPTYSTATE_BUTTON_ADD="Reinstall Joomla! core files"
+COM_JOOMLAUPDATE_REINSTALL_EMPTYSTATE_CONTENT="You can reinstall all core files to repair broken or missing files."
+COM_JOOMLAUPDATE_REINSTALL_EMPTYSTATE_TITLE="Currently no update available."
+COM_JOOMLAUPDATE_SELF_EMPTYSTATE_BUTTON_ADD="Update component now"
+COM_JOOMLAUPDATE_SELF_EMPTYSTATE_CONTENT="A new version of the Joomla Update Component is available. You must update this first before you can update Joomla!"
+COM_JOOMLAUPDATE_SELF_EMPTYSTATE_TITLE="Live Update is not available"
COM_JOOMLAUPDATE_SYSTEM_CHECK="System Check"
COM_JOOMLAUPDATE_TOOLBAR_CHECK="Check for Updates"
COM_JOOMLAUPDATE_UPDATE_CHECK="Update Check"
+COM_JOOMLAUPDATE_UPDATE_CONFIRM_BACKUP="I've created a backup and my extensions are compatible."
+COM_JOOMLAUPDATE_UPDATE_EMPTYSTATE_TITLE="Update your site to \"Joomla! %s\""
+COM_JOOMLAUPDATE_UPDATE_EMPTYSTATE_BUTTON_ADD="Start update"
COM_JOOMLAUPDATE_UPDATE_LOG_CLEANUP="Cleaning up after installation."
COM_JOOMLAUPDATE_UPDATE_LOG_COMPLETE="Update to version %s is complete."
COM_JOOMLAUPDATE_UPDATE_LOG_DELETE_FILES="Deleting removed files and folders."
@@ -59,7 +79,7 @@ COM_JOOMLAUPDATE_VIEW_DEFAULT_DIRECTIVE="Directive"
COM_JOOMLAUPDATE_VIEW_DEFAULT_DOWNLOAD_IN_PROGRESS="Downloading update file. Please wait ..."
COM_JOOMLAUPDATE_VIEW_DEFAULT_EXPLANATION_AND_LINK_TO_DOCS="The pre-update check provides you with information about the readiness of your server, settings and installed extensions for the update.
You can find more information about this page and how to prepare for updating Joomla in the
pre-update check documentation."
COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSION_COMPATIBLE="Compatible"
-COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSION_COMPATIBLE_WITH_JOOMLA_VERSION="Joomla %s Compatible Version"
+COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSION_COMPATIBLE_WITH_JOOMLA_VERSION="%s Compatible"
COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSION_INSTALLED_VERSION="Installed Version"
COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSION_NAME="Extension Name"
COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSION_NO_COMPATIBILITY_INFORMATION="No Compatibility Information"
@@ -73,13 +93,13 @@ COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSIONS_NONE="No extensions installed."
COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSIONS_PRE_UPDATE_CHECKS_FAILED="Pre-Update Checks Failed"
COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSIONS_PRE_UPDATE_CHECKS_FAILED_NOTES="It was not possible to check the compatibility of these plugins. The request to the update server either timed out or returned an error."
COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSIONS_PROBABLY_COMPATIBLE="No Update Required"
-COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSIONS_PROBABLY_COMPATIBLE_NOTES="
The extension developer states that the currently installed version is compatible.
Please note that if you see a version highlighted as X.X.X then the extension developer is offering a newer version of the extension for your current version of Joomla than they do for the new version of Joomla. You should check with the extension developer if this is correct before you ugprade Joomla.
"
+COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSIONS_PROBABLY_COMPATIBLE_NOTES="
The extension developer states that the currently installed version is compatible.
Please note that if you see a version highlighted as X.X.X then the extension developer is offering a newer version of the extension for your current version of Joomla than they do for the new version of Joomla. You should check with the extension developer if this is correct before you update Joomla.
"
COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSIONS_REQUIRING_UPDATES_TO_BE_COMPATIBLE="Update Required"
-COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSIONS_REQUIRING_UPDATES_TO_BE_COMPATIBLE_NOTES="
Please update these extensions before updating Joomla.
Please take extra care if this updated version of the extension is not also listed as compatible with your current version of Joomla.
"
+COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSIONS_REQUIRING_UPDATES_TO_BE_COMPATIBLE_NOTES="
Please update these extensions before updating Joomla.
Please be especially careful if the extension is also listed as incompatible with the current version of Joomla!
"
COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSIONS_RUNNING_PRE_UPDATE_CHECKS="Running Pre-Update Checks"
-COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSIONS_RUNNING_PRE_UPDATE_CHECKS_NOTES="Please be patient whilst we run the pre-update checks on your extensions."
-COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSIONS_SHOW_LESS_COMPATIBILITY_INFORMATION="[ Less Detail %s ]"
-COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSIONS_SHOW_MORE_COMPATIBILITY_INFORMATION="[ More Detail %s ]"
+COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSIONS_RUNNING_PRE_UPDATE_CHECKS_NOTES="
Please be patient whilst we run the pre-update checks on your extensions.
"
+COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSIONS_SHOW_LESS_COMPATIBILITY_INFORMATION="Less Details"
+COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSIONS_SHOW_MORE_COMPATIBILITY_INFORMATION="More Details"
COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSIONS_UPDATE_SERVER_OFFERS_NO_COMPATIBLE_VERSION="Update Information Unavailable"
COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSIONS_UPDATE_SERVER_OFFERS_NO_COMPATIBLE_VERSION_NOTES="Extension does not offer a compatible version for the selected target version of Joomla. This could mean the extension does not use the Joomla update system or the developer has not provided compatibility information for this Joomla version yet."
COM_JOOMLAUPDATE_VIEW_DEFAULT_HELP="More Information."
@@ -87,24 +107,25 @@ COM_JOOMLAUPDATE_VIEW_DEFAULT_INFOURL="Additional Information"
COM_JOOMLAUPDATE_VIEW_DEFAULT_INSTALL_SELF_UPDATE_FIRST="You must update to the latest version of the Joomla Update Component before you can update Joomla!"
COM_JOOMLAUPDATE_VIEW_DEFAULT_INSTALLAGAIN="Reinstall Joomla core files"
COM_JOOMLAUPDATE_VIEW_DEFAULT_INSTALLED="Installed Joomla version"
-COM_JOOMLAUPDATE_VIEW_DEFAULT_INSTALLUPDATE="Install the Update"
+COM_JOOMLAUPDATE_VIEW_DEFAULT_INSTALLUPDATE="Update"
COM_JOOMLAUPDATE_VIEW_DEFAULT_LATEST="Latest Joomla version"
COM_JOOMLAUPDATE_VIEW_DEFAULT_NO_DOWNLOAD_URL="We can't find a download URL"
COM_JOOMLAUPDATE_VIEW_DEFAULT_NO_DOWNLOAD_URL_DESC="An update to Joomla %1$s was found, but it wasn't possible to fetch the download URL for that update. Either the update to Joomla %1$s is not available for your stability level or there is a problem with the Joomla Update Server.
Please try to download the update package from
the official Joomla download page and use the Upload and Update tab."
COM_JOOMLAUPDATE_VIEW_DEFAULT_NO_LIVE_UPDATE="Live Update is not available"
COM_JOOMLAUPDATE_VIEW_DEFAULT_NO_LIVE_UPDATE_DESC="There is a new version of the Joomla Update Component that needs to be installed first.
Click here to update the component."
-COM_JOOMLAUPDATE_VIEW_DEFAULT_NON_CORE_PLUGIN_BEING_CHECKED="The system is currently checking these plugins to see if they could cause problems during the upgrade.
Please be patient while the checks are completed."
-COM_JOOMLAUPDATE_VIEW_DEFAULT_NON_CORE_PLUGIN_CONFIRMATION="Do you wish to ignore the warnings about potentially incompatible plugins and to proceed with the upgrade?"
+COM_JOOMLAUPDATE_VIEW_DEFAULT_NON_CORE_PLUGIN_BEING_CHECKED="The system is currently checking these plugins to see if they could cause problems during the update.
Please be patient while the checks are completed."
+COM_JOOMLAUPDATE_VIEW_DEFAULT_NON_CORE_PLUGIN_CONFIRMATION="I accept the warnings about potentially incompatible extensions and wish to proceed with the update."
COM_JOOMLAUPDATE_VIEW_DEFAULT_NOUPDATES="No updates available"
COM_JOOMLAUPDATE_VIEW_DEFAULT_NOUPDATESNOTICE="You already have the latest Joomla version, %s."
COM_JOOMLAUPDATE_VIEW_DEFAULT_PACKAGE="Update package URL"
+COM_JOOMLAUPDATE_VIEW_DEFAULT_PACKAGE_INFO="You can also download
the update package and install it manually."
COM_JOOMLAUPDATE_VIEW_DEFAULT_PACKAGE_REINSTALL="Reinstall package URL"
COM_JOOMLAUPDATE_VIEW_DEFAULT_PHP_VERSION_NOT_SUPPORTED="Your PHP version is not supported"
COM_JOOMLAUPDATE_VIEW_DEFAULT_PHP_VERSION_NOT_SUPPORTED_DESC="An update to Joomla %1$s was found, but your currently installed PHP version does not match
the minimum requirements for Joomla %1$s."
-COM_JOOMLAUPDATE_VIEW_DEFAULT_POTENTIALLY_DANGEROUS_PLUGIN="Potentially Serious Problem."
-COM_JOOMLAUPDATE_VIEW_DEFAULT_POTENTIALLY_DANGEROUS_PLUGIN_CONFIRM_MESSAGE="Are you sure you want to ignore the warnings about potentially incompatible plugins and proceed with the upgrade?"
-COM_JOOMLAUPDATE_VIEW_DEFAULT_POTENTIALLY_DANGEROUS_PLUGIN_DESC="This extension includes a plugin that could cause the upgrade to fail.
To perform the Joomla upgrade safely you should either upgrade this extension to a version compatible with your target version of Joomla or disable the relevant plugin(s) and check again.
For more information about the relevant plugins please check the 'Live Update' tab."
-COM_JOOMLAUPDATE_VIEW_DEFAULT_POTENTIALLY_DANGEROUS_PLUGIN_LIST="The following plugins could cause problems during the upgrade"
+COM_JOOMLAUPDATE_VIEW_DEFAULT_POTENTIALLY_DANGEROUS_PLUGIN="Potential Problem."
+COM_JOOMLAUPDATE_VIEW_DEFAULT_POTENTIALLY_DANGEROUS_PLUGIN_CONFIRM_MESSAGE="Are you sure you want to ignore the warnings about potentially incompatible extensions and proceed with the update?"
+COM_JOOMLAUPDATE_VIEW_DEFAULT_POTENTIALLY_DANGEROUS_PLUGIN_DESC="This extension includes a plugin that could cause the update to fail.
To perform the Joomla update safely you should either update this extension to a version compatible with your target version of Joomla or disable the relevant plugin(s) and check again.
For more information about the relevant plugins please check the 'Live Update' tab."
+COM_JOOMLAUPDATE_VIEW_DEFAULT_POTENTIALLY_DANGEROUS_PLUGIN_LIST="The following plugins could cause problems during the update"
COM_JOOMLAUPDATE_VIEW_DEFAULT_PREUPDATE_CHECK="Pre-Update Check for Joomla %s"
COM_JOOMLAUPDATE_VIEW_DEFAULT_RECOMMENDED="Recommended"
COM_JOOMLAUPDATE_VIEW_DEFAULT_RECOMMENDED_SETTINGS_DESC="These settings are recommended for PHP in order to ensure full compatibility with Joomla. However, Joomla! will still operate if your settings do not quite match the recommended configuration."
@@ -121,7 +142,7 @@ COM_JOOMLAUPDATE_VIEW_DEFAULT_UPDATES_INFO_CUSTOM="You are on the "%s"
COM_JOOMLAUPDATE_VIEW_DEFAULT_UPDATES_INFO_DEFAULT="You are on the "%s" update channel. Through this channel you'll receive notifications for all updates of the current Joomla release (4.x)"
COM_JOOMLAUPDATE_VIEW_DEFAULT_UPDATES_INFO_NEXT="You are on the "%s" update channel. Through this channel you'll receive notifications for all updates of the current Joomla release (4.x) and you will also be notified when the future major release (5.x) will be available. Before upgrading to 5.x you'll need to assess its compatibility with your environment."
COM_JOOMLAUPDATE_VIEW_DEFAULT_UPDATES_INFO_TESTING="You are on the "%s" update channel. This channel is designed for testing new releases and fixes in Joomla.
It is only intended for JBS (Joomla Bug Squad™) members and others within the Joomla community who are testing. Do not use this setting on a production site."
-COM_JOOMLAUPDATE_VIEW_DEFAULT_UPLOAD_INTRO="You can use this feature to update Joomla if your server is behind a firewall or otherwise unable to contact the update servers. First download the Joomla
Upgrade Package in ZIP format from
the official Joomla download page. Then use the fields below to upload and install it."
+COM_JOOMLAUPDATE_VIEW_DEFAULT_UPLOAD_INTRO="You can use this feature to update Joomla if your server is behind a firewall or otherwise unable to contact the update servers. First download the Joomla
Update Package in ZIP format from
the official Joomla download page. Then use the fields below to upload and install it."
COM_JOOMLAUPDATE_VIEW_UPDATE_BYTESEXTRACTED="Bytes extracted"
COM_JOOMLAUPDATE_VIEW_UPDATE_BYTESREAD="Bytes read"
COM_JOOMLAUPDATE_VIEW_UPDATE_CHECKSUM_WRONG="File Checksum Failed"
diff --git a/build/media_source/com_joomlaupdate/js/default.es6.js b/build/media_source/com_joomlaupdate/js/default.es6.js
index 6c6a75a6abafe..06c4f2ad97320 100644
--- a/build/media_source/com_joomlaupdate/js/default.es6.js
+++ b/build/media_source/com_joomlaupdate/js/default.es6.js
@@ -16,7 +16,7 @@ Joomla = window.Joomla || {};
alert(Joomla.Text._('COM_INSTALLER_MSG_INSTALL_PLEASE_SELECT_A_PACKAGE'), true);
} else if (form.install_package.files[0].size > form.max_upload_size.value) {
alert(Joomla.Text._('COM_INSTALLER_MSG_WARNINGS_UPLOADFILETOOBIG'), true);
- } else {
+ } else if (document.getElementById('joomlaupdate-confirm-backup').checked) {
form.submit();
}
};
@@ -45,13 +45,26 @@ Joomla = window.Joomla || {};
document.addEventListener('DOMContentLoaded', () => {
const uploadButton = document.getElementById('uploadButton');
- const downloadMsg = document.getElementById('downloadMessage');
-
+ const uploadField = document.getElementById('install_package');
+ const installButton = document.querySelector('.emptystate-btnadd', document.getElementById('joomlaupdate-wrapper'));
+ const updateCheck = document.getElementById('joomlaupdate-confirm-backup');
+ const form = installButton ? installButton.closest('form') : null;
+ const task = form ? form.querySelector('[name=task]', form) : null;
if (uploadButton) {
- uploadButton.addEventListener('click', () => {
- if (downloadMsg) {
- downloadMsg.classList.remove('hidden');
+ uploadButton.addEventListener('click', Joomla.submitbuttonUpload);
+ }
+ if (uploadField) {
+ uploadField.addEventListener('change', Joomla.installpackageChange);
+ }
+ // Trigger (re-) install (including checkbox confirm if we update)
+ if (installButton && installButton.getAttribute('href') === '#' && task) {
+ installButton.addEventListener('click', (e) => {
+ e.preventDefault();
+ if (updateCheck && !updateCheck.checked) {
+ return;
}
+ task.value = 'update.download';
+ form.submit();
});
}
});
@@ -91,82 +104,87 @@ Joomla = window.Joomla || {};
SERVER_ERROR: 3,
};
+ PreUpdateChecker.cleanup = (status) => {
+ // Set the icon in the nav-tab
+ const infoIcon = document.querySelector('#joomlaupdate-precheck-extensions-tab .fa-spinner');
+
+ let iconColor = 'success';
+ let iconClass = 'check';
+
+ switch (status) {
+ case 'danger':
+ iconColor = 'danger';
+ iconClass = 'times';
+ break;
+ case 'warning':
+ iconColor = 'warning';
+ iconClass = 'exclamation-triangle';
+ break;
+ default:
+ }
+ if (infoIcon) {
+ infoIcon.classList.remove('fa-spinner', 'fa-spin', 'text-info');
+ infoIcon.classList.add(`fa-${iconClass}`, `text-${iconColor}`);
+ }
+ // Hide table of addons to load
+ const checkedExtensions = document.querySelector('#compatibilityTable0');
+ const preupdateCheckWarning = document.querySelector('#preupdateCheckWarning');
+ if (checkedExtensions) {
+ checkedExtensions.classList.add('hidden');
+ }
+ if (preupdateCheckWarning) {
+ preupdateCheckWarning.classList.add('hidden');
+ }
+ };
+
/**
* Run the PreUpdateChecker.
* Called by document ready, setup below.
*/
PreUpdateChecker.run = () => {
- [].slice.call(document.querySelectorAll('.settingstoggle')).forEach((el) => {
- el.style.float = 'right';
- el.style.cursor = 'pointer';
- el.addEventListener('click', () => {
- const settingsfieldset = el.closest('fieldset');
- if (el.dataset.state === 'closed') {
- el.dataset.state = 'open';
- el.innerHTML = Joomla.sanitizeHtml(Joomla.getOptions('COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSIONS_SHOW_LESS_COMPATIBILITY_INFORMATION'));
- settingsfieldset.querySelectorAll('.settingsInfo').forEach((fieldset) => {
- fieldset.classList.remove('hidden');
- });
- } else {
- el.dataset.state = 'closed';
- el.innerHTML = Joomla.sanitizeHtml(Joomla.getOptions('COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSIONS_SHOW_MORE_COMPATIBILITY_INFORMATION'));
- settingsfieldset.querySelectorAll('.settingsInfo').forEach((fieldset) => {
- fieldset.classList.add('hidden');
- });
- }
- });
- });
-
// eslint-disable-next-line no-undef
PreUpdateChecker.nonCoreCriticalPlugins = Joomla.getOptions('nonCoreCriticalPlugins', []);
- // If there are no non Core Critical Plugins installed, and we are in the update view, then
- // disable the warnings upfront
- if (PreUpdateChecker.nonCoreCriticalPlugins.length === 0 && document.getElementById('updateView') !== null) {
- document.getElementById('preupdateCheckWarning').style.display = 'none';
- document.getElementById('preupdateconfirmation').style.display = 'none';
- document.getElementById('preupdatecheckbox').style.display = 'none';
- document.getElementById('preupdatecheckheadings').style.display = 'none';
- document.getElementById('preupdatecheckbox').checked = true;
- document.getElementById('noncoreplugins').checked = true;
-
- [].slice.call(document.querySelectorAll('button.submitupdate')).forEach((el) => {
- el.classList.remove('disabled');
- el.removeAttribute('disabled');
- });
- }
-
// Grab all extensions based on the selector set in the config object
const extensions = document.querySelectorAll(PreUpdateChecker.config.selector);
// If there are no extensions to be checked we can exit here
if (extensions.length === 0) {
+ if (document.getElementById('preupdatecheckbox') !== null) {
+ document.getElementById('preupdatecheckbox').style.display = 'none';
+ }
+ if (document.getElementById('noncoreplugins') !== null) {
+ document.getElementById('noncoreplugins').checked = true;
+ }
+ [].slice.call(document.querySelectorAll('button.submitupdate')).forEach((el) => {
+ el.classList.remove('disabled');
+ el.removeAttribute('disabled');
+ });
+ PreUpdateChecker.cleanup();
return;
}
+ // Let the user make an update although there *could* be dangerous plugins in the wild
const onChangeEvent = () => {
- const preUpdateCheckbox = document.getElementById('preupdatecheckbox').checked;
- const nonCorePluginCheckbox = document.getElementById('noncoreplugins').checked;
- if (preUpdateCheckbox && nonCorePluginCheckbox) {
+ const nonCorePluginCheckbox = document.getElementById('noncoreplugins');
+ if (nonCorePluginCheckbox.checked) {
if (window.confirm(Joomla.Text._('COM_JOOMLAUPDATE_VIEW_DEFAULT_POTENTIALLY_DANGEROUS_PLUGIN_CONFIRM_MESSAGE'))) {
[].slice.call(document.querySelectorAll('button.submitupdate')).forEach((el) => {
el.classList.remove('disabled');
el.removeAttribute('disabled');
});
} else {
- document.getElementById('preupdatecheckbox').checked = true;
- document.getElementById('noncoreplugins').checked = true;
+ nonCorePluginCheckbox.checked = false;
}
} else {
[].slice.call(document.querySelectorAll('button.submitupdate')).forEach((el) => {
- el.classList.remove('disabled');
- el.removeAttribute('disabled');
+ el.classList.add('disabled');
+ el.setAttribute('disabled', '');
});
}
};
- if (document.getElementById('updateView') !== null) {
- document.getElementById('preupdatecheckbox').addEventListener('change', onChangeEvent);
+ if (document.getElementById('noncoreplugins') !== null) {
document.getElementById('noncoreplugins').addEventListener('change', onChangeEvent);
}
@@ -175,99 +193,24 @@ Joomla = window.Joomla || {};
PreUpdateChecker.joomlaTargetVersion = joomlaUpdateWrapper.getAttribute('data-joomla-target-version');
PreUpdateChecker.joomlaCurrentVersion = joomlaUpdateWrapper.getAttribute('data-joomla-current-version');
- // No point creating and loading a component stylesheet for 4 settings
- [].slice.call(document.querySelectorAll('.compatibilitytypes img')).forEach((el) => {
- el.style.height = '20px';
- });
- [].slice.call(document.querySelectorAll('.compatibilitytypes')).forEach((el) => {
- el.style.display = 'none';
- el.style.marginLeft = 0;
- });
- // The currently processing line should show until it’s finished
- const compatibilityType0 = document.getElementById('compatibilitytype0');
-
- if (compatibilityType0) {
- compatibilityType0.style.display = 'block';
- }
-
[].slice.call(document.querySelectorAll('.compatibilitytoggle')).forEach((el) => {
- el.style.float = 'right';
- el.style.cursor = 'pointer';
el.addEventListener('click', () => {
- const compatibilitytypes = el.closest('fieldset.compatibilitytypes');
+ const compatibilityTable = el.closest('.compatibilityTable');
if (el.dataset.state === 'closed') {
el.dataset.state = 'open';
- el.innerHTML = Joomla.sanitizeHtml(Joomla.getOptions('COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSIONS_SHOW_LESS_COMPATIBILITY_INFORMATION'));
+ el.innerHTML = Joomla.sanitizeHtml(Joomla.Text._('COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSIONS_SHOW_LESS_COMPATIBILITY_INFORMATION'));
- [].slice.call(compatibilitytypes.querySelectorAll('.exname')).forEach((extension) => {
- extension.classList.remove('col-md-8');
- extension.classList.add('col-md-4');
+ [].slice.call(compatibilityTable.querySelectorAll('table .hidden')).forEach((elem) => {
+ elem.classList.remove('hidden');
});
-
- [].slice.call(compatibilitytypes.querySelectorAll('.extype')).forEach((extension) => {
- extension.classList.remove('col-md-4');
- extension.classList.add('col-md-1');
- });
-
- [].slice.call(compatibilitytypes.querySelectorAll('.upcomp')).forEach((extension) => {
- extension.classList.remove('hidden');
- extension.classList.add('col-md-3');
- });
-
- [].slice.call(compatibilitytypes.querySelectorAll('.currcomp')).forEach((extension) => {
- extension.classList.remove('hidden');
- extension.classList.add('col-md-3');
- });
-
- [].slice.call(compatibilitytypes.querySelectorAll('.instver')).forEach((extension) => {
- extension.classList.remove('hidden');
- extension.classList.add('col-md-1');
- });
-
- if (PreUpdateChecker.showyellowwarning && compatibilitytypes.querySelector('#updateyellowwarning')) {
- compatibilitytypes.querySelector('#updateyellowwarning').classList.remove('hidden');
- }
-
- if (PreUpdateChecker.showorangewarning && compatibilitytypes.querySelector('#updateorangewarning')) {
- compatibilitytypes.querySelector('#updateorangewarning').classList.remove('hidden');
- }
} else {
el.dataset.state = 'closed';
- el.innerHTML = Joomla.sanitizeHtml(Joomla.getOptions('COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSIONS_SHOW_MORE_COMPATIBILITY_INFORMATION'));
-
- [].slice.call(compatibilitytypes.querySelectorAll('.exname')).forEach((extension) => {
- extension.classList.add('col-md-8');
- extension.classList.remove('col-md-4');
- });
+ el.innerHTML = Joomla.sanitizeHtml(Joomla.Text._('COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSIONS_SHOW_MORE_COMPATIBILITY_INFORMATION'));
- [].slice.call(compatibilitytypes.querySelectorAll('.extype')).forEach((extension) => {
- extension.classList.add('col-md-4');
- extension.classList.remove('col-md-1');
+ [].slice.call(compatibilityTable.querySelectorAll('table .instver, table .upcomp, table .currcomp')).forEach((elem) => {
+ elem.classList.add('hidden');
});
-
- [].slice.call(compatibilitytypes.querySelectorAll('.upcomp')).forEach((extension) => {
- extension.classList.add('hidden');
- extension.classList.remove('col-md-3');
- });
-
- [].slice.call(compatibilitytypes.querySelectorAll('.currcomp')).forEach((extension) => {
- extension.classList.add('hidden');
- extension.classList.remove('col-md-3');
- });
-
- [].slice.call(compatibilitytypes.querySelectorAll('.instver')).forEach((extension) => {
- extension.classList.add('hidden');
- extension.classList.remove('col-md-1');
- });
-
- if (PreUpdateChecker.showyellowwarning && compatibilitytypes.querySelector('#updateyellowwarning')) {
- compatibilitytypes.querySelector('#updateyellowwarning').classList.add('hidden');
- }
-
- if (PreUpdateChecker.showorangewarning && compatibilitytypes.querySelector('#updateorangewarning')) {
- compatibilitytypes.querySelector('#updateorangewarning').classList.add('hidden');
- }
}
});
});
@@ -314,6 +257,7 @@ Joomla = window.Joomla || {};
callback(extension);
},
onError() {
+ extension.serverError = 1;
// Pass the retrieved data to the callback
callback(extension);
},
@@ -344,24 +288,35 @@ Joomla = window.Joomla || {};
case PreUpdateChecker.STATE.COMPATIBLE:
if (extensionData.compatibilityData.upgradeWarning) {
// eslint-disable-next-line max-len
- html = `
${extensionData.compatibilityData.upgradeCompatibilityStatus.compatibleVersion}`;
- PreUpdateChecker.showyellowwarning = true;
+ const compatibleVersion = Joomla.sanitizeHtml(extensionData.compatibilityData.upgradeCompatibilityStatus.compatibleVersion);
+ html = `
${compatibleVersion}`;
+ // @TODO activate when language strings are correct
+ /* if (compatibilitytypes.querySelector('#updateorangewarning')) {
+ compatibilitytypes.querySelector('#updateorangewarning').classList.remove('hidden');
+ } */
} else {
// eslint-disable-next-line max-len
html = extensionData.compatibilityData.upgradeCompatibilityStatus.compatibleVersion === false
? Joomla.Text._('COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSION_NO_COMPATIBILITY_INFORMATION')
- : extensionData.compatibilityData.upgradeCompatibilityStatus.compatibleVersion;
+ // eslint-disable-next-line max-len
+ : Joomla.sanitizeHtml(extensionData.compatibilityData.upgradeCompatibilityStatus.compatibleVersion);
}
break;
case PreUpdateChecker.STATE.INCOMPATIBLE:
// No compatible version found -> display error label
html = Joomla.Text._('COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSION_NO_COMPATIBILITY_INFORMATION');
- PreUpdateChecker.showorangewarning = true;
+ // @TODO activate when language strings are correct
+ /* if (document.querySelector('#updateyellowwarning')) {
+ document.querySelector('#updateyellowwarning').classList.remove('hidden');
+ } */
break;
case PreUpdateChecker.STATE.MISSING_COMPATIBILITY_TAG:
// Could not check compatibility state -> display warning
html = Joomla.Text._('COM_JOOMLAUPDATE_VIEW_DEFAULT_EXTENSION_NO_COMPATIBILITY_INFORMATION');
- PreUpdateChecker.showorangewarning = true;
+ // @TODO activate when language strings are correct
+ /* if (document.querySelector('#updateyellowwarning')) {
+ document.querySelector('#updateyellowwarning').classList.remove('hidden');
+ } */
break;
default:
// An error occurred -> show unknown error note
@@ -370,7 +325,7 @@ Joomla = window.Joomla || {};
}
// Insert the generated html
- extensionData.element.innerHTML = Joomla.sanitizeHtml(html);
+ extensionData.element.innerHTML = html;
// Process Current Version Extension Compatibility
html = '';
@@ -403,36 +358,29 @@ Joomla = window.Joomla || {};
const extensionId = extensionData.element.getAttribute('data-extension-id');
document.getElementById(`available-version-${extensionId}`).innerText = html;
- const compatType = document.querySelector(`#compatibilitytype${extensionData.compatibilityData.resultGroup} tbody`);
+ const compatType = document.querySelector(`#compatibilityTable${extensionData.compatibilityData.resultGroup} tbody`);
if (compatType) {
compatType.appendChild(extensionData.element.closest('tr'));
}
- document.getElementById(`compatibilitytype${extensionData.compatibilityData.resultGroup}`).style.display = 'block';
- document.getElementById('compatibilitytype0').style.display = 'block';
+ // Show the table
+ document.getElementById(`compatibilityTable${extensionData.compatibilityData.resultGroup}`).classList.remove('hidden');
// Process the nonCoreCriticalPlugin list
if (extensionData.compatibilityData.resultGroup === 3) {
PreUpdateChecker.nonCoreCriticalPlugins.forEach((plugin, cpi) => {
if (plugin.package_id.toString() === extensionId
|| plugin.extension_id.toString() === extensionId) {
- document.getElementById(`#plg_${plugin.extension_id}`).remove();
PreUpdateChecker.nonCoreCriticalPlugins.splice(cpi, 1);
}
});
}
- // Have we finished running through the potentially critical plugins - if so we can hide the
- // warning before all the checks are completed
- const headingsElement = document.getElementById('preupdatecheckheadings');
- if (headingsElement && headingsElement.querySelectorAll('table td').length === 0) {
- headingsElement.style.display = 'none';
- }
-
// Have we finished?
- if (!document.querySelector('#compatibilitytype0 tbody td')) {
- document.getElementById('compatibilitytype0').style.display = 'none';
+ if (!document.querySelector('#compatibilityTable0 tbody td')) {
+ document.getElementById('compatibilityTable0').classList.add('hidden');
+ let status = 'success';
PreUpdateChecker.nonCoreCriticalPlugins.forEach((plugin) => {
let problemPluginRow = document.querySelector(`td[data-extension-id="${plugin.extension_id}"]`);
if (!problemPluginRow) {
@@ -441,61 +389,54 @@ Joomla = window.Joomla || {};
if (problemPluginRow) {
const tableRow = problemPluginRow.closest('tr');
tableRow.classList.add('error');
- const pluginTitleTableCell = tableRow.querySelector('td:first-child');
- pluginTitleTableCell.innerHTML = Joomla.sanitizeHtml(`${pluginTitleTableCell.innerHTML}
-
+ const pluginTitleTableCell = tableRow.querySelector('.exname');
+ pluginTitleTableCell.innerHTML = `${Joomla.sanitizeHtml(pluginTitleTableCell.innerHTML)}
+
+
${Joomla.Text._('COM_JOOMLAUPDATE_VIEW_DEFAULT_POTENTIALLY_DANGEROUS_PLUGIN')}
-
-
${Joomla.Text._('COM_JOOMLAUPDATE_VIEW_DEFAULT_HELP')}
- `);
+
+
`;
const popoverElement = pluginTitleTableCell.querySelector('.hasPopover');
if (popoverElement) {
popoverElement.style.cursor = 'pointer';
// eslint-disable-next-line no-new
- new bootstrap.Popover(popoverElement, { placement: 'top', html: true, trigger: 'focus click' });
+ new bootstrap.Popover(popoverElement, { placement: 'top', html: true, trigger: 'focus' });
}
+ status = 'danger';
}
});
-
- // If we aren't in the update view now - bail early.
- if (document.getElementById('updateView') === null) {
- return;
+ // Updates required
+ if (document.querySelector('#compatibilityTable2 tbody td')) {
+ status = 'danger';
+ } else if (status !== 'danger' && document.querySelector('#compatibilityTable1 tbody td')) {
+ status = 'warning';
}
- if (PreUpdateChecker.nonCoreCriticalPlugins.length === 0) {
- document.getElementById('preupdateCheckWarning').style.display = 'none';
- document.getElementById('preupdateconfirmation').style.display = 'none';
+ if (PreUpdateChecker.nonCoreCriticalPlugins.length === 0 && status === 'success') {
document.getElementById('preupdatecheckbox').style.display = 'none';
- document.getElementById('preupdatecheckheadings').style.display = 'none';
- document.getElementById('preupdatecheckbox').checked = true;
document.getElementById('noncoreplugins').checked = true;
[].slice.call(document.querySelectorAll('button.submitupdate')).forEach((el) => {
el.classList.remove('disabled');
el.removeAttribute('disabled');
});
- } else {
- document.getElementById('preupdateCheckWarning').classList.add('hidden');
+ } else if (PreUpdateChecker.nonCoreCriticalPlugins.length > 0) {
document.getElementById('preupdateCheckCompleteProblems').classList.remove('hidden');
-
- [].slice.call(document.querySelectorAll('#preupdateconfirmation .preupdateconfirmation_label h3')).forEach((el) => {
- el.innerText = Joomla.Text._('COM_JOOMLAUPDATE_VIEW_DEFAULT_POTENTIALLY_DANGEROUS_PLUGIN_LIST');
- });
-
- [].slice.call(document.querySelectorAll('#preupdateconfirmation .preupdateconfirmation_label')).forEach((el) => {
- el.classList.add('label-important');
- el.classList.remove('label-warning');
- });
}
+
+ PreUpdateChecker.cleanup(status);
}
};
- // Run PreUpdateChecker on document ready
- document.addEventListener('DOMContentLoaded', PreUpdateChecker.run, false);
+ if (document.getElementById('preupdatecheck') !== null) {
+ // Run PreUpdateChecker on document ready
+ document.addEventListener('DOMContentLoaded', PreUpdateChecker.run, false);
+ }
})(Joomla, document);
diff --git a/layouts/joomla/content/emptystate.php b/layouts/joomla/content/emptystate.php
index 06cb2eee6e22d..3fe64284cda07 100644
--- a/layouts/joomla/content/emptystate.php
+++ b/layouts/joomla/content/emptystate.php
@@ -45,7 +45,7 @@
input->get('tmpl') !== 'component') : ?>
+ class="btn btn-primary btn-lg px-4 me-sm-3 emptystate-btnadd">