代码之家  ›  专栏  ›  技术社区  ›  user455982

想在fckeditor代码中调用javascript

  •  1
  • user455982  · 技术社区  · 15 年前

    我想在fckeditors中调用onblur函数。

    这是我的密码。

      <?php
      $oFCKeditor = new FCKeditor('conf_emailtext['.$this->escape($data->conf_id).']') ;  
      $oFCKeditor->BasePath = $this->baseUrl().'/FCKeditor/' ;
      $oFCKeditor->Value =  $this->arrMailList[$i]['conf_emailtext'];
      $oFCKeditor->Height ='400px';
      $oFCKeditor->Width ='650px';
      $oFCKeditor->Create() ;
      ?>
    

    有人能帮我解决这个问题吗?

    事先谢谢。

    汉字

    1 回复  |  直到 15 年前
        1
  •  0
  •   Asif Mulla    15 年前

    不要这样认为,可以用PHP设置。但是,您可以使用HTML/template页面上的javascript来实现这一点。

    <script type="text/javascript" language="javascript">
    function FCKeditor_OnComplete( editor_instance)
    {
       editor_instance.Events.AttachEvent( 'OnFocus', DoSomething ) ;
       editor_instance.Events.AttachEvent( 'OnBlur', DoSomething1 ) ;
    }
    </script>
    
    推荐文章