query comment author url (2 posts)

  1. leisegang
    Posted 3 years ago #

    i am trying to get out all the comment author emails for doing a competition, the one that comments the most in the next 30 days win a price. but i cannot get all the emails outputted. the best would be if it was printet to a txt file or screen.

    can anyone help me with this?
    i am making graphs in excel

    	global $wpdb;
    	// Query all blogs from multi-site install
    	$blogs = $wpdb->get_results("SELECT blog_id FROM wp_blogs ORDER BY blog_id");
    	foreach( $blogs as $blog ) {
    		// Query for comment_author_email from comments table
    		$eposts = $wpdb->get_results("SELECT <code>comment_author_email FROM
    wp_".$blog->blog_id ."_comments");
    		foreach( $eposts as $epost ) {
    			// Create list
    			echo $epost->option_value;
  2. All comments from all sites on your network?

Topic Closed

This topic has been closed to new replies.

About this Topic


No tags yet.