Changelogs: Decoda v6.2.0

A new version of Decoda has been released, version 6.2.0. Please download the new tag or view the documentation. If you have any questions, be sure to send me an email or comment on this post. If you run into any problems, report an issue on the GitHub repository.

Version: 6.2.0
Tested On: PHP 5.4.3, Composer
Requires: PHP 5.3, Composer
Commit Hash: e90e79fddb88aff3928eb74018594b5717080e1b
Changes:

  • Added a newline to line break conversion setting lineBreaks [#48]
  • Added an onlyTags setting to filters that only allow tags and no text nodes as direct descendants
  • Added [*] list item tag to ListFilter (does not support nested lists)
  • Changed utility methods to public from protected
  • Improved newline normalization

Changelogs: Decoda v6.0.0

A new version of Decoda has been released, version 6.0.0. Please download the new tag or view the documentation. If you have any questions, be sure to send me an email or comment on this post. If you run into any problems, be sure to report an issue on the Github repository.

Version: 6.0.0
Tested On: PHP 5.3.13, Composer
Requires: PHP 5.3, Composer
Commit Hash: 70a679488d2be76c8f997f7bdcc0555871e7bfe2
Changes:

  • Added a Component class which all Filters, Hooks, Engines and Loaders extend
  • Added a Loader class to handle resource file loading for configuration and messages
  • Added Hook::startup() to initialize data before callbacks are called
  • Added Decoda::addMessages() to add messages using a Loader
  • Added Decoda::getBlacklist() and getWhitelist()
  • Added a 2nd argument $key for Decoda::addFilter() and addHook()
  • Added a default attribute to ImageFilter (img="200x200")
  • Added a default attribute to ListFilter (list="upper-roman")
  • Added a new TableFilter
  • Added custom exceptions
  • Renamed all config methods to getConfig() and setConfig()
  • Renamed Filter::tag() to getTag()
  • Renamed Filter::tags() to getTags()
  • Renamed Engine::setPath() to addPath()
  • Renamed Engine::getPath() to getPaths()
  • Updated CensorHook to support blacklisting words using a Loader
  • Updated EmoticonHook to support adding emoticons using a Loader
  • Updated Decoda::setLocale() so that it no longer throws exceptions (can now support setting the default locale)
  • Updated Engines to support multiple template lookup paths
  • Updated with Travis CI and phpunit.xml integration

Changelogs: Decoda v5.1.0

A new version of Decoda has been released, version 5.1.0. Please download the new tag or view the documentation. If you have any questions, be sure to send me an email or comment on this post. If you run into any problems, be sure to report an issue on the Github repository.

Version: 5.1.0
Tested On: PHP 5.4, Composer
Requires: PHP 5.3, Composer
Commit Hash: b554ba63750bf2c32b0e22b757fed57d5adb981f
Changes:

  • Updated to use Multibyte extensively
  • Added Decoda::hasFilter() and Decoda::hasHook()
  • Added <code> tags within <pre> for CodeFilter and proper semantics
  • Added source tag that renders <code> tag for CodeFilter
  • Refactored Decoda::_buildTag() to be more efficient
  • Fixed bugs with custom brackets in tag parsing
  • Fixed bugs with auto-linking regex
  • Fixed bug with URLs that end in trailing slash
  • Changed <code> to <var> for var tag

Changelogs: Decoda v5.0.0

A new version of Decoda has been released, version 5.0.0. Please download the new tag or view the documentation. If you have any questions, be sure to send me an email or comment on this post. If you run into any problems, be sure to report an issue on the Github repository.

Version: 5.0.0
Tested On: PHP 5.3
Requires: PHP 5.3
Commit Hash: 29dfe2d792d65c0d2b81d470213e54e75a2db722
Changes:

  • Changed folder and namespace structure to make heavier use of Composer
  • Added attribute support for self closing tags
  • Moved interfaces to source root
  • Reversed naming of abstract classes
  • Removed Decoda's autoloader in place of Composer
  • Removed DECODA constant
  • Updated to use SPL exceptions

Changelogs: Decoda v4.1.0

A new version of Decoda has been released, version 4.1.0. Please download the new tag or view the documentation. If you have any questions, be sure to send me an email or comment on this post. If you run into any problems, be sure to report an issue on the Github repository.

Version: 4.1.0
Tested On: PHP 5.4
Requires: PHP 5.3
Commit Hash: 5da68b72a0ec4b774eb9e421fa930b9ff0d316c5
Changes:

Changelogs: Decoda v4.0.0-beta

A new version of Decoda has been released, version 4.0.0-beta. Please download the new tag or view the documentation. If you have any questions, be sure to send me an email or comment on this post. If you run into any problems, be sure to report an issue on the Github repository.

Version: 4.0.0-beta
Tested On: PHP 5.3
Requires: PHP 5.3
Commit Hash: f960a1b4f4064d48894f4f7438cce7eed3a9381c
Changes:

  • Refactored for PHP 5.3 namespaces and moved all classes to namespaced folders
  • Added unit tests for all classes
  • Added configuration paths to define custom lookup locations
  • Added a new option for Filters: childrenBlacklist and renamed children to childrenWhitelist
  • Added a new option for Filters: persistContent
  • Added a new config for QuoteFilters: dateFormat
  • Added a new config for BlockFilters: spoilerToggle
  • Added a new config for UrlFilter: protocols
  • Added a new config for CensorHook: suffix
  • Added a new configs for EmoticonHook: path, extension
  • Added support for self closing tags:
  • Added a global blacklist to Decoda using Decoda::blacklist()
  • Fixed incorrectly nested tags
  • Fixed child and parent hierarchies
  • Fixed CRLF conversion problems
  • Merged Filter options alias and map into mapAttributes
  • Moved all class constants to Decoda base
  • Refactored all Filter regex patterns
  • Refactored all the template HTML classes
  • Removed all global constants except for DECODA
  • Removed Decoda::nl2br()
  • Removed Filter option testNoDefault
  • Renamed Filter option key to tag
  • Renamed Filter option tag to htmlTag
  • Renamed Filter option type to displayType
  • Renamed Filter option allowed to allowedTypes
  • Renamed Decoda::disableFilters() to resetFilters()
  • Renamed Decoda::disableHooks() to resetHooks()
  • Updated doc blocks and examples
  • Updated EmailFilter and UrlFilter to use filter_var()
  • Updated Decoda to throw exceptions when necessary

Changelogs: Decoda v3.4

A new version of Decoda has been released, version 3.4. Please download the new tag or view the documentation. If you have any questions, be sure to send me an email or comment on this post. If you run into any problems, be sure to report an issue on the Github repository.

Version: 3.4
Tested On: PHP 5.3
Requires: PHP 5.2
Commit Hash: 6fb3cdb9a906d720687d87e4b6b3b4533cd5af7f
Changes:

  • Added Composer support
  • Added an alias property to filters allowing attribute alias names for tags

Changelogs: Decoda v3.3

A new version of Decoda has been released, version 3.3. Please download the new tag or view the documentation. If you have any questions, be sure to send me an email or comment on this post. If you run into any problems, be sure to report an issue on the Github repository.

Version: 3.3
Tested On: PHP 5.3
Requires: PHP 5.2
Commit Hash: 710b972a367d908a33d198134417a30ef418b54b
Changes:

  • Added DecodaFilter::setupHooks() to allow filters to initialize hook dependencies
  • Added DecodaHook::setupFilters() to allow hooks to initialize filter dependencies
  • Added CodeHook (CodeFilter dependency) that stops emoticons from being processed in code blocks [Issue #9]
  • Check for class or interface during autoload [Issue #10]
  • Made HTML escaping a boolean setting [Issue #11]
  • Switched CensorHook::afterParse() to beforeParse()

Two new scripts, Resession and Decoda

It has been a while since I released some of my scripts, but now I have two to reveal! Well actually the Resession script has been up for nearly 2 months now, but I'm finally getting around to announcing. And without further ado, I give you Resession (Session Manager) and Decoda (A BBcode style parser).

Decoda

Decoda is a lightweight class that extracts and parses a custom markup language; based on the concept of BB code. Decoda supports all the basic HTML tags and manages special features for making links and emails auto-clickable, using shorthand emails and links, and finally allowing the user to add their own code tags.

Download the latest versions of Decoda

Resession

A small lightweight script that can manage and manipulate Session data. Calls session_start() in memory so that no header errors are thrown, as well as stores the session id in the object.

Download the latest version of Resession

If you have any suggestions for either of these classes, please feel free to comment this post or send me an email!