| 开发者 | lxdintegral |
|---|---|
| 更新时间 | 2026年11月18日 00:06 |
| PHP版本: | 8.1 及以上 |
| WordPress版本: | 7.1 |
| 版权: | GPLv2 or later |
| 版权网址: | 版权信息 |
[user_badges] shortcode or the Earned Badges block. Each badge carries a Save & share link (the owner's page at the provider, where the badge can be saved to Open Badge Passport / CanCred Passport or downloaded) and a public Verify link to the provider's hosted validator.https://openbadgefactory.com), operated by Open Badge Factory Oy, Finland. Terms of use · Privacy noticehttps://factory.cancred.ca), operated by Learning Agents, Canada. Terms of use · Privacy policyAUTH_KEY and SECURE_AUTH_KEY in wp-config.php, as WordPress recommends, so that key is not itself stored in the database. If the salts are ever changed, the plugin asks you to re-enter the secret.
Background work (issuing, retries, link fetching, status checks) runs through WP-Cron. If your site has disabled WP-Cron, make sure a system cron job calls wp-cron.php. The plugin is designed for single-site installs; on a multisite network, activate it per site.
Source code
The block editor script ships as compiled JavaScript in build/; its human-readable source is included in blocks/ and in the public repository at github.com/LXD-Integral/lxd-integral-microcredentials-for-learndash. To rebuild it, run npm install and then npm run build in the plugin directory; the build uses @wordpress/scripts. The PHP needs no build step.
[user_badges] shortcode, to any page.[user_badges] shortcode accepts these optional attributes: user (user ID, defaults to the current visitor), columns (1–6, default 3), size (badge image size in px, 32–256, default 96), show_name (1/0), link (1/0, link each badge image to the provider's badge page), export (1/0, "Save & share" link, owner only), verify (1/0, "Verify" link).Both, including both at once. Open Badge Factory and CanCred Factory are functionally identical platforms with different geographical mandates. The plugin connects to each with its own Client ID and Client Secret, and every badge remembers which provider it came from.
In the provider's console under Admin tools → API, create an API key. This requires a subscription tier with API access. Paste the Client ID and Client Secret into the plugin's Settings screen and use Test Connection.
Badges are synced, not live-queried. Go to Badges → Sync Now to pull the current library. Draft badges are listed but can't be issued until published in the provider's console.
Issuance is deliberately asynchronous. When a learner completes an item, the plugin records the award and hands it to a background job, so the learner's completion is never slowed down or broken by the badge provider. The badge is normally issued within a minute or two, and an hourly safety sweep catches anything that slipped through. If a badge still hasn't appeared after an hour, check the Activity Log, where every attempt is recorded with a specific reason on failure.
No. Awards are idempotent per trigger: once a learner holds a badge from a given trigger rule, re-completing the same item does not issue a duplicate.
The award is queued and retried with increasing backoff (up to five attempts), and the hourly sweep re-processes anything still outstanding. Failures appear in the Activity Log. The learner's course completion is unaffected.
Yes. Issue Badges → Backfill runs a trigger over learners who completed the item before the trigger existed. You can also issue any badge to any learner by hand from the same screen.
Yes. Quiz triggers accept an optional minimum percentage. A completion without a score never satisfies a score condition.
No. A quiz trigger awards only when LearnDash records the attempt as passed, using the passing percentage set on the quiz. A minimum score on the trigger is an extra bar on top of that, not a way around it: to award at a lower score, lower the quiz's own passing percentage. Version 1.0.0 also awarded on failed attempts when the trigger had no minimum score, or one below the quiz's pass mark; 1.0.1 corrects that. Badges 1.0.0 issued on a failed attempt are not withdrawn automatically. If you need to withdraw one, revoke it at Open Badge Factory or CanCred and the plugin will hide it at its next status check.
Save & share opens the badge's claim page at the provider, where the learner can save the badge to Open Badge Passport / CanCred Passport, share it, or download it. It appears only to the badge's owner. Verify opens the provider's public validator, which confirms that the credential is valid, not revoked, and not expired. It is shown to every visitor.
Yes. The shortcode accepts a user attribute. With it, any visitor sees that learner's badge names, images, and Verify links, never the owner's claim link. Without the attribute, the list always shows the signed-in visitor's own badges.
Yes. Every badge is issued by Open Badge Factory / CanCred Factory as a hosted Open Badges 3.0 verifiable credential.
The plugin checks every issued badge's status at the provider once an hour, and immediately when you click Refresh Award Status on the Badges screen. A revoked badge disappears from the learner's list and from every public showcase, and the Activity Log records the change.
Only if the badge was set up with an expiry at the provider. The badge list then shows "Expires" with the date and, once the date passes, "Expired". Expired badges stay listed, but the owner's Save & share link is dropped.
Yes. Pages showing a visitor's own badge list are excluded from full-page caching, and issuing a badge or a status change purges the page cache. Public showcase pages remain fully cacheable.
Yes. The plugin plugs into WordPress's Tools → Export Personal Data and Erase Personal Data: an export lists every badge awarded to the email address, and an erasure removes the email address from the award records and deletes the learner's activity-log entries. The award records themselves are kept, so a badge is never issued twice, and the credential remains at the provider.
Per site. Activate and configure it on each site that needs it; network activation is not supported.
Nothing is deleted by default: uninstalling preserves your badges, triggers, award history, and log. Tick Delete all plugin data when the plugin is uninstalled on the Settings screen if you want everything removed.
Yes. LXD Integral Learning Ltd. has committed to maintaining the plugin until at least November 2029 (three years from the 1.0.0 release), reviewed each November. In practice that means a standing weekly support and maintenance window, a first reply to support-forum threads within a week, compatibility kept current with each WordPress major release and with the Open Badge Factory / CanCred API, and an independent security review of the code each quarter on top of the automated checks that run on every change. Updates arrive through the normal WordPress update channel.
Privately, please: use the "Report a vulnerability" form on the plugin's GitHub repository (https://github.com/LXD-Integral/lxd-integral-microcredentials-for-learndash/security/advisories/new), email security@lxdintegral.com, or email the WordPress.org plugins team at plugins@wordpress.org naming this plugin. The repository's SECURITY.md gives the full policy: the latest release is the supported one, reports are acknowledged within a working day, and a fix ships as a patch release on a seven-day target for anything exploitable without an administrator account. Please do not post security problems in the public support forum.
wp_unschedule_hook().WP_DEBUG on.
The pre-release history (0.1.0 to 0.4.0) is in changelog.txt.