https://www.sorcerers-tower.net/Sorcerer's Tower2021-10-25T17:00:00ZPeter Boughtonhttps://www.peterboughton.nethttps://www.sorcerers-tower.net/articles/repositories,_releases_and_status_updatesRepositories, Releases and Status Updates2021-10-25T17:00:00Z2021-10-25T17:00:00Z<p>There have been releases of the software on <a href="https://www.sorcerersisle.com/">Sorcerer's Isle</a>, mostly to
update URLs and fix the lack of documentation in the download packages.</p>
<p>The reason for the URL changes is the migration of repositories from GitHub
onto my own server, details of which will follow this quick summary of the releases.</p>
<p>If you want more details on the releases, read the <a href="https://www.sorcerers-tower.net/articles/repositories,_releases_and_status_updates">full version</a> of this post, but in summary...</p>
<ul>
<li><p><a href="https://www.sorcerersisle.com/software/luje">Lucee on Jetty</a> is now at v0.7 and both Jetty 9.4.44 and Jetty 10.0.7 have been bundled with Lucee 5.3.8</p></li>
<li><p><a href="https://www.sorcerersisle.com/software/cfpassphrase">cfPassphrase</a> had been sitting on rc0.2 for longer than necessary and was promoted to v0.2 -
there are no code changes - no need to update current projects.</p></li>
<li><p><a href="https://www.sorcerersisle.com/software/qpscanner">QueryParam Scanner</a> v0.8 has been formally merged/released - again, no code changes from rc0.8,
just another case of life getting in the way at the time when this should have otherwise happened.</p></li>
<li><p><a href="https://www.sorcerersisle.com/software/cfregex">cfRegex</a> v0.1.003 has been re-released as v0.3 to keep versioning consistent amongst projects,
and actually has its own repository now, along with simplified packages and documentation.</p></li>
<li><p><a href="https://www.sorcerersisle.com/software/scatter">Scatter</a> v0.1.1 does nothing more than add documentation and update the repository URL,
so again nothing to update for existing projects.</p></li>
</ul>
<h2>Why</h2>
<p>So that's the quick overview, but why?
The primary reason for all of these releases was to change their repository URLs, from
<code>https://github.com/boughtonp/[reponame]</code> to <code>https://code.sorcerersisle.com/[reponame]</code>.</p>
<p>This is not a total move away from GitHub - it is still used for issue tracking
(for the time being), and I'll most likely still push code there when full
releases are made - but it will only be a secondary source/mirror.</p>
<p>The motivation for doing this is to reduce dependency on centralised proprietary services,
and removing the unwanted requirement to have JavaScript enabled.</p>
<p>This move would have happened a great deal sooner, but when I looked into the various Git
repository browsers available, I found a lot of bloated software with features
I neither needed nor wanted, hundreds of megabytes of code and dependencies,
no ability to meaningfully change how it looks, and so on.</p>
<p>Long story short: irritated by how everything sucked, whilst also looking for
a decent project to extend my Python skills, I created a
lightweight and themeable Git repository browser.</p>
<h2 id="gitfrit">GitFrit</h2>
<p>GitFrit is capable of running on CentOS 7, only needing Python 3.6 (or newer) and Git 2.24 (or newer).
The source code is currently ~0.5MB (half of that is the included templating library, which I'd like to streamline).</p>
<p>GitFrit is tiny in comparison to almost everything else available - even git-web with ~0.3MB of source is only slightly smaller,
and that has its markup intertwined with Perl, preventing it from being themeable.</p>
<p>GitFrit is not quite ready for release yet - I took shortcuts to get it up onto
Sorcerer's Isle sooner, and those now need to be cleaned up into configuration
options, all of which needs to be documented, plus there's a couple more features
I'd like it to have first.</p>
<p>When those changes (and thus a release) will happen is uncertain - I need to shift focus
back onto other priorities, and unless there's significant interest in GitFrit, it may take me a
while to get back to it and spend the time to make it publicly available.</p>
<p>If you are interested, do <a href="https://www.sorcerersisle.com/contact">send me an email</a> so I can let you know when it's ready.</p>
<p><br/></p>
https://www.sorcerers-tower.net/articles/introducing_scatter_js_libraryIntroducing Scatter JS Library2020-03-31T11:00:00Z2020-03-31T11:00:00Z<p><a href="//www.sorcerersisle.com/software/scatter">Scatter</a> is a JavaScript library for randomly arranging HTML elements within a containing element.
It is deliberately lightweight, easy to integrate, and without dependencies.</p>
<p>The initial script was written to provide a scattered polaroid effect for an in-page gallery,
as a reaction to the complexity found in a couple of existing libraries - both of those
other libraries expected JSON files containing the image URLs, which was parsed and
iterated through to generate specific markup, and neither of the libraries could be easily
modified to take the simpler and more flexible approach of being pointed at existing markup.</p>
<p>Thus, the script that evolved into Scatter was created, with a focus on providing an
easy-to-integrate and configurable scattering effect with a clean core script - i.e.
following the philosophy of doing one thing well, and also making it easy for others
to understand (and extend if needed).</p>
<p>Scatter does not convert JSON to HTML for you - that's a distinct task from randomly
arranging HTML elements - but it will work whether your HTML is static or dynamic,
and it does not limit you to images styled as polaroids.</p>
<p>The versatility is demonstrated within the <a href="//docs.sorcerersisle.com/scatter">Scatter documentation</a>, where a handful of
examples show how it can be used to achieve vastly different effects.</p>
<p>Scatter does not require any external libraries, it's a single ~12KB file (~3KB compressed)
and will run in any browser released in the past five years (earlier browsers will work with
appropriate polyfills, available either from MDN or backwards compatibility libraries).</p>
<p>If you find any issues, or you have a need that Scatter almost-but-not-quite meets, feel free
to either <a href="https://github.com/boughtonp/scatter/issues">raise an issue</a> or <a href="//www.sorcerersisle.com/contact">get in touch directly</a> to discuss further.</p>
https://www.sorcerers-tower.net/articles/configuring-jetty-for-https-with-letsencryptConfiguring Jetty for HTTPS with Let's Encrypt2019-11-04T20:00:00Z2019-11-04T20:00:00Z<p>The Jetty documentation for <a href="https://www.eclipse.org/jetty/documentation/current/configuring-ssl.html">Configuring SSL/TLS</a> is long and
daunting, but makes no mention of how to work with the EFF's <a href="https://letsencrypt.org/">Let's Encrypt</a>
certificate authority, which provides free automated certificates with the aim
of having the entire web available over HTTPS.</p>
<p>This article provides the steps for obtaining a Let's Encrypt certificate,
importing it into Jetty, enabling HTTPS using the certificate, and handling
renewals.</p>
<p>It assumes you have Jetty setup in a home/base configuration, serving over HTTP
for one or more Internet-facing domain names.</p>
<p>As with all such guides, it is recommended to read all steps before making any changes,
and ensure you have backups for any existing files you may modify.</p>
<p><a href="https://www.sorcerers-tower.net/articles/configuring-jetty-for-https-with-letsencrypt">Continue</a>.</p>
https://www.sorcerers-tower.net/articles/getting_the_original_url_in_apacheGetting the Original URL in Apache2019-07-31T16:00:00Z2019-07-31T16:00:00Z<p>There are various situations where one might want to know the full URL sent
over HTTP by the user agent, before any rewriting has occurring.</p>
<p>Depending on the situation and setup, it can be as simple as using CGI variables
such as <code>path_info</code>, <code>redirect_url</code> or <code>request_uri</code>, and within a JVM servlet
<a href="https://javaee.github.io/javaee-spec/javadocs/javax/servlet/http/HttpServletRequest.html#getRequestURL--"><code>getRequestUrl()</code></a> may prove useful - but none of those are <em>guaranteed</em> to be
the URL which Apache received, nor are any of Apache's other <a href="https://httpd.apache.org/docs/current/expr.html#vars">documented variables</a>.</p>
<p>Fortunately there is a workaround, because one variable provided is the
first line of the HTTP request, which contains the desired request URL nestled
between the method and protocol, i.e: "<code>GET /url HTTP/1.1</code>" - meaning all that
needs doing is to chop the ends off.</p>
<p>It is relatively simple to extract the URL, and at the same time provide it to
later scripts, by using the RequestHeader directive from <a href="https://httpd.apache.org/docs/current/mod/mod_headers.html">mod_headers</a> to
set and modify a header, like so:</p>
<pre><code>RequestHeader set X-Original-URL "expr=%{THE_REQUEST}"
RequestHeader edit* X-Original-URL ^[A-Z]+\s|\sHTTP/1\.\d$ ""
</code></pre>
<p>The first line creates a header named <code>X-Original-URL</code> with the full value of
the variable.</p>
<p>The second line performs a regex replace on the specified header, matching
both the request method and its trailing space (<nobr><code>^[A-Z]+\s</code></nobr>) then
the protocol plus its preceding space (<nobr><code>\sHTTP/1\.\d$</code></nobr>) and
replacing with an empty string to leave just the URL.</p>
<p>The <code>*</code> after edit is what makes the replace occur multiple times - without it
only the first match would be replaced. (i.e. the <code>*</code> is equivalent to a <code>g</code>/Global flag.)</p>
<p>The name <code>X-Original-URL</code> is used for compatibility with the equivalent
header set by the IIS <a href="https://www.iis.net/downloads/microsoft/url-rewrite">URL Rewrite Module</a> - both that module and the above
solution provide the full request URL, including query string, and encoded in
whatever manner the user agent sent, but one difference is that the above
config always sets the header, whilst the IIS version only sets it when the URL
has been rewritten.</p>
https://www.sorcerers-tower.net/articles/why_test_driven_developmentWhy Test-Driven Development?2016-03-20T18:20:06Z2016-03-20T18:20:06Z<p>Test-Driven Development - TDD - is a great way to catch bugs before they go live,
to ensure fixes stay fixed, and to prove the functionality of software. This
stability alone is reason enough to ensure tests exist for as much of every
application as is feasible, but is not the only benefit.</p>
<p><br/>
When you write the all the key tests for a piece of functionality <em>in advance
of writing the rest of the code</em>, you are defining when that functionality
will be complete, how much progress has been made, and specifically what tasks
are next to be done.</p>
<p>For anyone practising Agile development, the parallels should be blatant. There
is similarity in the benefits too, particularly with respect to keeping focused
on the task being worked on and knowing when you're done and ready to move on.</p>
<p><br/>
With Agile development, each piece of functionality is broken down in a couple
of ways - as business-focused acceptance criteria, and development-focused tasks,
which is (in part) about making large pieces of work less daunting. Likewise,
TDD provides a way for an otherwise overwhelming piece of work to be described
step-by-step by someone who understands the matter at hand, and (with appropriate
software structure and functionality) can then be divided up amongst multiple
developers to increase overall velocity.</p>
<p>Incomplete functionality can be more easily passed from one developer to another,
simplifying the explanations of what has been done and still needs to be done;
the tests do the talking.</p>
<p><br/>
TDD means all newly written code has tests to describe what it should do, which
helps to build trust in the application - a full set of passing tests proves a
particular change has not altered the tested functionality, and allows you to
deploy it with far more confidence than otherwise.</p>
<p>TDD means writing the tests happens first - <em>before</em> making the changes that the
tests apply to, not afterwards. Writing tests afterwards still has advantages
compared to no tests at all, but it does not guarantee that <em>all</em> code has tests
- indeed, it makes it more likely that tests will be rushed or dropped if time
is limited; precisely the situation when bugs are more likely to be introduced
- and thus can give false confidence in what the result of a set of changes may
be.</p>
<p><br/>
Test-Driven Development <em>increases</em> productivity. As with most things, TDD has a
learning curve - it's not something a programmer will instantly be completely
efficient with - but some programmers will still complain (erroneously) that
writing automated tests slows them down.</p>
<p>It's obvious that writing tests is additional work compared to not doing so, but
this additional upfront cost comes with the saving of not having to manually
step through performing repetitive tasks with minor variations each time - each
test is written once, and is executed easily each time the code progresses. When
automated, tests are not forgotton - the full test suite can be run at any time
to check for regressions or unexpected side-effects. Automated testing doesn't
remove the need to use an application as a user, but it <em>far</em> reduces the time
it takes to check that changes are working as intended, and helps reduce the
space for human error.</p>
<p>Of course, practising TDD does mean that pesky bugs are identified at the time
of development - not days, weeks, or months down the line - and this can also
appear to make things slower; in reality identifying bugs sooner generally makes
the issue easier to fix.</p>
<p><br/>
Finally, with TDD you know when you're done - when all the tests pass. Without
tests written up-front, there may not be a clear finishing point. It's easy for
developers to become side-tracked, or to unconciously introduce scope creep, and
thus slow down the completion of a task which an appropriate set of test cases
would have identified as already implemented.</p>
<p><br/>
This article hopefully explains how Test-Driven Development is not just about
code quality, reducing application errors and increasing stability. It enables
developers to work smarter and faster, give clearer progress updates, know what
they're doing next and not become disheartened on bigger chunks of work.</p>
<p>TDD is a critical methodology which any competent professional developer should
<em>want</em> to use.
<br/>
<br/></p>
https://www.sorcerers-tower.net/articles/introduction_to_password_securityIntroduction to Password Security2015-10-18T22:10:00Z2015-10-18T22:10:00Z<p>Earlier this year I gave a talk on Password Security at Digital Croydon #5, and
didn't want to simply put up the slides without any commentary, so I've written
this article to accompany them. It is primarily for the benefit of those that
attended - by which I mean it wont explain every slide or go into detail on
everything the talk covered, but will explain the key points, provide links, etc.</p>
<p>Similarly, as mentioned in the talk, it didn't cover everything there is to
know, and this article wont do that either - it's an introduction, not a
comprehensive guide.</p>
<p>(At some point I do hope to write up more detailed articles, both on the points
covered and on related subjects - if/when that happens I will add the relevant
links to this article.)</p>
<p><a href="https://www.sorcerers-tower.net/articles/introduction_to_password_security">Continue</a>.</p>
https://www.sorcerers-tower.net/articles/lucee-on-jettyIntroducing Lucee on Jetty2015-02-21T23:45:00Z2015-02-21T23:45:00Z<p><a href="//www.sorcerersisle.com/projects:lucee-on-jetty">Lucee on Jetty</a> bundles the <a href="http://eclipse.org/jetty">Jetty server</a> with the <a href="http://lucee.org">Lucee CFML engine</a>,
cleanly configured using the home/base functionality in Jetty 9, and extensively documented.</p>
<p>The main aim is to provide a Lucee package that is a simple unzip-and-run to get
started, whilst providing a fully functional and capable web server, and also
making it clear how everything works to allow it to be adapted as needed.</p>
<p>This first release is v0.5 because I don't consider it sufficiently complete yet
- it all works fine, but doesn't yet contain everything I feel it should - for
example, HTTPS has not been configured and documented, and whilst Jetty itself
does support HTTPS and there's nothing stopping anyone consulting the Jetty docs
and setting it up, this project is about reducing that work.</p>
<p>So for development use it's fine, if you don't need HTTPS or are willing to
configure it yourself, go ahead - otherwise I hope to get what I consider a
complete v1.0 ready as soon as time permits, but didn't want to delay releasing
what I've done so far.</p>
<p>Downloads are available from the <a href="//www.sorcerersisle.com/projects:lucee-on-jetty">Lucee on Jetty project page</a>; there's a
<a href="https://github.com/boughtonp/lucee-on-jetty/wiki">documentation wiki</a> at GitHub, and the template for building bundles in
the <a href="https://github.com/boughtonp/lucee-on-jetty">GitHub repo</a> .</p>
<p>As ever, I welcome any feedback or questions you might have - please use the
<a href="https://github.com/boughtonp/lucee-on-jetty/issues">issue tracker</a>.</p>
https://www.sorcerers-tower.net/articles/luceeLucee2015-01-29T23:59:00Z2015-01-29T23:59:00Z<p>Lucee is the best CFML engine.</p>
<p>Nine years ago I began a blog article with a similar claim, and set out to
explain why Railo was at that time the best CFML engine. Well the simplest proof
of Lucee taking the crown is that Lucee is a fork of Railo by its original
creator, Michael Offner.</p>
<p>The thing that made Railo great and that Lucee will be taking further is in
being a CFML engine written for developers. That is to say, with features added
through developers saying "I need feature X to do my job better" - and
specifically <em>not</em> via vague ideas decided on by product managers getting
feedback from non-technical clients who say "we need to do mobile" and then
having a bunch of disconnected non-programmers come up with a horrendously buggy
and useless mess called cfclient. <em>Eugh!</em></p>
<p>Good programmers already know what tools they need to achieve certain tasks,
and if those tools don't exist or aren't good enough, they need the ability to
create/improve them - that is what Micha gave us with Railo, and Lucee promises
to take this further - to make it even easier for the developer community to
adapt it to their needs.</p>
<p>Bering a fork, Lucee continues the versioning from Railo, launching tonight with
Lucee 4.5 available already, and an excellent Lucee 5 just around the corner.</p>
<h3>Why Not Railo?</h3>
<p>Many will be wondering why fork Railo, instead of working on what was there, and
the best way to answer that is simply to refer to what Brad Wood has already
written on the Railo mailing list: <a href="">https://groups.google.com/forum/#!msg/railo/B_1S3WzVPXY/hlIeZDE1u98J</a></p>
<p>To re-iterate the key points: this is the original Railo developer, taking the
Railo source code, and refreshing the project. Don't mistake for division what
is actually an inclusive evolution, and importantly: a sign of exciting things
to come!</p>
<h3>Lucee 5</h3>
<p>With the next release, Lucee will bring incredible flexibility to CFML and JVM
developers through a couple of key technologies.</p>
<p><a href="http://www.osgi.org/">OSGi</a> is a modular platform for the JVM which allows only
the necessary libraries to be loaded. So if, for example, you don't use
Hibernate, it doesn't get included and wont add any overhead. Railo was already
lightweight, and Lucee with OSGi will take this even further.</p>
<p><a href="https://jcp.org/aboutJava/communityprocess/final/jsr223/index.html">JSR223</a> or
"Scripting for the Java Platform" is a standard for embedding different languages
on the JVM, and what this means is being able to use Lucee to write CFML in far
more places than before. A good example is Ant build scripts - doing certain
things with Ant can be awkward and convoluted and Lucee 5 will allow embedding
CFML which makes those same tasks trivial.</p>
<p>Together these bring some great opportunies, and this is only the beginning...</p>
<h3>More Info</h3>
<p>I've tried to avoid simply parrotting what others have already written, so to
get further details on Lucee's launch and future you should definitely check out
<a href="http://blog.cmdbase.io/lucee/">Mark Drew's blog post</a>,
<a href="http://blog.adamcameron.me/2015/01/lucee.html">Adam Cameron's blog post</a>,
<a href="https://groups.google.com/d/msg/railo/B_1S3WzVPXY/wWrw_2KmjQ8J">the thread started by Igal on the Railo list</a>,
and of course the official Lucee website: <a href="http://lucee.org">lucee.org</a>.</p>
https://www.sorcerers-tower.net/articles/queryparam_scanner_0-8_release_candidateQueryParam Scanner 0.8 Release Candidate2013-06-29T14:15:00Z2013-06-29T14:15:00Z<p>The release candidate for the next version of <a href="//www.sorcerersisle.com/projects:qpscanner.html">QueryParam Scanner</a> is
<a href="https://github.com/boughtonp/qpscanner/tree/rc0.8">available on GitHub</a>.</p>
<p>So what's changed?</p>
<p>Well it now runs on <a href="http://fw1.riaforge.org">FW/1</a> rather than <a href="http://fusebox.org">Fusebox</a>, and the UI has a new
theme - the previous gold/beige is gone, and in its place is a theme based on a
"new" logo which I've actually had sitting around for several years. There's CSS
used that will require a modern browser - FF4 and IE9 both work, but no
guarantees for anything older.</p>
<p>Functionality-wise there's a couple of fixes: an error is now thrown when a
directory doesn't exist (previous behaviour was to return 0 matches in 0 files),
and the IDs returned in data structures are now content-based hashes (previously
they were ever-changing UUIDs). Oh, and the IDs are now displayed with the HTML
results, in preparation for future functionality that'll potentially use them.</p>
<p>A new experimental (i.e. buggy) feature has been added to seperate the query
code into SELECT/FROM/WHERE/etc parts, when returning data structures. This may
help with post-processing the data, but has known flaws so use with care.
(The existing ORDER BY functionality has also been marked as experimental to
similarly indicate that it's not perfect.)</p>
<p>There's a minor change in that relative paths are officially <em>not</em> supported -
the UI always stated absolute paths or mappings were required, but there was
ugly code in place to try and make relative paths work too - that code has been
removed. If you used relative paths before, you need to resolve them before
passing to qpscanner.</p>
<p>In summary:</p>
<pre><code>Changed: Switched to FW/1 and removed unnecessary files.
Changed: New logo and front-end UI.
Removed: Dropped unofficial relative path support.
Added: Experimental ability to separate query code into segments
Fixed: IDs now use content-based SHA hashes, not random UUIDs.
Fixed: Throw error when path does not exist, instead of zero results.
Supports: ColdFusion 9/10 and Railo 3.3/4.0/4.1
</code></pre>
<p>That's it for now. There are several new features planned to make qpscanner
faster, more flexible and more useful, but you'll have to wait for a future
release for those.</p>
<p>As ever, if you have any feedback, feature requests, or find any bugs, then
please go ahead and get in touch via the <a href="https://github.com/boughtonp/qpscanner/issues">GitHub issue tracker</a>.</p>
https://www.sorcerers-tower.net/articles/speaking_at_scotch_on_the_rocks_2013Speaking at Scotch on the Rocks 20132013-03-13T12:10:00Z2013-03-13T12:10:00Z<p>I will be speaking at this year's <a href="http://sotr.eu">Scotch on the Rocks</a> conference.
<a href="http://sotr.eu/index.cfm/main/presentation/by/peter_boughton">My presentation</a> is on the subject of getting help when you are stuck
and how to describe your issue in a way that makes it easier for others to help
you.</p>
<p>All developers have times when they need help, but it's not always easy to ask
for (particularly when all you want is to get past a tricky problem, not have
long tangental discussions). Having spent a lot of time both seeking and
offering help, I hope to shed some light on the quickest ways to find solutions
and effective methods for framing your issues so that fellow developers can
understand what you need.</p>
<p>The talk will be aimed at developers of any level who want help with getting help.</p>
<p>Scotch on the Rocks is Europe's longest running conference catering for CFML
developers, having been held most years since 2005. This year it takes place on
the 6th and 7th of June at the <a href="http://www3.hilton.com/en/hotels/united-kingdom/hilton-edinburgh-grosvenor-hotel-EDNGRHN/index.html">Hilton Edinburgh Grosvenor hotel</a> and
covers a <a href="http://sotr.eu/index.cfm/main/presentation">wide variety of topics</a> on different aspects of web development
- so whether you're looking to learn new techniques and technologies or you
want to network and socialise with other programmers, Scotch on the Rocks is the
conference for you.</p>
<p>Hurry up and <a href="http://sotr.eu/index.cfm/main/tickets">book your tickets</a> before they sell out!</p>
https://www.sorcerers-tower.net/articles/queryparam_scanner_v0-7-5_releasedQueryParam Scanner v0.7.5 Released2013-01-10T15:30:00Z2013-01-10T15:30:00Z<p>Earlier this week I promoted the release candidate for 0.7.5 of QueryParam Scanner
to full release.</p>
<p>For anyone unaware, <a href="//www.sorcerersisle.com/projects:qpscanner.html">QueryParam Scanner</a> is a simple tool for identifying
unparameterised variables in CFML queries (which may indicate a potential SQL
injection risk).</p>
<p>This version has a handful of bug fixes and code cleanups, resulting in faster
more accurate scanning than previous versions, plus the addition of JSON output
format, giving a more lightweight option if used in scripted processes.</p>
<p>For further details on these, see the <a href="//www.sorcerers-tower.net/articles/queryparam_scanner_0-7-5_release_candidate">previous RC article</a>; other than
a couple of trivial fixes and a new readme, nothing has changed since that.</p>
<p>To download the latest version, you can either clone the <a href="https://github.com/boughtonp/qpscanner.git">git repo</a>, or
grab it as a <a href="https://github.com/boughtonp/qpscanner/zipball/v0.7.5">zip archive</a> from the <a href="https://github.com/boughtonp/qpscanner/tags">GitHub tags page</a>.</p>
<p>For any feedback, problems, or questions, please use the <a href="https://github.com/boughtonp/qpscanner/issues">issue tracker</a>.</p>
https://www.sorcerers-tower.net/articles/apache,_cpanel_and_errordocumentApache, cPanel and ErrorDocument2012-11-08T01:49:00Z2012-11-08T01:49:00Z<p>If you're using a <a href="http://www.cpanel.net/">cPanel</a>-powered <a href="http://httpd.apache.org">Apache</a> server, there's a chance it
may not be setup in the best way.</p>
<p>The same issue might manifest itself in two ways: confusing error messages and
ignored htaccess directives.</p>
<p>In both cases, the solution is to use the <a href="http://httpd.apache.org/docs/current/mod/core.html#ErrorDocument">ErrorDocument</a> directive.</p>
<p><a href="https://www.sorcerers-tower.net/articles/apache,_cpanel_and_errordocument">Find out more</a>.</p>
https://www.sorcerers-tower.net/articles/happy_regex_day_2012Happy Regex Day 2012!2012-06-01T23:42:00Z2012-06-01T23:42:00Z
<p>Today was the 1st June, and that means it's Regex Day again!</p>
<p>This annual event was started four years ago by <a href="http://www.bennadel.com/about/about-ben-nadel.htm">Ben Nadel</a> to celebrate this wonderful (yet often misunderstood) technology, and as usual Ben is running <a href="http://www.bennadel.com/blog/2383-The-5th-Annual-Regular-Expression-Day-And-Prizes-June-1st-2012.htm">a fun regex competition, with prizes, on his blog</a>.</p>
<p>If that's not enough regex goodness for you, here's a couple of projects you should know about.</p>
<p>First up, there's <strong><a href="http://xregexp.com/">XRegExp</a></strong>, a library by <a href="http://blog.stevenlevithan.com/about">Steven Levithan</a> which augments JavaScript's native regex functionality with new functionality, and ensures cross-browser compatibility.</p>
<p>For CFML developers, there's <strong><a href="http://cfregex.net">cfRegex</a></strong> a replacement regex implemenation providing more power and functionality than CFML's native functions, whilst being easier to work with.</p>
<p>Whatever your level of regex skill, both of these tools are definitely worth checking out.</p>https://www.sorcerers-tower.net/articles/queryparam_scanner_0-7-5_release_candidateQueryParam Scanner 0.7.5 Release Candidate2012-01-07T20:59:00Z2012-01-07T20:59:00Z<p>I have just pushed an update of QueryParam Scanner to <a href="https://github.com/boughtonp/qpscanner">GitHub</a>, containing
various improvements.</p>
<p>This update is on the <a href="https://github.com/boughtonp/qpscanner/tree/rc0.7.5">rc0.7.5 branch</a>, and it'd be nice if people could
take it for a spin and make sure there are no issues with it. (There is a
<a href="https://github.com/boughtonp/qpscanner/zipball/rc0.7.5">zip download</a> for anyone without git.)</p>
<p>The visible changes which you might notice are:</p>
<ul>
<li>Added JSON output format, giving an alternative to XML for anyone using
qpscanner in a scripted process.</li>
<li>Added variable for number of potential risk files, and improved related
wording in HTML output.</li>
<li>Fixed bug where identical queries were causing incorrect line numbers.</li>
<li>Fixed bug where query names were not being detected.</li>
<li>Fixed bug where blank lines were incorrectly removed.</li>
</ul>
<p>However, there are also significant under-the-hood changes. I removed my
obsolete "Java Regex Utils" library (replacing it with the object part of
<a href="http://cfregex.net">cfRegex</a>), and made a number of little code clean-ups.</p>
<p>A result of these changes is that qpscanner rc0.7.5 appears to be almost twice
as fast as previous versions.</p>
<p>If you have any feedback, please feel free to <a href="https://github.com/inbox/new/boughtonp">contact me via GitHub</a>,
and similarly if you find any bugs then please raise them on the <a href="https://github.com/boughtonp/qpscanner/issues">issue tracker</a>.</p>
https://www.sorcerers-tower.net/articles/why_railo_3-3Why Railo 3.3?2011-11-06T23:54:00Z2011-11-06T23:54:00Z<p>It's been over two and a half years since my last "why railo" post, and -
despite <a href="http://www.getrailo.org">Railo</a> "only" being 0.3 versions on - there's
been a lot of improvements!</p>
<p>In fact, because it's been so long, a few of the things here are not new with
v3.3 (though they are all new since the <a href="/articles/why_railo_3.html">previous article</a>),
but are still great features that deserve mentioning!</p>
<p><a href="https://www.sorcerers-tower.net/articles/why_railo_3-3">Read on to find out what my ten favourite new feature are</a>.</p>
https://www.sorcerers-tower.net/articles/cfml_on_wikipediaCFML on Wikipedia2011-10-02T22:08:00Z2011-10-02T22:08:00Z
<p>If you've ever looked at the CFML related articles on Wikipedia, you can't fail
to have noticed that, especially when compared to other programming articles,
they're not very good.
<p>When somebody puts "coldfusion" or "cfml" into Google, they will almost
certainly see the respective Wikipedia pages amongst the top three results, but
when they follow those links they're unlikely to get a very good impression!
<p>Not only could both these pages themselves benefit significantly from being
cleaned up and improved, but there are only a few frameworks and tools that even
have pages, and most of what does exist are very unencyclopaedic stubs. And this
doesn't even consider the generic programming pages that often don't even mention CFML.
<p>Take a look at the <a href="http://en.wikipedia.org/wiki/Category:CFML_programming_language">CFML category page</a>
- does that category contain everything you would expect an encyclopaedia to
cover about CFML? Check the pages for the frameworks you are familiar with - do
they go into the level of detail you would expect, and tell you everything you'd
want to know if you were entirely new to CFML?
<p>If you agree that the CFML presence on Wikipedia can and should be improved,
and it's up to the CFML community to do it, then
<a href="https://www.sorcerers-tower.net/articles/cfml_on_wikipedia">read on to find out how you can help fix it</a>.
https://www.sorcerers-tower.net/articles/introducing_the_cfregex_projectIntroducing the cfRegex Project!2011-07-22T22:20:00Z2011-07-22T22:20:00Z
<p>The <a href="http://cfregex.net">cfRegex project</a> is two things. Firstly, it is a complete regex implementation
for CFML, providing more functionality, flexibility, features and power than the
existing CFML RE functions. Secondly, it is a drive to encourage people to
properly learn and make use of regex.
<p>Regex is a very flexible language for matching patterns within text, and it has
the power to greatly simplify certain programming tasks. However, it can also be
intimidating to people not experienced with it.
<p>This problem can be compounded by the relatively limited support for regex in
CFML, which often means code is written that is more complex than should be
necessary.
<p>cfRegex helps to address both these problems. It provides a number of functions
and features that help to reduce the amount of code which programmers have to
write, whilst also helping to make their code clearer and easier to understand.
In addition, the project provides documentation, not just for its own features,
but also for regex itself, helping people to understand exactly what their
expressions are matching, and how to get the most out of regex.
<p>Whilst cfRegex is still at a relatively early stage, it is currently usable, and
if you're a fan of regex it is certainly worth checking out.
<p>It currently runs on CF 9.0.1, OpenBD 2.0, Railo 3.2 and later.<br/>
<small>(Support for CF8 and others will be considered if enough people need it.)</small>
<p>The <a href="http://docs.cfregex.net/">documentation</a> should tell you everything you need to know about using it,
but if not then get it touch and say what's missing so it can be fixed!
<p>If you get stuck, there's a <a href="http://cfregex.net/discussion.html">mailing list</a> where you can receive answers to any
problems or questions you have.</p>https://www.sorcerers-tower.net/articles/international_regular_expressions_day_2010International Regular Expressions Day 20102010-06-01T14:20:00Z2010-06-01T14:20:00Z
<p>It's 1st June 2010 today, and that means we're celebrating for the third time the annual International Regular Expressions Day.</p>
<p><a href="http://www.bennadel.com">Ben Nadel</a> kicked off this event two years ago, in order to promote the use of Regex, especially amongst those who might consider them something scary and obscure.</p>
<p>As before, Ben is running a contest, this year's prizes being some O'Reily Regex books and IIS Mod-Rewrite Pro licenses.</p>
<p>Entry to the competition requires writing some code, and the deadline is today, so if you're interested then hurry up and
<a href="http://www.bennadel.com/blog/1923-3rd-Annual-Inter-National-Regular-Expression-Day-And-Prizes-June-1st-2010.htm">read Ben's blog entry to find out more</a>.</p>
<br/>
<p style="text-align:center"><big><a href="http://www.regular-expression-day.com/">Happy Regex Day!</a></big></p>
<br/>
https://www.sorcerers-tower.net/articles/railo_still_awesomeRailo: Still Awesome!2010-01-26T21:42:00Z2010-01-26T21:42:00Z
<p>It's nearly a year on from my last Railo blog post so it is well overdue that I write another - just in case there is anyone still sitting on the fence, unsure if they should use Railo - or indeed, anyone who might be unaware of Railo's very existance!</p>
<br/>
<p>So to start with, a quick summary of what <a href="http://www.getrailo.com">Railo</a> is:</p>
<ul>
<li>Railo, <a href="http://www.youtube.com/watch?v=d1QKOHThSiM#t=0m10s" title="(sounds like 'silo')">pronounced /ˈraɪ.ləʊ/</a>, is super fast Enterprise-level sofware for RAD webapp and website creation.</li>
<li>Railo is LGPL-licensed <a href="http://www.gnu.org/philosophy/free-sw.html">Free Software</a>, so anyone can use it how they like.</li>
<li>Railo runs on any <a href="http://java.sun.com/javaee/">Java EE</a> server, (but doesn't require Java knowledge), and is a <a href="http://www.jboss.org/">Jboss.org</a> project.</li>
<li>Railo uses the <a href="http://www.opencfml.org">CFML language</a>, like <a href="http://www.adobe.com/coldfusion">Adobe ColdFusion</a> (the primary CFML engine), <a href="http://www.openbluedragon.org">OpenBlueDragon</a>, and others.</li>
<li>Railo is really awesome.</li>
</ul>
<p><strong><a href="/articles/railo_still_awesome">Find out why Railo is the perfect choice for your next development project.</a></strong>
https://www.sorcerers-tower.net/articles/beehive_forum_0-9_has_been_releasedBeehive Forum 0.9 has been released!2009-07-06T23:50:00Z2009-07-06T23:50:00Z
<p>Version 0.9 of <a href="http://www.beehiveforum.net">Beehive Forum</a>, probably the greatest forum software there is, has recently been officially released.</p>
<p>Since the previous v0.8.4 there have been a variety of fixes and improvements, particularly to client-side caching and UTF-8.
There is also now support for Google Analytics and for displaying optional Google Adsense adverts. For full information on what has changed, you can check the <a href="https://sourceforge.net/project/shownotes.php?group_id=50772&release_id=694880">release notes</a>.</p>
<br/>
<p style="text-align:center"><strong><a href="https://sourceforge.net/projects/beehiveforum/files/">Download Beehive Forum 0.9 from SourceForge</a></strong></p>
<br/>
<p>Also, Beehive is currently a Finalist in the SourceForge Community Choice Awards!</p>
<p>If you're a fan of Beehive and haven't yet voted, please vote for Beehive now.</p>
</a>
</div>
<p>There is a lot of competition, with many thousands of votes already having been cast, so please help spread the word to as many other Beehive users as you can, to help vote for Beehive to win, and gain the recognition it deserves!</p>
<br/>https://www.sorcerers-tower.net/articles/java_regex_utilities_v0-7_previewJava RegEx Utilities - v0.7 preview2009-04-09T21:47:00Z2009-04-09T21:47:00Z
<p><a href="http://www.hybridchill.com/projects/jre-utils.html">Java RegEx Utilities</a>, or jre-utils, is a CFC which provides a convenient way to access <a href="http://www.java.com">Java</a>'s <a href="http://www.regular-expressions.info/">regular expression</a> functionality.</p>
<p>Whilst <a href="http://www.adobe.com/coldfusion">ColdFusion</a>, <a href="http://www.getrailo.com">Railo</a>, and <a href="http://www.openbluedragon.org">openBD</a> are all built on Java, and <a href="http://www.opencfml.org">CFML</a> does have regular expression functions, they do not actually use the Java regular expression engine, which supports many useful regex constructs.</p>
<p>The purpose of jre-utils is to provide this extra power to CFML developers in a familiar and easy to use way.</p>
<p>I will shortly be releasing v0.7 of jre-utils, which adds a number of new functions, as well as making things more consistent, so I decided I would give this quick preview of what it contains.</p>
https://www.sorcerers-tower.net/articles/open_source_railoOpen Source Railo2009-03-31T21:03:00Z2009-03-31T21:03:00Z
<p>Earlier today, the eagely awaited Railo 3.1 public beta was announced!</p>
<p>And the reason for much of this eagerness?</p>
<p><strong>Railo is now <a href="http://www.opensource.org/">Open Source</a> and <a href="http://www.gnu.org/philosophy/free-sw.html">Free Software</a></strong>, released under the LGPL v2.</p>
<p>This license requires that any changes to Railo's sourcecode itself must also be released under LGPL v2 (or later version).</p>
<p>However, unlike the full GPL, it does not require that you release any packaged applications under a compatible license - so you can still use whatever license you like for your own CFML code, Open Source or otherwise.</p>
<p>Along with the announcement comes two new Railo websites: The commercial-oriented <a href="http://www.getrailo.com">getrailo.com</a> and the community-oriented <a href="http://www.getrailo.org">getrailo.org</a>, which also contains <a href="http://wiki.getrailo.org">wiki-based documentation</a>.</p>
<p>Details on updating this documentation, as well as information about the new features in Railo 3.1, will come later this week - stay tuned to the <a href="http://www.railo.ch/blog/">Railo blog</a> for the latest details.</p>
<p>The next four months are going to be a very exciting time for Railo and CFML!</p>https://www.sorcerers-tower.net/articles/why_railo_3Why Railo 3?2009-03-01T02:53:00Z2009-03-01T02:53:00Z
<p>It's been nearly half a year since Railo 3 was released, and with 3.1 just around the corner it is a good time to write a post about some of the features that continue to make Railo such an excellent CFML engine!</p>
<p>This blog entry covers things new to Railo 3 - however, if you've not looked at Railo before, you should also look at my previous postings, as they are still valid:</p>
<a href="https://www.sorcerers-tower.net/articles/why_railo_3"><p>This blog entry gives ten reasons for using Railo 3...</a>
https://www.sorcerers-tower.net/articles/switch_on_string_in_javaSwitch on String in Java2008-12-12T21:50:00Z2008-12-12T21:50:00Z
<p>For anyone working with any other modern language, (such as CFML, C#, JavaScript, Ruby, and more), using a String within a switch-case statement is not an issue, and probably something you've done many times without thinking about.</p>
<p>However, when working in Java you cannot use strings in a switch statement.</p>
<p>Fortunately, despite what many sites suggest,
<a href="https://www.sorcerers-tower.net/articles/switch_on_string_in_java">there is a solution</a>.
https://www.sorcerers-tower.net/articles/creating_my_very_first_eclipse_pluginCreating my very first Eclipse Plugin2008-09-23T00:10:00Z2008-09-23T00:10:00Z
<p>I recently* completed my very first Eclipse Plugin, and I found the whole experience to be very interesting.<br/>
<small class="a">*(well about a month ago; took me longer to get writing this than intended)</small></p>
<p>This blog entry will focus on two main areas - my experience with Eclipse (as opposed to CFEclipse and similar), and the issues I encountered from a development perspective</p>
<p><a href="https://www.sorcerers-tower.net/articles/creating_my_very_first_eclipse_plugin">Read on to find out about it</a>.
https://www.sorcerers-tower.net/articles/railo_3-0_releasedRailo 3.0 released!2008-09-09T19:08:00Z2008-09-09T19:08:00Z
<p>The long awaited Railo 3.0 is out of Beta and available to all.</p>
<p>There are a lot of exciting new features with Railo 3.0: multimedia video conversion and manipulation, video player with playlisting, task manager, cluster scope, CF8 compatibility, and more.</p>
<p>Also, with Railo 3.0, the Community and Professional versions have been combined - keeping the price of the Community edition (i.e free), but without the previous restrictions this had. (With Railo 3.1 due later this year, Railo will fully become <a href="http://www.gnu.org/philosophy/free-sw.html">Free Software</a>, under the LGPL2 license.)</p>
<p>For more details, the best place to head is the rebrushed <a href="http://www.railo.ch/en/">Railo website</a>, which has been updated to provide information on <a href="http://railo3.railo.ch/en/index.cfm?treeID=353">what is new with Railo 3.0</a>.</p>
<p>There will also be a three part series on the <a href="http://www.railo.ch/blog">Railo blog</a> covering the new features. The <a href="http://www.railo.ch/blog/index.cfm/2008/9/9/Railo-30-released--Features-part-1">first entry in the series</a> is already available.</p>https://www.sorcerers-tower.net/articles/beyond_tables_beyond_divs_simple_javascript_calculator_iiiBeyond Tables, Beyond Divs - Simple JavaScript Calculator III2008-08-30T18:32:00Z2008-08-30T18:32:00Z
<p>As we (hopefully) all know, using HTML tables for layout is Bad and Wrong.</p>
<p>Unfortunately, the most common way people avoid using tables is to just
replace their table, tr and td tags with divs, divs and more divs.</p>
<p>The div tag is a generic container that should be used as a <em>last resort</em>,
if there are no other more suitable options.</p>
<p>Whilst the problem of excess divs is not limited to the conversion of table
layouts, it is perhaps most obvious here, as it shows the developer is still
stuck in the column+row frame of mind, rather than thinking about what they
are actually displaying.</p>
<p><a href="https://www.sorcerers-tower.net/articles/beyond_tables_beyond_divs_simple_javascript_calculator_iii">In this blog entry, I show an
example of how avoiding this mindset can result in much simpler and cleaner
code</a>.
https://www.sorcerers-tower.net/articles/queryparam_scanner_eclipse_pluginQueryParam Scanner - Eclipse Plugin2008-08-25T23:24:00Z2008-08-25T23:24:00Z
<p>The first pre-release version of the qpScanner Eclipse Plugin is now available.</p>
<p>This is the very first Eclipse plugin I have created. It was an interesting
experience, and something that I will be writing up in a separate entry as soon
as I can collect my thoughts.</p>
<p>It order to use the plugin, you must be using v0.7 or higher of qpScanner -
if you do not yet have this, you can download the
<a href="https://github.com/boughtonp/qpscanner/zipball/develop">latest
development version of qpScanner</a>, which contains details of the Update Site
to use. If for any reason you cannot use the regular Eclipse Update method, you
can directly <a href="http://eclipse.hybridchill.com/plugins/hybridchill.eclipse.qpscanner_0.1.0.0.jar">download the qpScanner Eclipse Plugin</a> instead.</p>
<p>Just to be clear, both v0.7 of QueryParam Scanner and v0.1 of the qpScanner
Eclipse Plugin are currently considered development releases, and are being made
available so that they can be tested and any bugs that might exist can be found
- if you are unwilling to use pre-release software you should wait until the
official release.</p>
<p>If you do get the Eclipse Plugin, or even just qpScanner on its own, I
welcome any and all feedback you might have - whether to report bugs you have
found, request new features you would like, or simply to let me know that works
with your local setup.</p>
<p>Please send feedback via the <a href="https://github.com/boughtonp/qpscanner/issues">GitHub Issue system</a>.
<br/>
<p>Related websites:</p>
<ul class="compact">
<li><a href="//www.sorcerersisle.com/projects:qpscanner.html">QueryParam Scanner official website</a></li>
<li><a href="http://qpscanner.riaforge.org">QueryParam Scanner project page at RIAForge</a></li>
<li><a href="https://github.com/boughtonp/qpscanner">QueryParam Scanner project page at GitHub</a></li>
</ul>https://www.sorcerers-tower.net/articles/queryparam_scanner_v0-7_devQueryParam Scanner v0.7-dev2008-08-17T00:01:00Z2008-08-17T00:01:00Z
<p>The latest development version of qpScanner is now in SVN at <a href="http://qpscanner.riaforge.org/">RIAForge</a>.</p>
<p>It would be great if people could test it out and let me know of any issues they encounter.</p>
<p>As before, it is all self-contained, so it can be installed and run with minimal effort.</p>
<p><strong>Note:</strong> As this is still the development version, you need to use the zip option at the bottom of the RIAForge page, <em>not</em> the "Download Project" link - the button will only give the old version.</p>
<p>When released, v0.7 will be a significant new version,
so I want to give <a href="https://www.sorcerers-tower.net/articles/queryparam_scanner_v0-7_dev">a quick discussion of the new features</a>...
https://www.sorcerers-tower.net/articles/expandpath_bug_in_cf8expandPath bug in CF82008-08-16T17:23:00Z2008-08-16T17:23:00Z
<p>I've just encountered a very annoying bug with the expandPath function in CF8.</p>
<p>Take the following code:</p>
<pre><code><cfset MyDir = "."/>
<cfloop index="i" from="1" to="5">
<cfset MyDir = expandPath(MyDir)/>
<cfoutput><br/>#MyDir#</cfoutput>
</cfloop></code></pre>
<p>Run the code through Railo and you will get exactly the right behaviour, with the current directory output five times:</p>
<pre><code>C:\dev\scratch
C:\dev\scratch
C:\dev\scratch
C:\dev\scratch
C:\dev\scratch</code></pre>
<p>Now go run the same code with CF8 - and this is what you get:</p>
<pre><code>F:\ColdFusion8\wwwroot\scratch
F:\ColdFusion8\wwwroot\scratch\F:\ColdFusion8\wwwroot\scratch
F:\ColdFusion8\wwwroot\scratch\F:\ColdFusion8\wwwroot\scratch\F:\ColdFusion8\wwwroot\scratch
F:\ColdFusion8\wwwroot\scratch\F:\ColdFusion8\wwwroot\scratch\F:\ColdFusion8\wwwroot\scratch\F:\ColdFusion8\wwwroot\scratch
F:\ColdFusion8\wwwroot\scratch\F:\ColdFusion8\wwwroot\scratch\F:\ColdFusion8\wwwroot\scratch\F:\ColdFusion8\wwwroot\scratch\F:\ColdFusion8\wwwroot\scratch</code></pre>
<p>It simply stacks the current directory onto the front each time. Very frustrating.</p>
<br/>
<p>In order to get round this, I created a regular expression to pull off the last value of any directory containing more than one colon - this will work for Windows machines, but may need to be changed for Linux or MacOSX machines (if the bug affects these).</p>
<pre><code><cfif isDefined('Server.ColdFusion.ProductName')
AND Server.ColdFusion.ProductName EQ 'ColdFusion Server'
AND ListLen( MyDir ,':') GT 2>
<cfset MyDir = REreplace( MyDir , "^.*([A-Z]:[^:]+)$" , "\1" )/>
</cfif></code></pre>https://www.sorcerers-tower.net/articles/railo_goes_open_source_with_jboss-org_updateRailo goes Open Source with JBoss.org (Update)2008-06-08T17:59:00Z2008-06-08T17:59:00Z
<p>As promised previously,
<a href="https://www.sorcerers-tower.net/articles/railo_goes_open_source_with_jboss-org_update">here is a more detailed entry</a> on the announcement to Open Source the Railo CFML engine.
https://www.sorcerers-tower.net/articles/scotch_on_the_rocks_2008Scotch on the Rocks 20082008-06-06T22:57:00Z2008-06-06T22:57:00Z
<p>Scotch on the Rocks 2008 is now unfortunately ended,
<a href="https://www.sorcerers-tower.net/articles/scotch_on_the_rocks_2008">read on</a> to see my thoughts.
https://www.sorcerers-tower.net/articles/railo_goes_open_source_with_jboss-orgRailo goes Open Source with JBoss.org2008-06-05T17:30:00Z2008-06-05T17:30:00Z
<p>Today at the midday Scotch keynote, Gert Franz and Luc Texier made an impressive announcement: <strong>Railo is going completely Open Source.</strong></p>
<br/>
<p>This is an exciting move both for Railo and for the CFML community as a whole, and I'll be writing more details about it later, but for now here some some quick key details...</p>
<p>There will be two editions of Railo, with the Community and Professional editions combining into one, and the Enterprise edition being the other:</p>
<p>The new Community+Professional edition will be Open Source and there will be no limit to the number of web contexts allowed.</p>
<p>The Enterprise edition will have added value features, including tools from Intergral.</p>
<br/>
<p>The license will be LGPL2, which means you can distribute Railo along with commercial software.</p>
<p>The timeline for release of the source code is mid to late October, around the time that Railo 3.1 is due for release.</p>
<p>The announcement is online at the JBoss website at <a href="http://www.jboss.org/railo">www.jboss.org/railo</a></p>
<br/>
<p><strong>More Information available:</strong> <a href="/articles/railo_goes_open_source_with_jboss-org_update">Railo goes Open Source with JBoss.org (Update)</a></p>https://www.sorcerers-tower.net/articles/international_regular_expressions_dayInternational Regular Expressions Day!2008-06-01T14:48:00Z2008-06-01T14:48:00Z
<p>Today, 1st June 2008, has been officially decreed as Regular Expressions Day.</p>
<p>And in honour of this event, there are a couple of regex-oriented competitions happening.</p>
<p>Ben Nadel, nominator of this great day, kicked things off with a handful of prizes for the best comments:
<a href="http://bennadel.com/index.cfm?dax=blog:1243.view">June 1st 2008 - National Regular Expression Day!</a></p>
<p>The deadline for Ben's competition is today - that is, you must post the comment on (or before) RegExp Day, and the winners will be selected tomorrow.</p>
<p>Don't despair if you miss that though, as Steve Levithan also has a regular expression competition running, and the deadline for that is Friday 13th, almost two weeks from now:
<a href="http://blog.stevenlevithan.com/archives/regexday-2008">Regex Day Contest</a></p>
<p class="c">Happy RegEx Day!</p>https://www.sorcerers-tower.net/articles/queryparam_scannerQueryParam Scanner2008-04-06T17:42:00Z2008-04-06T17:42:00Z
<p>The code for my <a href="http://qpscanner.riaforge.org">QueryParam Scanner</a>
has been uploaded to <a href="http://www.riaforge.org">RIAForge</a>.</p>
<p>QueryParam Scanner is a simple tool which scans your code for queries and
reports back about any variables that are not inside <code><cfqueryparam/></code> tags.</p>
<p><a href="http://qpscanner.riaforge.org/index.cfm?event=action.download">Download QueryParam Scanner from RIAForge</a>.</p>https://www.sorcerers-tower.net/articles/java_regex_utilitiesJava RegEx Utilities2008-04-05T23:30:00Z2008-04-05T23:30:00Z
<p>I have just released <a href="http://jreutils.riaforge.org">Java RegEx Utilities</a> on <a href="http://www.riaforge.org">RIAForge</a>, which is a CFC enabling easy access to Java Regular Expression functionality, adding to what is available in the standard CFML functions.</p>
<p>Currently there are two main functions.</p>
<p><code>jre.<b>get</b>(Text,RegEx)</code> returns the matches to the regular expression as an array.</p>
<p><code>jre.<b>replace</b>(Text,RegEx,Replacement)</code> is similar to REReplace, but the Replacement argument can be a function pointer, allowing you to process the results of a regex match with a function</p>
<p>You can find more usage details on the <a href="http://jreutils.riaforge.org/wiki/">jre-utils wiki</a>, which I plan to update with some examples of when each of these functions can be useful.</p>
<p>I have tested jre-utils against Railo 2 and CFMX 7, but it should also work with ColdFusion 8 and the Java version of BlueDragon - if anyone can test/confirm this please let me know.</p>
<p><a href="http://jreutils.riaforge.org/index.cfm?event=action.download">Download Java RegEx Utilities from RIAForge</a>.</p>https://www.sorcerers-tower.net/articles/javascript_leap_year_checkJavaScript Leap Year check2008-02-22T11:32:00Z2008-02-22T11:32:00Z
<p>I've just needed to fix a calendar that didn't implement leap years, and thus was missing 29th Feb this year.</p>
<p>Unfortunately, Google was bringing up various functions that rely on how browsers handle oddities in the built-in date functions, which isn't a sensible approach.</p>
<br/>
<p>So, here is how to do it relying on the leap year formula:</p>
<pre><code>function isLeapYear(year)
{return ((year%4 == 0) && (year%100 != 0 || year%400 == 0));}</code></pre>
<br/>
<p>And to implement that:</p>
<pre><code>function readDaysInMonth(month,year)
{
if (month == 1 && isLeapYear(year) == true) return 29;
else return [31,28,31,30,31,30,31,31,30,31,30,31][month];
}</code></pre>
<p><small class="a">(Remember, in JS months are 0-indexed, hence 1 = Feb)</small></p>https://www.sorcerers-tower.net/articles/fusebox_5-5_is_out_nowFusebox 5.5 is out now!2007-12-03T23:44:00Z2007-12-03T23:44:00Z
<p>The highly anticapted next major version of Fusebox has finally been <a href="http://www.fusebox.org/index.cfm?objectID=A13FA6AA-C448-15CC-1FEFB38ABEA2EC82">released to the website</a>.</p>
<p>Fusebox 5.5 allows you to use the Fusebox applications without using XML, which should please many people.</p>
<p>Instead of fusebox.xml it checks conventional places for your circuits, and instead of circuit.xml it can either use CFCs, where each function is a fuseaction, or just a directory, where each file is a fuseaction.</p>
<p>It also brings support for dynamic do to both xml and non-xml configuration, which is a feature I've really wanted on a couple of occasions.</p>
<p>Get it while it's hot...</p>
<p><a href="http://fusebox.org/go/fusebox-downloads/core-files">http://fusebox.org/go/fusebox-downloads/core-files</a>
https://www.sorcerers-tower.net/articles/beehive_forum_0-8_out_nowBeehive Forum 0.8 out now!2007-11-28T23:11:00Z2007-11-28T23:11:00Z
<p>The newest version of Beehive Forum has been released today, with a large selection of new features, improvements, and fixes.</p>
<p><strong>It is very much recommended that users of previous versions upgrade to the latest version without delay</strong> - upgrade paths are available from both 0.6.* and 0.7.* so there is no excuse!</p>
<p>For those not familiar with Beehive, it is a superb free and open-source discussion forum system which (in addition to its superior interface) exhibits several rare and unique features which make it a joy to use. For example: there is a relationship system which allows you to ignore others users, or their signatures, or give them amusing nicknames that only you see; each user also has an individiual word filter, with a regular expression option for very powerful filtering; there's a flexible polling system with groupable options, public/private ballot, fixed/changable votes; and many other cool things.</p>
<p>To learn more you can look at the <a href="http://www.beehiveforum.net/">Beehive website</a>, or you can go straight to the <a href="http://sourceforge.net/projects/beehiveforum/">SourceForge project page</a> to download it now.</p>https://www.sorcerers-tower.net/articles/railo_2-0_out_nowRailo 2.0 out now!2007-08-29T00:48:00Z2007-08-29T00:48:00Z
<p>The final release of Railo 2.0 is now available for download from the re-vamped <a href="http://railo.ch/en">Railo website</a>.</p>
<p>If you've already tried Railo, you'll probably be wanting to head straight to <a href="http://www.railo.ch/en/index.cfm?treeID=224">the download page</a>.</p>
<p>If you want to know more about what Railo is and why you might be interested,
<a href="https://www.sorcerers-tower.net/articles/railo_2-0_out_now">read on...</a>
https://www.sorcerers-tower.net/articles/why_railo_2Why Railo 2?2007-06-06T21:58:00Z2007-06-06T21:58:00Z
<p>A while ago I wrote an entry about why people should consider Railo. Well,
with the Release Candidate for version 2.0, there comes a lot more reasons
for using Railo.
<a href="https://www.sorcerers-tower.net/articles/why_railo_2">And here are twenty of them...</a>
https://www.sorcerers-tower.net/articles/why_railoWhy Railo?2007-02-07T21:36:00Z2007-02-07T21:36:00Z
<p>In the near future I'll be getting myself a dedicated server, and decided to
find out if anyone would be interested if I was to setup Railo hosting on
it. So, I posted on the CF-Talk mailing list to see if anyone was
interested, and <em>crikey</em>, what a reaction I got! The discussion is
currently the longest in the past four dozen threads.
<p>The first few replies basically boiled down to was "why would anyone want
Railo hosting?!?".</p>
<p>Tempting as it is to reply with <i>"Railo PWNS U l4m3rz!"</i>, I've decided
that I'll instead explain why <em>I</em> choose Railo, over all the other CFML
engines available (CFMX, BlueDragon and Smith being the significant
alternatives).
<p>However, to prevent me from rambling on for hours about how wonderful Railo
is -- and I really could talk about it all day -- I am simply going to pick
just five things that should help to show what attracts me to Railo.
<p><a href="https://www.sorcerers-tower.net/articles/why_railo">Read on</a>.
https://www.sorcerers-tower.net/articles/railo_1-1_betaRailo 1.1 Beta2007-01-01T21:04:00Z2007-01-01T21:04:00Z
<p>The latest version of Railo is now available as a public beta from the
<a href="http://www.railo.ch/en/index.cfm?treeID=159">Railo customer center</a>,
and it brings with it an exciting new feature: Resources.</p>
<p>Resources are a brilliant feature that allows you to perform file actions on
virtual filesystems such as in memory, ZIP archives, and FTP sites.</p>
<p><a href="https://www.sorcerers-tower.net/articles/railo_1-1_beta">Read on to find out more</a>.
https://www.sorcerers-tower.net/articles/cfdevcon_2006cfDevCon 20062006-11-09T22:49:00Z2006-11-09T22:49:00Z
<p>Okay, so I've arrived back from <a href="http://www.cfdevcon.com">the UK's first* ColdFusion developers' conference</a> (*if you ignore the previous two UK-based CF conferences), and decided I would give
<a href="https://www.sorcerers-tower.net/articles/cfdevcon_2006">my thoughts about it</a>.
https://www.sorcerers-tower.net/articles/link_lexicon_verb_for_fusebox_5Link lexicon verb for Fusebox 52006-11-08T17:54:00Z2006-11-08T17:54:00Z
<p>I have created a simple custom verb which allows you to link specified resource files from circuit.xml, without having to go to the bother of writing it all in a script and including it.</p>
<p>For example, you can do this:</p>
<pre><code><cf:link resource="/res/bubbles.css"/><br/><cf:link resource="/res/bubbles.js"/></code></pre>
<p>And it will convert that and place the following inside your HTML head:</p>
<pre><code><link rel="stylesheet" type="text/css" href="/res/bubbles.css"/><br/><script type="text/javascript" src="/res/bubbles.js"></script></code></pre>
<p>This should be useful if you have a lot of different circuits that all have unique styles and scripts, and you'd rather avoid putting lots of conditional statements in your layout pages.</p>
<p>For more information and a download link, <a href="https://www.sorcerers-tower.net/articles/link_lexicon_verb_for_fusebox_5">read the article</a>.
https://www.sorcerers-tower.net/articles/accessibility_is_not_cssAccessibility Is Not CSS!2006-09-15T21:05:00Z2006-09-15T21:05:00Z
<p>The biggest barrier to creating an accessible Internet is not browser support
or badly designed syntax, but rather people's false beliefs of what
accessibility is; what it means to 'be accessible'. For many people, being
accessible means switching from <var>font</var> tags to <abbr>CSS</abbr>,
using <var>em</var> tags for italics, and replacing <var>table</var>s with
<var>div</var>s. <em>THAT IS NOT ACCESSIBILITY!</em></p>
<p><a href="https://www.sorcerers-tower.net/articles/accessibility_is_not_css">Read on to find out more</a>.
https://www.sorcerers-tower.net/articles/railoRailo2006-07-17T19:31:00Z2006-07-17T19:31:00Z
<p>Railo is the best CFML engine.</p>
<p>I guess you'll be wanting me to validate that statement? Well I'll make a start on that in a moment, but first I think I'll post a few disclaimers to pre-empt any potential whiney people.</p>
<p>I have nothing against Adobe, NewAtlanta, CFMX, nor BlueDragon. They're both great companies/products - without the company formally known as Allaire, I'd never have had my life enriched by the joy that is ColdFusion - and BlueDragon is no doubt a fine product if you find yourself stuck using that .NET thing. ;)</p>
<p>But Railo is better than both of them, and here is why...</p>