[wp-cvs] wordpress/wp-admin edit-comments.php,1.36,1.37

Matthew Mullenweg saxmatt at users.sourceforge.net
Tue Oct 5 07:25:24 UTC 2004


Update of /cvsroot/cafelog/wordpress/wp-admin
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv7622/wp-admin

Modified Files:
	edit-comments.php 
Log Message:
Page comments

Index: edit-comments.php
===================================================================
RCS file: /cvsroot/cafelog/wordpress/wp-admin/edit-comments.php,v
retrieving revision 1.36
retrieving revision 1.37
diff -C2 -d -r1.36 -r1.37
*** edit-comments.php	5 Oct 2004 07:13:51 -0000	1.36
--- edit-comments.php	5 Oct 2004 07:25:21 -0000	1.37
***************
*** 62,70 ****
  		ORDER BY comment_date DESC");
  } else {
! 	$comments = $wpdb->get_results("SELECT * FROM $wpdb->comments ORDER BY comment_date DESC LIMIT 20");
  }
  if ('view' == $mode) {
  	if ($comments) {
! 		echo '<ol class="commentlist">';
  		$i = 0;
  		foreach ($comments as $comment) {
--- 62,80 ----
  		ORDER BY comment_date DESC");
  } else {
! 	if ( isset($_GET['offset']) )
! 		$offset = (int) $_GET['offset'] * 20;
! 	else
! 		$offset = 0;
! 
! 	$comments = $wpdb->get_results("SELECT * FROM $wpdb->comments ORDER BY comment_date DESC LIMIT $offset,20");
  }
  if ('view' == $mode) {
  	if ($comments) {
! 		if ($offset)
! 			$start = " start='$offset'";
! 		else
! 			$start = '';
! 
! 		echo "<ol class='commentlist' $start>";
  		$i = 0;
  		foreach ($comments as $comment) {
***************
*** 93,99 ****
  		</li>
  
! 		<?php 
! 		} // end foreach
! 	echo '</ol>';
  	} else {
  
--- 103,116 ----
  		</li>
  
! <?php } // end foreach ?>
! </ol>
! <form action="" method="get">
! <p class="submit">
! <input type="hidden" name="offset" value="<?php echo $_GET['offset']+ 1; ?>" />
! <input type="submit" name="submit" value="<?php _e('View Next 20 Comments &raquo;');?>" />
! </p>
! </form>
! 
! <?php
  	} else {
  




More information about the cvs mailing list