WP Manifestindependent plugin directory
manifest / developer / wp-corpus-utils

GovRight Corpus Utilities

Developer's suite for handling common small tasks like locale data extraction or GovRight Corpus API calls in Wordpress

by GovRight · github.com/govright/wp-corpus-utils · website

0stars
0forks

Install

No release zip yet. The repository archive installs, but the folder name will carry the branch suffix and updates will not flow:

wp plugin install https://github.com/govright/wp-corpus-utils/archive/refs/heads/master.zip

Declares an update source (https://github.com/GovRight/wp-corpus-utils), so updates arrive through the plugin's own updater.

From the readme

GovRight Corpus Utilities Developer's suite for handling common small tasks like locale data extraction or GovRight Corpus API calls in WordPress themes and plugins. Requirements Tested and works properly with: WordPress = 4.5 PHP = 5.5 (dev) PHPUnit =4.8.24 (dev) Node.js =5 2. string $languagecode (optional) - language code to extract | array | Extracts locale data from a model instance. If $languagecode is specified - returns corresponding translations if available or a first available otherwise. If $languagecode is not specified - checks if the WPML plugin is activated and tries to extract currently set language, return a first available locale otherwise. corpusattsstring() | 1. array $atts - attributes array 2. bool $includelocale (optional) - include locale prop | string | Converts $atts array into a string. Includes data-locale prop if $includelocale is true and WPML is activated. JavaScript API reference Plugin adds a global GovRight object which has the following properties/methods: Function/prop | Arguments | Returns | Description --- | --- | --- | --- GovRight.corpusApiUrl | - | - | String property that stores Corpus API url. Default value is http://corpus.go

Read the full README on GitHub →