Print

Free: API wordpress.org

Challenge

WordPress.org has an API which provides data on each WordPress plugin: listing how often it’s been downloaded, how well it’s rated, etc. We can fetch any such API and display its results on our page. The API for the JCI Plugin is at https://api.wordpress.org/plugins/info/1.0/json-content-importer.json

Code

This shortcode loads data from the above link, converts it into HTML, and shows the data:

[jsoncontentimporter url=https://api.wordpress.org/plugins/info/1.0/json-content-importer.json]
Version: {version} - {downloaded} 
Downloads - {num_ratings} Ratings: {rating}%
[/jsoncontentimporter]
Result

The live result is below:


Version: 1.3.13 – 225043
Downloads – 64 Ratings: 98%

Was this article helpful?
4.5 out Of 5 Stars
5 Stars 0%
4 Stars 100%
3 Stars 0%
2 Stars 0%
1 Stars 0%
How can we improve this article?
Please submit the reason for your vote so that we can improve the article.
Previous Free: Examples
On this page: