• 0
Sign in to follow this  
Followers 0

Custom Posts / Queries

Question

Posted · Report post

I'm tired of searching around. Maybe someone can save me sometime. Here is my dilemma. I have a XML Feed importing in as 'posts' with custom fields. I also have basic news articles as 'posts'. (default layout for blog) I need different custom layouts for the post and for queries. (Example: Credit Card post type/category will display custom fields in the queries and in it's single post) Should I do the custom layouts based on 'Post_Type' or a simpler solution of 'Category' based displays? Also, what would be the best solution for this? I'm more of a designer than programmer. I hope that make sense. Please help me! Thanks!

Share this post


Link to post
Share on other sites

2 answers to this question

  • 0

Posted · Report post

Could this be used in Pagelines 2+ ? [url]http://www.pagelines.com/forum/discussion/12961/pull-data-from-custom-fields-in-a-custom-post-type-template/p1[/url] [code]add_action('pagelines_loop_before_post_content', 'book_info'); function book_info(){ if( get_post_type() == 'books' ) { echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo "
Publisher / DeveloperAgePriceScore
"; echo do_shortcode('[ecpt_field id="publisher/developer"]'); echo ""; echo do_shortcode('[ecpt_field id="age"]'); echo ""; echo do_shortcode('[ecpt_field id="price"]'); echo ""; echo do_shortcode('[starreview tpl=16 post=% style="plain_green" size="16"]'); echo "
"; } }[/code]

Share this post


Link to post
Share on other sites
  • 0

Posted · Report post

I'm certain that code is for PlatformPro, not PageLines because the timestamp for that past is from August. It may work, though, since the hook (pagelines_loop_before_post_content) is still applicable in PageLines. This link may also be helpful: http://codex.wordpress.org/Function_Reference/do_shortcode

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0