PolyLang
in package
Uses
UtilsProvider
This class handles the compatibility for Poly Lang plugin.
Table of Contents
Properties
- $active : mixed
- $me : mixed
- $previousFolderId : mixed
- Avoid duplicate call of move action.
- $previousIds : mixed
- Avoid duplicate call of move action.
Methods
- getInstance() : PolyLang
- Get instance.
- getPluginConstantPrefix() : string
- Get the prefix of this plugin so composer packages can dynamically build other constant values on it.
- html_options_move() : mixed
- Output button to move translation.
- init() : mixed
- Initialize actions.
- item_move_finished() : mixed
- A file is moved (not copied) and then move also all the translations.
- options_register() : mixed
- Register option for PolyLang.
- pll_translate_media() : mixed
- New translation created => synchronize with original post.
- __construct() : mixed
- C'tor.
Properties
$active
private
mixed
$active
= false
$me
private
static mixed
$me
= null
$previousFolderId
Avoid duplicate call of move action.
private
mixed
$previousFolderId
= null
$previousIds
Avoid duplicate call of move action.
private
mixed
$previousIds
= null
Methods
getInstance()
Get instance.
public
static getInstance() : PolyLang
Return values
PolyLanggetPluginConstantPrefix()
Get the prefix of this plugin so composer packages can dynamically build other constant values on it.
public
getPluginConstantPrefix() : string
Tags
Return values
stringhtml_options_move()
Output button to move translation.
public
html_options_move() : mixed
init()
Initialize actions.
public
init() : mixed
item_move_finished()
A file is moved (not copied) and then move also all the translations.
public
item_move_finished(int $folderId, array<string|int, int> $ids, IFolder $folder, bool $isShortcut) : mixed
Parameters
- $folderId : int
- $ids : array<string|int, int>
- $folder : IFolder
- $isShortcut : bool
options_register()
Register option for PolyLang.
public
options_register() : mixed
pll_translate_media()
New translation created => synchronize with original post.
public
pll_translate_media(int $post_id, int $tr_id, string $lang_slug) : mixed
Then reset the count cache for the unorganized folder.
Parameters
- $post_id : int
- $tr_id : int
- $lang_slug : string
__construct()
C'tor.
private
__construct() : mixed