24 'plugin_id' => $plugin_id,
30 elgg_log(
"Invalid value type provided to save plugin setting '{$name}' for plugin '{$plugin_id}' only scalars are allowed",
'ERROR');
34 $name = $this->getNamespacedPluginSettingName($plugin_id, $name);
36 return $this->setPrivateSetting($name,
$value);
48 public function getPluginSetting(
string $plugin_id,
string $name,
$default = null): string {
49 $name = $this->getNamespacedPluginSettingName($plugin_id, $name);
51 return (
string) ($this->getPrivateSetting($name) ??
$default);
62 public function removePluginSetting(
string $plugin_id,
string $name): bool {
63 $name = $this->getNamespacedPluginSettingName($plugin_id, $name);
65 return $this->removePrivateSetting($name);
76 final public function getNamespacedPluginSettingName(
string $plugin_id,
string $name): string {
77 return "plugin:{$this->getType()}_setting:{$plugin_id}:{$name}";
if(!$user||!$user->canDelete()) $name
$plugin_id
Remove all user and plugin settings from the give plugin ID.
elgg_log($message, $level=\Psr\Log\LogLevel::NOTICE)
Log a message.
_elgg_services()
Get the global service provider.