Please upgrade here. These earlier versions are no longer being updated and have security issues.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
Advanced Theme Options - Return Theme Option value within themeoptions.php
salum
New
I'm developing a theme for vanilla where I'm modifying the themeoptions.php file.
I've been able to do everything so far but can't find a way to retrieve my values. As of now to create a new text field the file uses:
Which creates a textbox (that returns the value) but uses the name of the field in its parameter. I don't wanna create a field, I just wanna return the value from the database...
Pretty much like... I have the Banner Text field for instance... i'd like to have a function that returns me the value of that option without creating a field... I'll be creating and manipulating the field's value myself... Is there a way to simply retrieve the value of the theme option?
I've been able to do everything so far but can't find a way to retrieve my values. As of now to create a new text field the file uses:
echo $this->Form->TextBox($this->Form->EscapeString('Text_'.$Code));
Which creates a textbox (that returns the value) but uses the name of the field in its parameter. I don't wanna create a field, I just wanna return the value from the database...
Pretty much like... I have the Banner Text field for instance... i'd like to have a function that returns me the value of that option without creating a field... I'll be creating and manipulating the field's value myself... Is there a way to simply retrieve the value of the theme option?
Tagged:
0
Comments
$var = $this->Form->GetFormValue($this->Form->EscapeString('Text_'.$Code));