开发者 | mmediagroup |
---|---|
更新时间 | 2021年3月20日 21:32 |
捐献地址: | 去捐款 |
PHP版本: | 7.2 及以上 |
WordPress版本: | 5.7 |
版权: | GPLv2 or later |
版权网址: | 版权信息 |
[covid-watch]
in your code to show the current number of confirmed cases.
You can pass a country and status, like [covid-watch country="France" status="confirmed"]
or [covid-watch country="US" status="deaths"]
to get results only from that country.
Listing all countries
To get a table of all countries and their respective current Coronavirus COVID-19 data, try [covid-watch country="All"]
, which will return a table of all current cases sorted alphabetically.
Pass the sort
attribute to sort by confirmed cases or deaths, like so: [covid-watch country="All" sort="confirmed"]
.
Pass the limit
attribute to limit the amount of results, like so: [covid-watch country="All" sort="confirmed" limit="3"]
. The limit
attribute only works in conjunction with the country="All"
attribute.
Live map shortcode
This shortcode will display a map of all cases.
Use the shortcode [covid-live-map]
in your posts and pages to show the map. You can pass the sort
parameter to change how countries are coloured. Colour by population
, confirmed
(default), deaths
, or mortality
.
A full example might look like [covid-live-map sort="confirmed" height="250px"]
.
Historical data shortcode
You can also use the historical shortcode, [covid-history]
to show a table of historical data.
Just like in the live data shortcode, you can pass attributes to the history shortcode, like so [covid-history country="France" status="confirmed" limit="3"]
.
Vaccine data shortcode
The shortcode you can use in your posts will always reference the most up to date number of vaccinations.
Use the shortcode [covid-vaccines]
in your code to show the current number of administered vaccines.
You can pass a country and status, like [covid-vaccines country="France" status="people_vaccinated"]
or [covid-vaccines country="US" status="people_partially_vaccinated"]
to get results only from that country.
You an also create a table of all country data, as you can with cases. See "Listing all countries" and replace covid-watch
with covid-vaccines
.
About recovered data
Some similar plugins may provide "recovered" data. We've been informed that a lot of countries are no longer reporting on recovered data because medical teams don't have the time to follow up with each patient. Because of this, Johns Hopkins and other data sources have stopped reporting recovered cases, and so have we. We recommend you don't show recovered cases as no accurate data is available.
Yes, this plugin is free to use.
Yes, you can pass your country in the shortcode attributes.
Our data is updated every hour (on average).
The data is provided from Johns Hopkins University via the M Media API.
We recommend you don't show recovered cases as no accurate data is available. We've been informed that a lot of countries are no longer reporting on recovered data because medical teams don't have the time to follow up with each patient. Because of this, Johns Hopkins and other data sources have stopped reporting recovered cases, and so have we.
limit
attribute to as per user suggestionheight
attribute to the mapsort
attribute to [covid-live-map]
shortcode which will change how countries are coloured. Colour by population, confirmed, deaths, or mortality.[covid-live-map]
shortcode which will show a live map of cases.[covid-watch]
shortcode, [covid-watch country="All" sort="deaths"]
, which will return a table of all current cases sorted by deaths."country"
and "status"
to shortcode.