set tabindex and class to FCK editor

519 Views Asked by At

i have problem to set tabindex to FCK editor . i am using following php code for fck editor

require_once("".$abspath."fckeditor/fckeditor.php");
    $oFCKeditor = new FCKeditor("shippinginfo") ;
    $oFCKeditor->BasePath = "../fckeditor/" ;
    $oFCKeditor -> Height = '300';
    $oFCKeditor -> Width = '900';
    $oFCKeditor->Value = stripslashes(str_replace("\\","",$product_shippinginfo));
    $oFCKeditor->Create() ;

and i also like to class to fck editor

any one have the idea

2

There are 2 best solutions below

0
On BEST ANSWER

by textarea replacing method we can set tabindex. so it works thanks !

 <textarea name="product_long_tescription" id="product_long_tescription"  tabindex="4"  class="fillbymaster" >init value</textarea>


window.onload = function()
{
var oFCKeditor = new FCKeditor( 'product_long_tescription' ) ;
oFCKeditor.BasePath = "../fckeditor/" ;
oFCKeditor.Height = "300" ; 
oFCKeditor.Width = "900";
oFCKeditor.ReplaceTextarea() ;

}
0
On

by the way i google and find below solution... try this

open file: fckeditor.js

find there a string:


return '<iframe id="' + this.InstanceName + '___Frame" src="' + sLink + '" width="' + this.Width + '" height="' + this.Height + '" frameborder="0" scrolling="no" tabindex=4></iframe>' ;

to add Class

Find these lines in FCKedotor's confing file, fckconfig,js

// This will be applied to the body element of the editor
FCKConfig.BodyId = '' ;
FCKConfig.BodyClass = '' ;

reference