How can I hide a wordpress post from direct traffic, but not from linked traffic?
May 14, 2010 2:23 PM   Subscribe

How can I hide a wordpress post from direct traffic, but not from linked traffic?

I have a certain post that I don't want to encourage people to find by scrolling through the site. However, there are some other sites linking to that post, and I want those links to continue to work.

Thoughts?
posted by bingo to Computers & Internet (4 answers total)
 
Change the post date to make it old? That will take it off the front page, but someone who goes burrowing for it will find it.

The only other thing I can think of would involve a fair amount of template hackery: basically, you'd give this post a special category, and set all your various template files to exclude that category—except for the single-post template. Then you'd need to make it so that the category itself is hidden from view. I'm pretty sure there are ways to do that, but they'd depend on what your template files already look like.
posted by adamrice at 2:33 PM on May 14, 2010


Perhaps this exclude post plugin might work for you?
posted by mireille at 2:42 PM on May 14, 2010


You can easily do this with a little bit of php in your template (like adamrice indicates: set a "hidden" category and then add query_posts(cat=-1)--or whatever the category's id is--just before The Loop).

Alternatively, it looks like there are plugins that might help you do this as well.
posted by maniactown at 2:43 PM on May 14, 2010


My thought was to find a plugin that would allow you to alter content based on where the user came from. I think you'd likely have to modify an existing plugin, although referrer based plugins do exist.
posted by davey_darling at 8:03 PM on May 14, 2010


« Older I'm not buying him socks!   |   Are there cheap and decent places to stay near OSU... Newer »
This thread is closed to new comments.