2013-05-21, 15:57:58
The function for me looks like this:
How do I have the same function encompass the extra code as previously quoted?
Code:
CKEDITOR.on( 'dialogDefinition', function( ev ) {
var dialogName = ev.data.name;
var dialogDefinition = ev.data.definition;
ev.data.definition.resizable = CKEDITOR.DIALOG_RESIZE_NONE;
if ( dialogName == 'link' ) {
var infoTab = dialogDefinition.getContents( 'info' );
//dialogDefinition.removeContents( 'target' );
var advTab = dialogDefinition.getContents( 'advanced' );
advTab.remove( 'advLangDir' );
advTab.remove( 'advLangCode' );
advTab.remove( 'advContentType' );
advTab.remove( 'advTitle' );
advTab.remove( 'advCharset' );
}
if ( dialogName == 'image' ) {
var infoTab = dialogDefinition.getContents( 'info' );
infoTab.remove( 'txtBorder' );
infoTab.remove( 'txtHSpace' );
infoTab.remove( 'txtVSpace' );
infoTab.remove( 'btnResetSize' );
dialogDefinition.removeContents( 'Link' );
var advTab = dialogDefinition.getContents( 'advanced' );
advTab.remove( 'cmbLangDir' );
advTab.remove( 'txtLangCode' );
advTab.remove( 'txtGenLongDescr' );
advTab.remove( 'txtGenTitle' );
}
});
How do I have the same function encompass the extra code as previously quoted?