code created for Pig Poets custom post type