- Create empty dialog - onLoad : get ajax content -onShow : add content to the dialog (for that moment, add json string returned by server in an HTML element)
That doc points to the API_dialog.html sample that shows how to customize dialogs modifying their definition on the dialogDefinition event.
If you listen for other events like onLoad or onShow, they are fired on the final dialog instances, so the definition has already been parsed and no matter whatever changes you make to them now. If you want to customize the dialog now you have to work at a different level (plain HTML & JS or dig into the code to find out how to create elements at runtime)
Besides that, remember that CKEDITOR.ajax.load is asynchronous, so there's no warranty that firing it at onLoad would return the contents before the onShow event is fired, and you have to keep that in mind with whatever system you end up using.
Re: Dynamically add dialog content after dialog load
If you listen for other events like onLoad or onShow, they are fired on the final dialog instances, so the definition has already been parsed and no matter whatever changes you make to them now. If you want to customize the dialog now you have to work at a different level (plain HTML & JS or dig into the code to find out how to create elements at runtime)
Besides that, remember that CKEDITOR.ajax.load is asynchronous, so there's no warranty that firing it at onLoad would return the contents before the onShow event is fired, and you have to keep that in mind with whatever system you end up using.