Web Design Forum: AdamConder - Viewing Profile - Web Design Forum

Jump to content

WDF
WDF Premium Memberships Reseller Hosting

AdamConder's Profile User Rating: -----

Reputation: 9 Neutral
Group:
Members
Active Posts:
193 (0.19 per day)
Joined:
18-May 09
Profile Views:
5,046
Last Active:
User is online Today, 11:49 PM
Currently:
Viewing Topic: Mysql union search or select fro...

My Information

Member Title:
Dedicated Member
Age:
20 years old
Birthday:
August 27, 1991
Gender:
Male Male
Location:
Newcastle, UK
Interests:
HTML, CSS and PHP!

Contact Information

E-mail:
Private
Website URL:
Website URL  http://adamconder.com

Users Experience

Experience:
Intermediate
Area of Expertise:
Coder

Posts I've Made

  1. In Topic: Wordpress Comments Loop

    30 March 2011 - 05:49 PM

    This fixed it:

       <?php $post_id = $post->ID; ?>
    	<?php $comments = get_comments(array('post_id' => $post_id)); ?>
  2. In Topic: Wordpress Comments Loop

    30 March 2011 - 05:18 PM

    Nope has no effect :l
  3. In Topic: Wordpress Comments Loop

    30 March 2011 - 04:56 PM

    Problem now is how can I specify the post id? It's returning all comments

    something like:
    <?php $comments = get_comments($post->ID); ?>
  4. In Topic: Wordpress Comments Loop

    30 March 2011 - 03:52 PM

    Solved:
    <?php $comments = get_comments(); ?>
    Thanks for the prompt :p
  5. In Topic: Wordpress Comments Loop

    30 March 2011 - 03:47 PM

    I was thinking the same, but everywhere I've looked is the same. Surely need to store a SQL statement inside and check if anything has been returned?

    Or is $comments a global variable that wp understands?