Carob-Framework icon indicating copy to clipboard operation
Carob-Framework copied to clipboard

Saving Theme Options

Open lgabeskiria opened this issue 10 years ago • 5 comments

Hi, the issue is that when I save theme options and use it editor's tinymce mode always returnes default value.

lgabeskiria avatar Aug 29 '14 11:08 lgabeskiria

It will fall back to the option's default value if the data that you want to save for that option is not valid for that option type. Take a look at the theme options implementation in the https://github.com/yankodimitrov/Carob-Starter-Theme

yankodimitrov avatar Aug 30 '14 09:08 yankodimitrov

it's just a text, that should be saved. I mentioned that it returns default value, not default option.

lgabeskiria avatar Aug 30 '14 18:08 lgabeskiria

Take a look at the theme options saving implementation in the Carob Starter Theme here: https://github.com/yankodimitrov/Carob-Starter-Theme/blob/master/theme/includes/class-carob-theme-options.php#L59-L95

yankodimitrov avatar Aug 31 '14 07:08 yankodimitrov

I have seen the implementation of saving options, you didn't understand me. When I use editor option with tinymce enabled and if I write text in visual mode not text it returns default value. If I write in text mode it saves it. This happens only in theme options panel. Try it, write something in visual mode and you'll see what I'm talking about.

lgabeskiria avatar Aug 31 '14 11:08 lgabeskiria

Hi, have you figured this issue?

lgabeskiria avatar Sep 10 '14 22:09 lgabeskiria