Skip to content

Commit

Permalink
Merge branch 'release/4.0.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
svanschu committed Jan 20, 2023
2 parents 74c1b5a + 7442ef9 commit 380e6a5
Show file tree
Hide file tree
Showing 125 changed files with 1,458 additions and 1,364 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
\.idea/
/.docker/**/db/
/.docker/**/public/

plugins/schuweb_sitemap/dpcalendar
6 changes: 1 addition & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
# SchuWeb Sitemap
This project continuous the great, simple and lightweight sitemap extension for Joomla! Xmap.
SchuWeb Sitemap is the great, simple and lightweight sitemap extension for Joomla!.

[Project website](https://extensions.schultschik.com/products/schuweb-sitemap)

Many thanks to Vargas, the original creator of Xmap, who discontinued the development of the extension.

## Demo
A small demo you can see at: [demo.schultschik.com](http://demo.schultschik.com/schuweb-sitemap)

Expand All @@ -19,8 +17,6 @@ Big thank you to all who helped with this extension. Especially to those listed
- [sshcli](https://github.com/sshcli)
- [Jelle Kok](https://github.com/810)

Thank you to [Guillermo Vargas](https://github.com/guilleva) too, who originally developed the XMap component, which development is discontinued.

## Donation
Want to support the project?

Expand Down
9 changes: 5 additions & 4 deletions administrator/components/com_schuweb_sitemap/controller.php
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<?php
/**
* @version sw.build.version
* @copyright Copyright (C) 2007 - 2009 Joomla! Vargas. All rights reserved.
* @copyright Copyright (C) 2019 - 2022 Sven Schultschik. All rights reserved
* @license GNU General Public License version 2 or later; see LICENSE.txt
* @author Guillermo Vargas ([email protected])
* @author Sven Schultschik ([email protected])
*/
// no direct access
defined('_JEXEC') or die;
Expand Down Expand Up @@ -31,10 +31,11 @@ public function display($cachable = false, $urlparams = false)
{
require_once JPATH_COMPONENT . '/helpers/schuweb_sitemap.php';

$app = JFactory::getApplication();
// Get the document object.
$document = JFactory::getDocument();
$document = $app->getDocument();

$jinput = JFactory::$application->input;
$jinput = $app->input;

// Set the default view name and format from the Request.
$vName = $jinput->getWord('view', 'sitemaps');
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<?php
/**
* @version sw.build.version
* @copyright Copyright (C) 2007 - 2009 Joomla! Vargas. All rights reserved.
* @copyright Copyright (C) 2019 - 2022 Sven Schultschik. All rights reserved
* @license GNU General Public License version 2 or later; see LICENSE.txt
* @author Guillermo Vargas ([email protected])
* @author Sven Schultschik ([email protected])
*/

// No direct access
Expand Down Expand Up @@ -32,6 +32,6 @@ protected function _allowEdit($data = array(), $key = 'id')
$recordId = (int) isset($data[$key]) ? $data[$key] : 0;

// Assets are being tracked, so no need to look into the category.
return JFactory::getUser()->authorise('core.edit', 'com_schuweb_sitemap.sitemap.'.$recordId);
return JFactory::getApplication()->getIdentity()->authorise('core.edit', 'com_schuweb_sitemap.sitemap.'.$recordId);
}
}
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<?php
/**
* @version sw.build.version
* @copyright Copyright (C) 2007 - 2009 Joomla! Vargas. All rights reserved.
* @copyright Copyright (C) 2019 - 2022 Sven Schultschik. All rights reserved
* @license GNU General Public License version 2 or later; see LICENSE.txt
* @author Guillermo Vargas ([email protected])
* @author Sven Schultschik ([email protected])
*/

// no direct access
Expand Down Expand Up @@ -78,8 +78,6 @@ function setDefault()
*/
public function getModel($name = 'Sitemap', $prefix = 'SchuWeb_SitemapModel', $config = array('ignore_request' => true))
{
$model = parent::getModel($name, $prefix, $config);

return $model;
return parent::getModel($name, $prefix, $config);
}
}
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<?php
/**
* @version sw.build.version
* @copyright Copyright (C) 2007 - 2009 Joomla! Vargas. All rights reserved.
* @copyright Copyright (C) 2019 - 2022 Sven Schultschik. All rights reserved
* @license GNU General Public License version 2 or later; see LICENSE.txt
* @author Guillermo Vargas ([email protected])
* @author Sven Schultschik ([email protected])
*/

// no direct access
Expand All @@ -29,6 +29,7 @@ abstract class JHtmlSchuWeb_Sitemap
*/
public static function priorities($name, $value = '0.5', $j)
{
$options = array();
// Array of options
for ($i=0.1; $i<=1;$i+=0.1) {
$options[] = JHTML::_('select.option',$i,$i);;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<?php
/**
* @version sw.build.version
* @copyright Copyright (C) 2007 - 2009 Joomla! Vargas. All rights reserved.
* @copyright Copyright (C) 2019 - 2022 Sven Schultschik. All rights reserved
* @license GNU General Public License version 2 or later; see LICENSE.txt
* @author Guillermo Vargas ([email protected])
* @author Sven Schultschik ([email protected])
*/


Expand All @@ -24,7 +24,7 @@ class SchuWeb_SitemapHelper
*
* @return mixed
*
* @since __DEPLOY_VERSION__
* @since
*/
public static function getExtensionsList()
{
Expand All @@ -33,13 +33,11 @@ public static function getExtensionsList()

$query->select('e.*')
->from($db->quoteName('#__extensions') . 'AS e')
->join('INNER', '#__extensions AS p ON e.element=p.element and p.enabled=0 and p.type=\'plugin\' and p.folder=\'schuweb_sitemap\'')
->join('INNER', '#__extensions AS p ON SUBSTRING(e.element,5)=p.element and p.enabled=0 and p.type=\'plugin\' and p.folder=\'schuweb_sitemap\'')
->where('e.type=\'component\' and e.enabled=1');

$db->setQuery($query);
$extensions = $db->loadObjectList();

return $extensions;
return $db->loadObjectList();
}

}
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
; sw.build.version
; SchuWeb Sitemap component
; Guillermo Vargas ([email protected])
; Copyright (C) 2007 - 2009 Joomla! Vargas. All rights reserved.
; Sven Schultschik ([email protected])
; Copyright (C) 2019 - 2022 Sven Schultschik.. All rights reserved.
; GNU General Public License version 2 or later; see LICENSE.txt
;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
; sw.build.version
; Copyright (C) 2007 - 2009 Joomla! Vargas. All rights reserved.
; Copyright (C) 2019 - 2022 Sven Schultschik.. All rights reserved.
; GNU General Public License version 2 or later; see LICENSE.txt
; Guillermo Vargas ([email protected])
; Sven Schultschik ([email protected])
;

COM_SCHUWEB_SITEMAP_="SchuWeb Sitemap"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
; sw.build.version
; SchuWeb Sitemap component
; Sven Schultschik (https://extensions.schultschik.com)
; Guillermo Vargas ([email protected])
; Sven Schultschik ([email protected])
; Copyright (C) 2016 - 2017 Sven Schultschik. All rights reserved.
; Copyright (C) 2007 - 2009 Joomla! Vargas. All rights reserved.
; Copyright (C) 2019 - 2022 Sven Schultschik.. All rights reserved.
; GNU General Public License version 2 or later; see LICENSE.txt
;

Expand Down Expand Up @@ -52,6 +52,7 @@ SCHUWEB_SITEMAP_IMAGES_LINK="Images Sitemap"
SCHUWEB_SITEMAP_IMAGES_LINK_TOOLTIP="Go to the &ldquo;Images&rdquo; version of the sitemap, use this url to submit your sitemap to Google and other search engines."

SCHUWEB_SITEMAP_MESSAGE_EXTENSIONS_DISABLED="SchuWeb Sitemap have detected that the following extensions can help you to get more content in your site map but they are disabled, you have to manually enable them visiting the <a href='index.php?option=com_plugins&view=plugins&filter_folder=schuweb_sitemap'>extensions manager</a>: %s"
SCHUWEB_SITEMAP_MESSAGE_EXTENSIONS_NOT_INSTALLED="SchuWeb Sitemap have detected that the following plugins can help you to get more content in your site map but they are not installed, you have to manually install them. You can find and download them from <a href='https://extensions.schultschik.com/schuweb-sitemap' target="_blank">SchuWeb Extensions Website</a>: %s"
COM_SCHUWEB_SITEMAP_SITEMAPS_N_ITEMS_UNPUBLISHED="%d sitemaps successfully unpublished"
COM_SCHUWEB_SITEMAP_SITEMAPS_N_ITEMS_UNPUBLISHED_1="%d sitemap successfully unpublished"
COM_SCHUWEB_SITEMAP_SITEMAPS_N_ITEMS_PUBLISHED="%d sitemaps successfully published"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
; sw.build.version
; Copyright (C) 2007 - 2009 Joomla! Vargas. All rights reserved.
; Copyright (C) 2019 - 2022 Sven Schultschik.. All rights reserved.
; Copyright (C) 2019 - 2020 SchuWebExt Sven Schultschik. All rights reserved.
; GNU General Public License version 2 or later; see LICENSE.txt
;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
; sw.build.version
; SchuWeb Sitemap component
; Guillermo Vargas ([email protected])
; Copyright (C) 2007 - 2009 Joomla! Vargas. All rights reserved.
; Sven Schultschik ([email protected])
; Copyright (C) 2019 - 2022 Sven Schultschik.. All rights reserved.
; GNU General Public License version 2 or later; see LICENSE.txt
;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
; sw.build.version
; Copyright (C) 2007 - 2009 Joomla! Vargas. All rights reserved.
; Copyright (C) 2019 - 2022 Sven Schultschik.. All rights reserved.
; GNU General Public License version 2 or later; see LICENSE.txt
; Guillermo Vargas ([email protected])
; Sven Schultschik ([email protected])
;

COM_SCHUWEB_SITEMAP_="SchuWeb Sitemap"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
; sw.build.version
; SchuWeb Sitemap component
; Guillermo Vargas ([email protected])
; Copyright (C) 2007 - 2009 Joomla! Vargas. All rights reserved.
; Sven Schultschik ([email protected])
; Copyright (C) 2019 - 2022 Sven Schultschik.. All rights reserved.
; GNU General Public License version 2 or later; see LICENSE.txt
;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
; sw.build.version
; Copyright (C) 2007 - 2009 Joomla! Vargas. All rights reserved.
; Copyright (C) 2019 - 2022 Sven Schultschik.. All rights reserved.
; GNU General Public License version 2 or later; see LICENSE.txt
; Guillermo Vargas ([email protected])
; Sven Schultschik ([email protected])
;

COM_SCHUWEB_SITEMAP_="SchuWeb Sitemap"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
; sw.build.version
; SchuWeb Sitemap component
; Guillermo Vargas ([email protected])
; Copyright (C) 2007 - 2009 Joomla! Vargas. All rights reserved.
; Sven Schultschik ([email protected])
; Copyright (C) 2019 - 2022 Sven Schultschik.. All rights reserved.
; GNU General Public License version 2 or later; see LICENSE.txt
;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
; sw.build.version
; Copyright (C) 2007 - 2009 Joomla! Vargas. All rights reserved.
; Copyright (C) 2019 - 2022 Sven Schultschik.. All rights reserved.
; GNU General Public License version 2 or later; see LICENSE.txt
; Guillermo Vargas ([email protected])
; Sven Schultschik ([email protected])
;

COM_SCHUWEB_SITEMAP_="SchuWeb Sitemap"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php
/**
* @version sw.build.version
* @copyright Copyright (C) 2021 Sven Schultschik. All rights reserved.
* @copyright Copyright (C) 2019 - 2022 Sven Schultschik. All rights reserved
* @license GNU General Public License version 2 or later; see LICENSE.txt
* @author Sven Schultschik ([email protected])
*/
Expand Down Expand Up @@ -67,22 +67,14 @@ protected function getInput()

$link = JRoute::_('index.php?option=com_schuweb_sitemap&view=sitemaps&layout=modal&tmpl=component&function=jSelectSitemap_' . $this->id);

if (version_compare(JVERSION, '4', 'lt'))
{
$class = 'class="input-medium"';
$classSpan = 'input-append';
$bsModal = 'data-target="#sitemapTypeModal" data-toggle="modal"';
}
else
{
$class = 'class="form-control valid form-control-success"';
$classSpan = 'input-group';
$bsModal = 'data-bs-target="#sitemapTypeModal" data-bs-toggle="modal"';
}

$class = 'class="form-control valid form-control-success"';
$classSpan = 'input-group';
$bsModal = 'data-bs-target="#sitemapTypeModal" data-bs-toggle="modal"';

$html = array();
$html[] = '<span class="' . $classSpan . '">';
$html[] = '<input type="text" required="required" readonly="readonly" size="40" id="' . $this->id . '_name" ' . $class . ' value="' . htmlspecialchars($title, ENT_QUOTES, 'UTF-8') . '" />';
$html[] = '<input type="text" required="required" readonly="readonly" size="40" id="' . $this->id . '_name" ' . $class . ' value="' . htmlspecialchars($title, ENT_QUOTES) . '" />';
$html[] = '<button type="button" class="btn btn-primary" ' . $bsModal . ' title="' . JText::_('COM_SCHUWEB_SITEMAP_CHANGE_SITEMAP') . '">'
. '<span class="icon-list icon-white" aria-hidden="true"></span> '
. JText::_('JSELECT') . '</button>';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php
/**
* @version sw.build.version
* @copyright Copyright (C) 2019 SchuWeb Extensions Sven Schultschik, All rights reserved.
* @copyright Copyright (C) 2019 - 2022 Sven Schultschik. All rights reserved
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/

Expand Down Expand Up @@ -255,8 +255,7 @@ protected function _prepareTable(&$table)

function _orderConditions($table = null)
{
$condition = array();
return $condition;
return array();
}

function setDefault($id)
Expand Down
Loading

0 comments on commit 380e6a5

Please sign in to comment.