You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hey,
I want to save the changed value for an option from other function of my plugin.
When using setOption() and setting new value; I'm getting the new value (using getOption() ) for that titan instance only but it's not saving the value in the database permanently. When recalling the value from another page, it just returns the default value.
Hey,
I want to save the changed value for an option from other function of my plugin.
When using
setOption()
and setting new value; I'm getting the new value (usinggetOption()
) for that titan instance only but it's not saving the value in the database permanently. When recalling the value from another page, it just returns the default value.Currently, I'm doing:
$titan = TitanFramework::getInstance('my-plugin');
$color = $titan->getOption('theme-color')
Getting
$color
value red.$titan->setOption('theme-color', 'Green')
$color = $titan->getOption('theme-color')
Getting
$color
value Green.But On other page:
$titan = TitanFramework::getInstance('my-plugin');
$color = $titan->getOption('theme-color')
Getting
$color
value still red.What am I missing here?
Thanks.
The text was updated successfully, but these errors were encountered: