taishikato / wp-fb-like-ranking

Making a ranking rated by the number of Facebook like. You can make and use a ranking rated by the number of Facebook like width this plugin.

Home Page:https://taishikato.github.io/wp-fb-like-ranking/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

WordPress Facebook Like Ranking πŸ˜ΈπŸ˜‡πŸ˜ˆ

With this plugin, you can create a your posts' ranking sorted by the number of Facebook like.

ExοΌ‰
screenshot-1

How to use

Create FB App

Here
https://developers.facebook.com/

Get FB App Token

You can get that here
https://developers.facebook.com/tools/explorer/

Set your FB App Token

You can see the setting of this plugin when you install it. Click it.
wp-fb-like-ranking-setting-image

You will see the setting page like below.
Put your token in the form and hit the save button.
WPFBSETTINGPAGE-2

Generate your ranking

All you need to do is just hit the "Create or Recreate" button.
WPFBSETTINGPAGE-2

πŸ›  Put code (or you can use wdget)

Put the code below whereever you would like to make the raking show up.

<?php if (function_exists('get_like_ranking')) get_like_ranking(); ?>

There are 6 parameters for this method.

get_like_ranking(int $post_number = 5, bool $post_count = true , array $thumbnail = null, $category_id = null, $shorten_words = null, $custom_post_name = null)

Ex)
In this case, There should be 10 articles which are "Movie" custom post type on your raking.
Second argument is false, thus like count of each artile does not show up.
Thumbnails are 15px x 15px.
If the title og the article is over 25 characters, it's gonne be compressed to 25 characters.

<?php if (function_exists('get_like_ranking')) get_like_ranking(10, false, array(15, 15), null, 25, "movie"); ?>

About

Making a ranking rated by the number of Facebook like. You can make and use a ranking rated by the number of Facebook like width this plugin.

https://taishikato.github.io/wp-fb-like-ranking/


Languages

Language:PHP 74.8%Language:JavaScript 11.5%Language:Vue 10.4%Language:HTML 2.6%Language:CSS 0.8%