clean up and release
This commit is contained in:
parent
e9274e5b43
commit
453b36e962
@ -1,5 +1,9 @@
|
||||
simplyFavicon 2021.08.18
|
||||
2021.09.02
|
||||
- clean up code
|
||||
- add dcstore.xml pre-release file
|
||||
|
||||
2021.08.18
|
||||
* update license
|
||||
|
||||
simplyFavicon 2011.04.08
|
||||
2011.04.08
|
||||
* first version
|
14
README.md
14
README.md
@ -2,22 +2,22 @@
|
||||
|
||||
## WHAT IS simplyFavicon ?
|
||||
|
||||
simplyFavicon is a plugin for the open-source
|
||||
_simplyFavicon_ is a plugin for the open-source
|
||||
web publishing software called Dotclear.
|
||||
|
||||
.
|
||||
It adds a favicon to your blog.
|
||||
|
||||
## REQUIREMENTS
|
||||
|
||||
simplyFavicon requires:
|
||||
_simplyFavicon_ requires:
|
||||
|
||||
* Administrator permissions
|
||||
* Dotclear 2.18
|
||||
* A readable public directory.
|
||||
* Administrator permissions
|
||||
* Dotclear 2.19
|
||||
* A readable public directory.
|
||||
|
||||
## USAGE
|
||||
|
||||
First install simplyFavicon, manualy from a zip package or from
|
||||
First install _simplyFavicon_, manualy from a zip package or from
|
||||
Dotaddict repository. (See Dotclear's documentation to know how do this)
|
||||
|
||||
Add un file called ''favicon.xxx'' where xxx could be ico, jpg, png,
|
||||
|
24
_admin.php
24
_admin.php
@ -1,15 +1,15 @@
|
||||
<?php
|
||||
# -- BEGIN LICENSE BLOCK ----------------------------------
|
||||
#
|
||||
# This file is part of simplyFavicon, a plugin for Dotclear 2.
|
||||
#
|
||||
# Copyright (c) 2009-2021 Jean-Christian Denis and contributors
|
||||
#
|
||||
# Licensed under the GPL version 2.0 license.
|
||||
# A copy of this license is available in LICENSE file or at
|
||||
# http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
|
||||
#
|
||||
# -- END LICENSE BLOCK ------------------------------------
|
||||
/**
|
||||
* @brief simplyFavicon, a plugin for Dotclear 2
|
||||
*
|
||||
* @package Dotclear
|
||||
* @subpackage Plugin
|
||||
*
|
||||
* @author Jean-Christian Denis
|
||||
*
|
||||
* @copyright Jean-Christian Denis
|
||||
* @copyright GPL-2.0 https://www.gnu.org/licenses/gpl-2.0.html
|
||||
*/
|
||||
|
||||
if (!defined('DC_CONTEXT_ADMIN')) {
|
||||
return;
|
||||
@ -32,7 +32,7 @@ class adminSimplyFavicon
|
||||
'</p>' .
|
||||
'</div>';
|
||||
}
|
||||
|
||||
|
||||
public static function adminBeforeBlogSettingsUpdate($blog_settings)
|
||||
{
|
||||
$blog_settings->system->put('simply_favicon', !empty($_POST['simply_favicon']));
|
||||
|
35
_define.php
35
_define.php
@ -1,24 +1,31 @@
|
||||
<?php
|
||||
# -- BEGIN LICENSE BLOCK ----------------------------------
|
||||
#
|
||||
# This file is part of simplyFavicon, a plugin for Dotclear 2.
|
||||
#
|
||||
# Copyright (c) 2009-2021 Jean-Christian Denis and contributors
|
||||
#
|
||||
# Licensed under the GPL version 2.0 license.
|
||||
# A copy of this license is available in LICENSE file or at
|
||||
# http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
|
||||
#
|
||||
# -- END LICENSE BLOCK ------------------------------------
|
||||
/**
|
||||
* @brief simplyFavicon, a plugin for Dotclear 2
|
||||
*
|
||||
* @package Dotclear
|
||||
* @subpackage Plugin
|
||||
*
|
||||
* @author Jean-Christian Denis
|
||||
*
|
||||
* @copyright Jean-Christian Denis
|
||||
* @copyright GPL-2.0 https://www.gnu.org/licenses/gpl-2.0.html
|
||||
*/
|
||||
|
||||
if (!defined('DC_RC_PATH')){
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
$this->registerModule(
|
||||
"Simply favicon",
|
||||
"Multi-agents favicon",
|
||||
"Jean-Christian Denis",
|
||||
'2021.08.18',
|
||||
'admin'
|
||||
'2021.09.02',
|
||||
[
|
||||
'requires' => [['core', '2.19']],
|
||||
'permissions' => 'admin',
|
||||
'type' => 'plugin',
|
||||
'support' => 'https://github.com/JcDenis/simplyFavicon',
|
||||
'details' => 'http://plugins.dotaddict.org/dc2/details/simplyFavicon',
|
||||
'repository' => 'https://raw.githubusercontent.com/JcDenis/simplyFavicon/master/dcstore.xml'
|
||||
]
|
||||
);
|
22
_prepend.php
22
_prepend.php
@ -1,15 +1,15 @@
|
||||
<?php
|
||||
# -- BEGIN LICENSE BLOCK ----------------------------------
|
||||
#
|
||||
# This file is part of simplyFavicon, a plugin for Dotclear 2.
|
||||
#
|
||||
# Copyright (c) 2009-2021 Jean-Christian Denis and contributors
|
||||
#
|
||||
# Licensed under the GPL version 2.0 license.
|
||||
# A copy of this license is available in LICENSE file or at
|
||||
# http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
|
||||
#
|
||||
# -- END LICENSE BLOCK ------------------------------------
|
||||
/**
|
||||
* @brief simplyFavicon, a plugin for Dotclear 2
|
||||
*
|
||||
* @package Dotclear
|
||||
* @subpackage Plugin
|
||||
*
|
||||
* @author Jean-Christian Denis
|
||||
*
|
||||
* @copyright Jean-Christian Denis
|
||||
* @copyright GPL-2.0 https://www.gnu.org/licenses/gpl-2.0.html
|
||||
*/
|
||||
|
||||
if (!defined('DC_RC_PATH')){
|
||||
return;
|
||||
|
32
_public.php
32
_public.php
@ -1,15 +1,15 @@
|
||||
<?php
|
||||
# -- BEGIN LICENSE BLOCK ----------------------------------
|
||||
#
|
||||
# This file is part of simplyFavicon, a plugin for Dotclear 2.
|
||||
#
|
||||
# Copyright (c) 2009-2021 Jean-Christian Denis and contributors
|
||||
#
|
||||
# Licensed under the GPL version 2.0 license.
|
||||
# A copy of this license is available in LICENSE file or at
|
||||
# http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
|
||||
#
|
||||
# -- END LICENSE BLOCK ------------------------------------
|
||||
/**
|
||||
* @brief simplyFavicon, a plugin for Dotclear 2
|
||||
*
|
||||
* @package Dotclear
|
||||
* @subpackage Plugin
|
||||
*
|
||||
* @author Jean-Christian Denis
|
||||
*
|
||||
* @copyright Jean-Christian Denis
|
||||
* @copyright GPL-2.0 https://www.gnu.org/licenses/gpl-2.0.html
|
||||
*/
|
||||
|
||||
if (!defined('DC_RC_PATH')){
|
||||
return;
|
||||
@ -27,11 +27,11 @@ class publicSimplyFavicon extends dcUrlHandlers
|
||||
'jpg' => 'image/jpeg',
|
||||
'mng' => 'video/x-mng'
|
||||
);
|
||||
|
||||
|
||||
public static function simplyFaviconUrl($arg)
|
||||
{
|
||||
global $core;
|
||||
|
||||
|
||||
$mimetypes = self::$mimetypes;
|
||||
$public_path = path::real(path::fullFromRoot($core->blog->settings->system->public_path, DC_ROOT)) . '/favicon.';
|
||||
|
||||
@ -48,17 +48,17 @@ class publicSimplyFavicon extends dcUrlHandlers
|
||||
exit;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public static function publicHeadContent($core)
|
||||
{
|
||||
if (!$core->blog->settings->system->simply_favicon){
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
$mimetypes = self::$mimetypes;
|
||||
$public_path = path::real(path::fullFromRoot($core->blog->settings->system->public_path, DC_ROOT)) . '/favicon.';
|
||||
$public_url = $core->blog->url.$core->url->getBase('simplyFavicon') . '.';
|
||||
|
||||
|
||||
// ico : IE6
|
||||
if (file_exists($public_path . 'ico') && '?' != substr($core->blog->url, -1)) {
|
||||
echo
|
||||
|
11
dcstore.xml
Normal file
11
dcstore.xml
Normal file
@ -0,0 +1,11 @@
|
||||
<modules xmlns:da="http://dotaddict.org/da/">
|
||||
<module id="simplyFavicon">
|
||||
<name>Simply favicon</name>
|
||||
<version>2021.09.02</version>
|
||||
<author>Jean-Christian Denis</author>
|
||||
<desc>Multi-agents favicon</desc>
|
||||
<file>https://github.com/JcDenis/simplyFavicon/releases/download/v2021.09.02/plugin-simplyFavicon.zip</file>
|
||||
<da:details>http://plugins.dotaddict.org/dc2/details/simplyFavicon</da:details>
|
||||
<da:support>https://github.com/JcDenis/simplyFavicon</da:support>
|
||||
</module>
|
||||
</modules>
|
@ -8,6 +8,4 @@
|
||||
$GLOBALS['__l10n']['Enable "Simply favicon" extension'] = 'Activer l\'extension "Simply favicon"';
|
||||
|
||||
#_admin.php:28
|
||||
$GLOBALS['__l10n']['You must place an image called favicon.png or .jpg or .ico into your blog\'s public directory.'] = 'Vous devez placer une image nommée favicon.png, .jpg ou .ico dans le répertoire publique du blog.';
|
||||
|
||||
?>
|
||||
$GLOBALS['__l10n']['You must place an image called favicon.png or .jpg or .ico into your blog\'s public directory.'] = 'Vous devez placer une image nommée favicon.png, .jpg ou .ico dans le répertoire publique du blog.';
|
Loading…
Reference in New Issue
Block a user