TheRageIsOn
Member
Hey there,
i have an issue about saving admin settings to be able to use in my templates.
Its something like this:
Additional i have the options.xml like this:
I want to use that setting in templates as listed above like $xf.options.imageServer.
but when i press save nothing gets save
How do i handle that data in my Folders.php controller ?
What am i missing?
Regards Mike
i have an issue about saving admin settings to be able to use in my templates.
Its something like this:
Code:
<xf:form action="{{ link('images/folders/save') }}" class="block" ajax="true">
<div class="block-container">
<div class="block-body">
<xf:inforow>Manage</xf:inforow>
<xf:textboxrow name="imageServer" value="{$xf.options.imageServer}" maxlength="100" label="Enter the Image server URL here" />
<xf:submitrow sticky="true" icon="save" />
</div>
</div>
</xf:form>]]>
Additional i have the options.xml like this:
Code:
<option option_id="imageServer" edit_format="textbox" data_type="string" advanced="0">
<default_value></default_value>
<edit_format_params>rows=5</edit_format_params>
<relation group_id="images" display_order="1110"/>
</option>
I want to use that setting in templates as listed above like $xf.options.imageServer.
but when i press save nothing gets save
How do i handle that data in my Folders.php controller ?
public function actionSave(ParameterBag $params)
{
$this->assertPostOnly();
$options = \XF:ptions();
if ($params->imageServer)
{
print "Server:".$params->imageServer;
}
echo"saved or not?";
....other code here
}
What am i missing?
Regards Mike