Skip to content
Snippets Groups Projects
Commit 76ca0bb9 authored by Reinhold Kainhofer's avatar Reinhold Kainhofer
Browse files

V3.99: Beta release (automatic version updates, library factorization)

parent 0cf35a08
No related branches found
No related tags found
No related merge requests found
......@@ -124,6 +124,10 @@ jQuery(document).ready (function () {
return "
div.credentials_checked {
padding: 10px 5px;
float: left;
clear: left;
display: block;
width: 100%;
}
div.credentials_checked_0 {
background-color: #FFD0D0;
......@@ -137,6 +141,11 @@ a#credentials_check {
";
}
protected function getInput() {
// Tell the user that automatic updates are not available in Joomla 2.5:
if (version_compare(JVERSION, '3.0', 'lt')) {
JFactory::getApplication()->enqueueMessage(JText::_('OPENTOOLS_COMMERCIAL_UPDATES_J25'), 'warning');
}
$this->loadjQuery();
$doc = JFactory::getDocument();
......
......@@ -91,3 +91,4 @@ OPENTOOLS_CHECK_CREDENTIALS="Zugangsdaten überprüfen und speichern"
OPENTOOLS_CHECK_CREDENTIALS_ERROR="Konnte Zugangsdaten nicht überprüfen. Bitte stellen Sie sicher, dass die Erweiterung in Joomla freigegeben ist!"
OPENTOOLS_XMLMANIFEST_ERROR="Konnte die XML-Manifest-Datei der Erweiterung nicht laden (%s)"
OPENTOOLS_UPDATESCRIPT_ERROR="Konnte die Aktualisierungsinformationen nicht laden (%s)"
OPENTOOLS_COMMERCIAL_UPDATES_J25="Automatische Aktualisierungen von kommerziellen Erweiterungen sind in Joomla 2.5 leider nicht möglich (erste ab Joomla 3.x). Bitte informieren Sie sich auf der Homepage des Entwicklers über mögliche Aktualisierungen und installieren Sie diese manuell."
......@@ -89,3 +89,5 @@ OPENTOOLS_CHECK_CREDENTIALS="Check and save update credentials"
OPENTOOLS_CHECK_CREDENTIALS_ERROR="Unable to check the download credentials. Please make sure that the plugin is enabled in your Joomla installation!"
OPENTOOLS_XMLMANIFEST_ERROR="Unable to load the plugin manifest file (%s)"
OPENTOOLS_UPDATESCRIPT_ERROR="Unable to load the update information from the update server (%s)"
OPENTOOLS_COMMERCIAL_UPDATES_J25="Automatic updates of commercial Joomla extensions are not available in Joomla 2.5 (only in Joomla 3.x). Please check the software developer's homepage and manually install updates."
......@@ -89,3 +89,5 @@ OPENTOOLS_CHECK_CREDENTIALS="Check and save update credentials"
OPENTOOLS_CHECK_CREDENTIALS_ERROR="Unable to check the download credentials. Please make sure that the plugin is enabled in your Joomla installation!"
OPENTOOLS_XMLMANIFEST_ERROR="Unable to load the plugin manifest file (%s)"
OPENTOOLS_UPDATESCRIPT_ERROR="Unable to load the update information from the update server (%s)"
OPENTOOLS_COMMERCIAL_UPDATES_J25="Automatic updates of commercial Joomla extensions are not available in Joomla 2.5 (only in Joomla 3.x). Please check the software developer's homepage and manually install updates."
......@@ -367,7 +367,7 @@ class OrdernumberHelper {
$format = $this->setupNumberFormatString($fmt, $type, $order, $reps);
$format = $this->doReplacements($format, $reps);
$ctrsettings = $this->extractCounterSettings ($format, $type, $ctrsettings);
JFactory::getApplication()->enqueueMessage("<pre>Counter Settings: ".print_r($ctrsettings,1)."</pre>", 'error');
// JFactory::getApplication()->enqueueMessage("<pre>Counter Settings: ".print_r($ctrsettings,1)."</pre>", 'error');
// JFactory::getApplication()->enqueueMessage("<pre>Replacements for $type:".print_r($reps,1)."</pre>", 'error');
// Increment the counter only if the format contains a placeholder for it!
if (strpos($ctrsettings["${type}_format"], "#") !== false) {
......
......@@ -348,7 +348,13 @@ class plgVmShopperOrdernumber extends vmShopperPlugin {
// append the order number and password and check whether access is
// possible.
$json['success'] = FALSE;
$xml = simplexml_load_file($this->_xmlFile);
if (isset($this->_xmlFile)) {
$xmlfile = $this->_xmlFile;
} else {
// VM 2 does not set the _xmlFile property, so construct it manually
$xmlfile = JPATH_SITE . '/plugins/' . $this->_type . '/' . $this->_name . '/' . $this->_name . '.xml';
}
$xml = simplexml_load_file($xmlfile);
if (!$xml || !isset($xml->updateservers)) {
JFactory::getApplication()->enqueueMessage(JText::sprintf('OPENTOOLS_XMLMANIFEST_ERROR', $this->_xmlFile), 'error');
return $json;
......@@ -461,6 +467,8 @@ class plgVmShopperOrdernumber extends vmShopperPlugin {
if ($orderpass!='') {
$extra_query[] = 'order_pass='.preg_replace("/[^-A-Za-z0-9_]/", '', $orderpass);
}
// Joomla 2.5 needs the filename to end in .zip:
$extra_query[] = 'filetype=.zip';
$extra_query = implode('&amp;', $extra_query);
// The following code is based on Nicholas K. Dionysopoulos' Joomla Pull request:
......
No preview for this file type
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment