To make things a bit quicker when using Phing on Windows use the following registry entry to create a right click option that integrates with Phing.
Phing is an awesome tool for automating things and I use it more and more for automating all kinds of different tasks. One of the tasks that I don't tend to do all that much is setting up a new local virtual host for Apache on my development machines. I know how to do it, but there is always something I forget to do, or a convention that I don't follow which means that I have to repeat myself at a later date to fix something I have missed.
DocBlox is the new defacto PHP class documentation generator. It was developed as an alternative to PHPDocumentor, but it looks as though it will replace it and become the new PHPDocumentor2. As a result I thought I would put together a quick tutorial on getting started.
This post assumes that you know what PHPDoc comments are and that you have a project that you want to generate API documentation for. To get started on PHPDoc take a look at the Wikipedia page on PHPDoc.
Many modern browsers now come with auto-complete functionality so that users can fill in their details quickly without having to type in their username and password every time they want to log on. This can be turned off by adding the attribute "autocomplete" to the form and password elements and setting its value to 'off'.
Every Drupal project I finish will usually have the same request at some point. This usually happens when the client tries to do a search that produces no results and sees the search hinting text about blue smurfs.
I recently built a Drupal site on an Apache server sertup and everything seemed fine until someone running IE8 tried to download a .docx file. For some reason IE8 insisted that this file was a .zip file and would open it as such, causing a bit of confusion as to what the problem was. I assumed that this was due to the mime type of the file not being set properly, but I decided to do a quick search to see if I could find anything to corroborate this. I thought it might be something odd that IE8 was doing as everything else was downloading the file perfectly.
Use the following rules in your Apache configuration (or your .htaccess file) to redirect all traffic from one domain to another. This also keeps the query string in place so that the user isn't just dumped to the homepage.
I'm always writing bits of script to test things out and I thought that I would start making a record of them in case I need them in the future. This is a little script that will loop through the contents of a text file and validate that a bunch of 301 redirects point to the place they are meant to point to. This script assumes that the redirects are already in place on the server, but this is what I was testing. Here the format of the redirects text file.
Drupal is capable of sending out a few different emails to users depending on different actions. The emails can be customised quite nicely with usernames, passwords, email addresses and other things by using a set of tokens. The password recovery email states that you can use the "!password" token to send the user their new password, but after a few tests I found that this token doesn't get replaced when the email is sent out.