I run a marketing company today… and it surprises me how many times I get questions from our partners about CAN-SPAM.

It’s 2011. The law was passed in December 2003. The FTC released “new rules” to clarify parts of the regulation in 2008. Lawyers that specialize in marketing should know the law… but sadly many of them still don’t know it that well… (can you say Google?)

So, just to set the record straight: CAN-SPAM does allow a marketer to use a P.O. Box in the unsubscribe footer in an email marketing message.

I have a “Contact Us” page on AggieCampusology.com and a “Share a Story” page, and in the default WordPress setups, Pages include the ability to post comments, just like a regular Post does. But that doesn’t make any sense on a “Contact Us” or “Share a Story” page, where users are already being presented forms to be filled out, and I was worried about users getting confused, so, I wanted to remove the comments section from those pages completely, if I could.

The solution is:

1. Create a custom page template.
2. Remove the “comments” code from that template.
3. Use the new Custom template for the pages you don’t want comments on.

Hopefully the following is a decent enough explanation, if you want to do the same yourself:

Copy the “page.php” file in your theme directory.

Call the new copy of “page.php” “custompage.php” or something similar.

*Note: all the above really does is duplicate the template called “loop-page.php” removing this code:<?php comments_template( '', true ); ?>
**Note: you can also just download the above code from here, if you’d like to see it a little more cleanly.

Save the “custompage.php” file.

Open the page you want the comments removed from in the WordPress Admin UI.

On the right under “Page Attributes” change the template from “Default Template” to “CustomPage”:

Click “Update” to save the new settings.

Check your new pages in a browser, to make sure everything works the way you want it (specifically that there are no longer “comments” at the bottom of your commentless pages!

If you want to read up more on creating your own page templates for WordPress, check the codex.

Oh, and sidebar here: I’m using TDO Mini Forms to power the “Share a Story” page on AggieCampusology.com, because I wanted a quick and easy way for users to submit entries, that will work with the publishing workflow that’s naturally included with WordPress, without making a user “register” or anything… seems to be working so far…

If you’re reading this site via RSS, I apologize for the multiple postings of my “daily links”. I saw the bug earlier this week and through it’d fix itself, but it hasn’t.

I just made a few changes to the site code to try and shut down the errant postings… The problem is I’m not 100% sure where the postings are coming from, so hopefully, I’ve squashed the bug. If not, I’ll try something different tomorrow.