From 2710d0b09fb3aa92b8f290c16e760cb33a02c438 Mon Sep 17 00:00:00 2001 From: mikelittle Date: Sun, 1 Jun 2003 20:59:56 +0000 Subject: [PATCH] Fix to use ezsql Also brought into line with inline comments code. git-svn-id: http://svn.automattic.com/wordpress/trunk@145 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- b2commentspopup.php | 47 +++++++++++++++------------------------------ 1 file changed, 16 insertions(+), 31 deletions(-) diff --git a/b2commentspopup.php b/b2commentspopup.php index e22caa9e0d..aaebe15a80 100644 --- a/b2commentspopup.php +++ b/b2commentspopup.php @@ -2,9 +2,8 @@ $blog=1; include('blog.header.php'); add_filter('comment_text', 'popuplinks'); -while($row = mysql_fetch_object($result)) { start_b2(); -?> - +foreach ($posts as $post) { start_b2(); +?> <?php echo $blogname ?> - Comments on "<?php the_title() ?>" @@ -24,37 +23,27 @@ while($row = mysql_fetch_object($result)) { start_b2();
    %' ORDER BY comment_date"; -$resultc = mysql_query($queryc); -if ($resultc) { -while($rowc = mysql_fetch_object($resultc)) { - $commentdata = get_commentdata($rowc->comment_ID); +$comments = $wpdb->get_results("SELECT * FROM $tablecomments WHERE comment_post_ID = $id ORDER BY comment_date"); +// this line is WordPress' motor, do not delete it. +if ($comments) { + foreach ($comments as $comment) { ?>
  1. -

    By {$commentdata["comment_author"]} -QQQ; -} else { - echo $commentdata["comment_author"]; -} ?> @

    +

    by @

  2. - - - - - +
  3. No comments yet.
  4. - +

Leave a Comment

-

Line and paragraph breaks automatic, website trumps email, HTML allowed: ', '> ', $comment_allowed_tags)); ?>

+

Line and paragraph breaks automatic, website trumps email, HTML allowed:

-

@@ -66,29 +55,25 @@ QQQ;

- +

- +

- +
- +

-
- - -
Close this window.