More consistent check
This commit is contained in:
parent
ceb2920769
commit
f34fb0d82d
@ -518,7 +518,7 @@ jQuery(document).ready(function() {
|
|||||||
/* focus work on a standard textarea but not if field was replaced with CKEDITOR */
|
/* focus work on a standard textarea but not if field was replaced with CKEDITOR */
|
||||||
jQuery('#dp_desc').focus();
|
jQuery('#dp_desc').focus();
|
||||||
/* focus if CKEDITOR */
|
/* focus if CKEDITOR */
|
||||||
if (typeof(CKEDITOR) !== 'undefined')
|
if (typeof CKEDITOR == "object" && typeof CKEDITOR.instances != "undefined" && CKEDITOR.instances[key] != "undefined")
|
||||||
{
|
{
|
||||||
var editor = CKEDITOR.instances['dp_desc'];
|
var editor = CKEDITOR.instances['dp_desc'];
|
||||||
if (editor) { editor.focus(); }
|
if (editor) { editor.focus(); }
|
||||||
@ -624,7 +624,7 @@ jQuery(document).ready(function() {
|
|||||||
/* focus work on a standard textarea but not if field was replaced with CKEDITOR */
|
/* focus work on a standard textarea but not if field was replaced with CKEDITOR */
|
||||||
jQuery('#dp_desc').focus();
|
jQuery('#dp_desc').focus();
|
||||||
/* focus if CKEDITOR */
|
/* focus if CKEDITOR */
|
||||||
if (typeof(CKEDITOR) !== 'undefined')
|
if (typeof CKEDITOR == "object" && typeof CKEDITOR.instances != "undefined" && CKEDITOR.instances[key] != "undefined")
|
||||||
{
|
{
|
||||||
var editor = CKEDITOR.instances['dp_desc'];
|
var editor = CKEDITOR.instances['dp_desc'];
|
||||||
if (editor) { editor.focus(); }
|
if (editor) { editor.focus(); }
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user