Circumventing DNS Caching

During my recent host switch I ran into a bit of a problem. After I had moved my database and content to the new server and changed the name servers, requests were still be directed toward my old server. The reason for this is that my ISP had not yet updated their DNS record cache thereby causing requests to be directed to the old server. It typically takes several days for a domain to fully propagate; the amount of time it takes for changes to take effect for an individual depends on how often their ISP updates the DNS records… Read More

New Host

I’m in the process of moving this site from my awful shared host to a shiny new VPS. Expect downtime, errors, unexpected behavior, and sudden explosions… Read More | 1 Comment

Apparatus Update Preview

I’ve been making some progress on the next version of Apparatus. Along with some bug fixes there are a few new features. One new thing is the option to attach a database to allow for more advanced functionality. For now this includes something I’m calling examples generation, which allows you to store your code and output and allow others to view it. This is done without giving them access to the Apparatus interface. Apparatus can still operate in lite mode (without a database), but some features will not be available.

Also in the works is a new template… Read More

Hello World Nightmare

Traditionally, when someone is introduced to programming, the first block of code they write is the infamous “Hello World” program. Unless you’re dealing with some esoteric language this program usually consists of just a few or even a single line. There is one popular language out there where, in comparison, Hello World is a monster: Java. If you’re a Java coder you may not see it, especially if Java wasn’t your first language. Try to look at it from the perspective of a first timer: Read More

RosettaCodex

As someone who is already experienced with a few programming languages, learning new languages, frameworks, and platforms is a much different process from someone who has no background in programming. Obviously having written a ton of code make learning how to write different code much easier. Much of the documentation out there however does not seem to take advantage of this fact. Documentation for someone who is completely new to programming is the same as documentation for someone with years of experience. It might be easier for the experienced programmer to understand and utilize that documentation, but it is still… Read More

PHP Confirmation Emails

If you are implementing your own user management system you may want to ensure that emails associated with users’ accounts are valid. The most straightforward way of doing this is to send an email to this account and verify that the user received it. Obviously we don’t want to do this manually so the solution is to write a script that automates the process.

High Level Concept
What we will need to do is:

  1. Generate a confirmation code for our users are registration time
  2. Store that code and track which users are not yet confirmed
  3. Send an email

Apparatus (also Happy New Year!)

For a while now I’ve been working on a web-based PHP interpreter; an interface I can use to quickly test or develop code from my browser. Ultimately this resulted in Apparatus, an in-browser PHP read-evaulate-print loop. Give it a try: http://tinsology.net/scripts/apparatus/.

Note that this is currently a beta version. Any help with identifying bugs will be greatly appreciated.

P.S. Happy New Year!… Read More

PHP Iterators

If you’ve spent any significant amount of time coding in PHP you’re most likely familiar with PHP’s foreach loop syntax. In simple terms, a foreach loop is an easy way to iterate over the elements of an array. Chances are if you’re reading this you already know that. What you may not know, however, is that it is possible to iterate objects with a foreach loop. Assuming you have some collection class (an object that stores some number of elements in an organized manner) you can iterate over its elements just like you can the elements of an array… Read More | 1 Comment

A Supplement

I’ve just added a section about session management to Creating a Secure Login System the Right Way.

Check it out… Read More

Do Not Reply

Anyone who has ever had an email account is probably very familiar with the “Do not reply” email. They can take the form of notifications from your bank, reminders to pay a bill, a newsletter, or just plain spam. Generally the read a little something like:

Please do not reply to this email. This mailbox is not monitored and you will not
receive a response.

Usually this is followed by some instructions to follow if you have a question or concern. I imagine at some point in the history of automated emailers someone decided that they did not… Read More