Title: byteee's Replies | WordPress.org

---

# byteee

  [  ](https://wordpress.org/support/users/byteee/)

 *   [Profile](https://wordpress.org/support/users/byteee/)
 *   [Topics Started](https://wordpress.org/support/users/byteee/topics/)
 *   [Replies Created](https://wordpress.org/support/users/byteee/replies/)
 *   [Reviews Written](https://wordpress.org/support/users/byteee/reviews/)
 *   [Topics Replied To](https://wordpress.org/support/users/byteee/replied-to/)
 *   [Engagements](https://wordpress.org/support/users/byteee/engagements/)
 *   [Favorites](https://wordpress.org/support/users/byteee/favorites/)

 Search replies:

## Forum Replies Created

Viewing 1 replies (of 1 total)

 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Facebook] [Plugin: Facebook] Comments suggestions](https://wordpress.org/support/topic/plugin-facebook-comments-suggestions/)
 *  [byteee](https://wordpress.org/support/users/byteee/)
 * (@byteee)
 * [13 years, 11 months ago](https://wordpress.org/support/topic/plugin-facebook-comments-suggestions/page/3/#post-2813540)
 * Hi all!
 * First of all, nice plugin!
 * I suggest to change the system of linking the post thumbnail in the og:image 
   meta-tag. You can add a condition that if there is no post-thumbnail grab the
   first image of the post. Like:
 *     ```
       $first_img = '';
       		$output = preg_match_all('/<img.+src=[\'"]([^\'"]+)[\'"].*>/i', $post->post_content, $matches);
       		$first_img = $matches[1][0];
       		if(trim($first_img)) {
       			echo '<meta property="og:image" content="'.trim($first_img).'">';
       		}
       ```
   

Viewing 1 replies (of 1 total)