This script is great. I appreciate the work you've put into it.
The only question I've got is whether it is feasible to have the same form used for a domain that also has aliases, without turning off domain checking?
I have a domain xyz.com that I have aliased via Apache to also reply to abc.com. With the way the php is currently set up, I don't see how to allow both domains to post a message, since I can only enter a single domain into the $domain variable. Since I've used the ServerAlias Directive in Apache, and used all relative linking on the sites, when a user comes in via abc.com, there is no redirect to xyz.com, all references are from abc.com for the duration of their visit. Therefore, if I have xyz.com listed in the script, and they come in on abc.com, they get the "Input Forbidden" error.
The obvious immediate workaround is to disable $domain_protect, but I'm wondering if an array could be used here without a large re-write of code. I'm no PHP programmer, but thought this might be an easy way to alleviate the problem.
Your thoughts?