0

I have recently taken over this company's website operations and I am trying to set up a page to house a certain type of post. The previous webmaster has already done this before but I can't figure out how to do it again.

Here is a picture to help describe what I'm trying to do. http://imgur.com/a/7TaWI

I want to make a sub-section of posts with the title reports/presentations the same way that it has past webinars, product links, and current webinars. Ideally, this reports/presentations piece will only be available to members. I just don't get how to do it, it's like they are a completely separate entity, not just a category of post, you can post inside of those areas without your post showing up on the overall posts menu.

  • Those are custom post types, but you'll need to clarify some more, e.g. by members do you mean logged in users? Or are you referring to a membership plugin? Do you mean only available to members on the frontend? Only available in the admin screen? – Tom J Nowell Jul 25 '17 at 19:45
  • Members via membership plugin. I've got that all figured out and pretty much set up though I think. Some of our customers pay to be a member of the site, and they will be receiving this reports tab. – BondyeLwa Jul 26 '17 at 11:18
0

Create you own WP_query running on this post type out side the main loop.

$args = array('post_type' => 'cpt_name');
$cptq = new WP_query($args);
if($cptq->have_posts()):
while($cptq->have_posts()):$cptq->the_post();

the_title();

endwhile;
wp_reset_query();
endif;
  • I apologize for being a WP noob, but I can't quite figure out where to access this php file in order to put the code block you have provided into it. – BondyeLwa Jul 26 '17 at 11:27
  • you have a page template, we'll call it cpt-page.php the basic structur of a page is: – ido barnea Jul 26 '17 at 11:28
  • you have a page template, we'll call it cpt-page.php the basic structure of a page is: is this pastebin.com/j4BxhNEy, this is for cpt: pastebin.com/iGxNbLbK – ido barnea Jul 26 '17 at 11:36
  • Sorry, what is cpt? and this is what my template.php should look like? – BondyeLwa Jul 26 '17 at 11:58
  • cpt = custom post type. codex.wordpress.org/Post_Types – ido barnea Jul 26 '17 at 12:01

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.