Open mvanmeerbeck opened 7 years ago
sure, any suggestions as to implementation?
@diggy: I also had a problem with this, solved it by calling activate_license
, if $licenses['polylang-pro']['key']
was not set:
if (defined('POLYLANG_PRO') && defined('POLYLANG_PRO_LICENSE_KEY') && !empty(POLYLANG_PRO_LICENSE_KEY)) {
add_action('after_setup_theme', function() {
$licenses = get_option('polylang_licenses');
if (empty($licenses['polylang-pro']['key'])) {
$license = new PLL_License(POLYLANG_FILE, 'Polylang Pro', POLYLANG_VERSION, 'Frédéric Demarle');
$license->activate_license(POLYLANG_PRO_LICENSE_KEY);
}
});
}
In my wp-config.php
i then have this define:
define('POLYLANG_PRO_LICENSE_KEY', 'xxxxxxxxxxxxxxxx');
Something similar could be implemented in polylang-cli...
@tditlu I'm not a PLL pro user, so I'm not sure if I'm in the best position to implement this. Of course, I welcome a PR that fixes your problem :)
Hi,
I'm using the pro version of polylang and i'm willing to set the license through the wp-cli but the option doesn't appear after:
wp pll option list
In fact, this option is under another namespace
wp option list | grep license
polylang_licenses
Is there anyway to handle that ?
Thanks!