Viewing 7 replies - 1 through 7 (of 7 total)
  • Thread Starter Dane Morgan

    (@danemorgan)

    PS. I added the buttons by hacking the code in the plugin, but if there were an options page we could provide the buttons we need without having to redo them when the plugin was updated.

    Plugin Author shauno

    (@shauno)

    Hey Dane

    An options page is a good idea. I’m on holiday at the moment, so I’m not going to get to it right away though ??

    [ Signature moderated. ]

    Plugin Author shauno

    (@shauno)

    Hey Dane
    Check out version 1.1. I’ve added an option to select the default WP editor when choosing the HTML custom field type.
    Hope that helps your situation.

    [ Signature moderated. ]

    Thread Starter Dane Morgan

    (@danemorgan)

    Beautiful. Went to check the changelog when I saw the update. Now I can plug the MCE for whatever buttons I want and they are universal with the main editor.

    One small gotcha. In my dashboard, the labels from the Betta Boxes Edit page are not showing up above the WP editor fields…

    Thread Starter Dane Morgan

    (@danemorgan)

    Adding Labels was easy enough (though i think they should be added through the functions arguments, and submitted feedback to that effect..

    I altered the code starting at line 26

    if($extra['use_wp_editor'] && version_compare(get_bloginfo('version'), '3.3', '>=')) { //wp_editor() is only available from WP 3.3
    			wp_editor($value, 'scfui_'.$field['slug'], array('textarea_name'=>'scfui['.$field['slug'].']', ));
    		}else{

    like this:

    if($extra['use_wp_editor'] && version_compare(get_bloginfo('version'), '3.3', '>=')) { //wp_editor() is only available from WP 3.3
    			echo '<p>';
    			echo '<label>'.$field['label'].'</label>';
    			wp_editor($value, 'scfui'.$field['slug'], array('textarea_name'=>'scfui_['.$field['slug'].']' ));
    			echo '</p>';
    		}else{

    [Please post code snippets between backticks or use the code button.]

    Note that I altered the wp_editor() $editor_id argument to remove the underscore because the specs specifically state that only lowercase letters may be used in this argument. (might want to add a note to that effect on the editor screen as well.

    Plugin Author shauno

    (@shauno)

    Whoops! Little oversight from me ?? I have added the label in v1.1.1.

    I noticed in the documentation that you shouldn’t have anything other than lower-case letters. I just had used the format scfui_[slug] for all the other field types. And using the underscore didn’t seem to break it. Damn programmer OCD wanting everything to be consistent…
    I have removed it now too. But obviously your slug needs to comply then with lower-case letters only too to be 100% compliant with what the codex says.

    You also shouldn’t re-order meta boxes with the wp_editor() in them according to the codex. I am hoping people read the docs, before I need to start writing a novel explaining everything on the editing screens ??

    Thread Starter Dane Morgan

    (@danemorgan)

    Well, remember 90% of the people who will use this plugin have probably never even loaded the codex. ??

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘[Plugin: Betta Boxes CMS] Inline Font-Size Styles on Betta Box Content’ is closed to new replies.