Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8902461
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T01:37:09+00:00 2026-06-15T01:37:09+00:00

Hey guys so I am trying to have a loop run to get all

  • 0

Hey guys so I am trying to have a loop run to get all the post that are within a certain category on a page, for some reason nothing happens though?

Code :

<?php
/*
Template Name: djequip
*/

get_header(); ?>

        <div id="primary">

            <div id="content" role="main">

                <?php /*query_posts('test');uncategorized*/
                if ( have_posts() ) : while ( have_posts() ) : the_post(); 
                 get_template_part( 'content', get_post_format() ); 
                endwhile; endif; ?>

            </div><!-- #content -->
        </div><!-- #primary -->

<?php get_sidebar(); ?>
<?php get_footer(); ?>

Let me know if you can help, thanks a ton!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T01:37:10+00:00Added an answer on June 15, 2026 at 1:37 am
    <?php /* Template Name: TEMPLATE NAME */ ?>
    <?php get_header();?>
    
    <?php query_posts('category_name=CATEGORY NAME'); ?>
       <?php while (have_posts()) : the_post(); ?>
          <?php the_excerpt(); ?>
    <?php endwhile; ?>
    

    Is this what you mean?

    the_excerpt

    can be changed to

    the_content

    Also I’d just like to add that you can put divs in there around the WP PHP.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Hey guys, I have the following HTML structure that I am trying to pull
Hey guys and gals I'm having some major issues trying to get my application
Hey guys I have an older site that is coded in AS2(I can't get
Hey guys...I am trying to get some data based on a condition which I
Hey guys I am getting this exception when trying to run the query Column
Hey guys, I am just trying to pull all the records from my database
Hey guys, I am trying to run a proccess by submitting an AJAX form:
Hey guys im trying to connect to an database and collect some data out
Hey guys I'm trying to see where my pairs of keys stop, I have
Hey guys i have been trying to download it from the below link http://www.enterprisedb.com/products-services-training/pgdownload

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.