diff --git a/CHANGELOG.md b/CHANGELOG.md
index 36116db..40835d7 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,4 +1,8 @@
-Version 0.5.0 (2020-03-28) - Gvx
+1.0 - 2022.12.15
+* update to dotclear 2.24
+* use anonymous function for behaviors
+
+0.5.0 - 2020.03.28 - Gvx
* Suppression de l'attribut "required" sur le champ "c_mail"
* Correction pour une adresse mail valide "invalid@invalid" par "invalid@invalid.fr"
* Pré-requis dotclear V2.11 mini
diff --git a/LICENSE b/LICENSE
index 8cdb845..d511905 100644
--- a/LICENSE
+++ b/LICENSE
@@ -1,12 +1,12 @@
- GNU GENERAL PUBLIC LICENSE
- Version 2, June 1991
+ GNU GENERAL PUBLIC LICENSE
+ Version 2, June 1991
- Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
+ Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
- Preamble
+ Preamble
The licenses for most software are designed to take away your
freedom to share and change it. By contrast, the GNU General Public
@@ -56,7 +56,7 @@ patent must be licensed for everyone's free use or not licensed at all.
The precise terms and conditions for copying, distribution and
modification follow.
- GNU GENERAL PUBLIC LICENSE
+ GNU GENERAL PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. This License applies to any program or other work which contains
@@ -255,7 +255,7 @@ make exceptions for this. Our decision will be guided by the two goals
of preserving the free status of all derivatives of our free software and
of promoting the sharing and reuse of software generally.
- NO WARRANTY
+ NO WARRANTY
11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
@@ -277,9 +277,9 @@ YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
POSSIBILITY OF SUCH DAMAGES.
- END OF TERMS AND CONDITIONS
+ END OF TERMS AND CONDITIONS
- How to Apply These Terms to Your New Programs
+ How to Apply These Terms to Your New Programs
If you develop a new program, and you want it to be of the greatest
possible use to the public, the best way to achieve this is to make it
@@ -290,8 +290,8 @@ to attach them to the start of each source file to most effectively
convey the exclusion of warranty; and each file should have at least
the "copyright" line and a pointer to where the full notice is found.
- {description}
- Copyright (C) {year} {fullname}
+
+ Copyright (C)
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -329,7 +329,7 @@ necessary. Here is a sample; alter the names:
Yoyodyne, Inc., hereby disclaims all copyright interest in the program
`Gnomovision' (which makes passes at compilers) written by James Hacker.
- {signature of Ty Coon}, 1 April 1989
+ , 1 April 1989
Ty Coon, President of Vice
This General Public License does not permit incorporating your program into
@@ -337,4 +337,3 @@ proprietary programs. If your program is a subroutine library, you may
consider it more useful to permit linking proprietary applications with the
library. If this is what you want to do, use the GNU Lesser General
Public License instead of this License.
-
diff --git a/README.md b/README.md
index 51bb122..f2f069b 100644
--- a/README.md
+++ b/README.md
@@ -1,2 +1,45 @@
-# emailOptionnel
-Rendre la saisie de l'adresse e-mail optionnelle dans les commentaires
+# README
+
+[![Release](https://img.shields.io/github/v/release/JcDenis/emailOptionnel)](https://github.com/JcDenis/emailOptionnel/releases)
+[![Date](https://img.shields.io/github/release-date/JcDenis/emailOptionnel)](https://github.com/JcDenis/emailOptionnel/releases)
+[![Issues](https://img.shields.io/github/issues/JcDenis/emailOptionnel)](https://github.com/JcDenis/emailOptionnel/issues)
+[![Dotclear](https://img.shields.io/badge/dotclear-v2.24-blue.svg)](https://fr.dotclear.org/download)
+[![Dotaddict](https://img.shields.io/badge/dotaddict-official-green.svg)](https://plugins.dotaddict.org/dc2/details/emailOptionnel)
+[![License](https://img.shields.io/github/license/JcDenis/emailOptionnel)](https://github.com/JcDenis/emailOptionnel/blob/master/LICENSE)
+
+## WHAT IS EMAILOPTIONNEL ?
+
+_emailOptionnel_ is a plugin for the open-source
+web publishing software called Dotclear.
+
+Allow visitors to publish comments without fill in their email.
+
+## REQUIREMENTS
+
+ _emailOptionnel_ requires:
+
+ * admin permissions to set up plugin
+ * Dotclear 2.24
+
+## USAGE
+
+First install _emailOptionnel_, manualy from a zip package or from
+Dotaddict repository. (See Dotclear's documentation to know how do this)
+
+Go to ''blog preference'' => fieldset ''plugin preference'', fill in form.
+
+## LINKS
+
+ * License : [GNU GPL v2](https://www.gnu.org/licenses/old-licenses/lgpl-2.0.html)
+ * Source & contribution : [GitHub Page](https://github.com/JcDenis/enhancePostContent)
+ * Packages & details : [Dotaddict Page](https://plugins.dotaddict.org/dc2/details/enhancePostContent)
+ * Discuss and help : [Dotclear Forum](http://forum.dotclear.org/viewtopic.php?pid=332948#p332948)
+
+## CONTRIBUTORS
+
+ * Oleksandr Syenchuk (author)
+ * Gvx
+ * Pierre Van Glabeke
+ * Jean-Christian Denis
+
+ You are welcome to contribute to this code.
\ No newline at end of file
diff --git a/_admin.php b/_admin.php
index 772680b..5a7a9b1 100644
--- a/_admin.php
+++ b/_admin.php
@@ -1,14 +1,40 @@
addBehavior('adminBlogPreferencesForm', array('emailOptionnelBehaviors', 'adminBlogPreferencesForm'));
-$core->addBehavior('adminBeforeBlogSettingsUpdate', array('emailOptionnelBehaviors', 'adminBeforeBlogSettingsUpdate'));
+dcCore::app()->addBehavior('adminBlogPreferencesFormV2', function () {
+ dcCore::app()->blog->settings->addNamespace(initEmailOptionnel::SETTING_NAME);
+
+ echo
+ '