* Bump AntLoader to version 2
* Whoops - I forgot about the tests
* Oh yeah, cron.
Note to self: turn the autoloader into an individual file that can be included by the tests / cron file so I don't need to update 3 of them manually
Can be enabled by adding "Template: templatename" to a file header.
Then AntCMS will attempt to load the associated template from the "Templates" directory of your current theme
* Start implementing APCu caching
* Fix tests
* Now make PHPStan happy :)
* Fix tests
* Also enable the APCu extension in the tests
* Set maxlife to 7 days & clear with cron
* Implement a more correct way to clear the cache
* Also mention the APCu caching in the readme
* Started work on routing improvements
Creates a helper class to make handling routes a bit easier. Also should an issue that prevented SSL certs from being renewed via the .well-known folder
* Bugfix
* Added PHPDocs
* Implemented rudimentary multi-user support
* Delete src.zip
* Improve the update user function
And added a new function to the auth module to invalidate a session
* Update AntAuth.php
* Rename the configs, a bit more auth stuff
* Fix test and JS regex
* Turn the admin landing page into a twig template
* plugin/admin/ -> admin/
* Refactored templating for plugins
Plus. I finally converted the remaining options in the admin plugin to twig templates. No extra styling, but it'll be easier now
* Fix PHPStan warnings
* Basic "first time" user setup
* Improved styling
* Started implementing user management
* Completed user management in the admin panel
* Renamed templates, added support for sub-dirs
* Limit and validate allowed chars for usernames
* Finished the basics of the profile plugin
* Styling for the bootstrap theme
* Some more final touches
* Added an example to show author
* Tweak to the readme
Also, replaced the old <!--AntCMS-SiteLink--> with a new filter called absUrl, which can be used to convert any link to an absolute URL by adding the base site URL
It didn't really work, added a bunch to the overall file size, and computer-generated keywords just won't compare to human created ones, unless you're to use AI or a particularly advanced algorithm, which I feel is outside the scope of the project.
I've left the class in place, so if needed, it'll be really easy to add it back
There's zero need to create a new instance of the class before calling it, so this removes a very small amount of overhead, but more importantly removes the need to create and define a new class of it each time, which makes the code very slightly cleaner
Testing showed the in_array function made it overall slower than simply calling MD4. Using a define, I was able to get the overhead down to virtually nothing:
PHP 8.2:
Execution time for MD4: 0.064558029174805 seconds
Execution time for XXH128: 0.015785932540894 seconds
Execution time for Check: 0.0119788646698 seconds
PHP 8.1:
Execution time for MD4: 0.034939050674438 seconds
Execution time for XXH128: 0.0058550834655762 seconds
Execution time for Check: 0.0062451362609863 seconds
Now it automatically strips off the .md extension since it's unneeded, and it sorts it so that the 'index' of the site is always the first item in the array, since that dictates the order they appear in the browser
It now uses the one found here: https://github.com/Donatello-za/rake-php-plus
This is much better than the one I had hacked together.
Makes AntCMS a bit bigger.. but not by too much. I may end up removing the keyword generator outright, but for now I'm going to keep it.