blob: f00c773607511b2c22feff22a9670373afdee668 (
plain)
| 1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
 | <%doc>
Example:
  include('/elements/htmlarea.html',
            'field'      => 'fieldname',
            'curr_value' => $curr_value,
            'height'     => 800,
         );
</%doc>
% #init
<SCRIPT TYPE="text/javascript" src="<% $p %>elements/fckeditor/fckeditor.js">
</SCRIPT>
% #editor
<SCRIPT TYPE="text/javascript">
  var oFCKeditor = new FCKeditor('<% $opt{'field'} %>');
  oFCKeditor.Value = <% $opt{'curr_value'} |js_string %>;
  oFCKeditor.BasePath = '<% $p %>elements/fckeditor/';
  oFCKeditor.Config['SkinPath'] = '<% $p %>elements/fckeditor/editor/skins/silver/';
% if ( $opt{'width'} ) {
    oFCKeditor.Width = '<% $opt{'width'} %>';
% }
  oFCKeditor.Height = '<% $opt{'height'} || 420 %>';
  oFCKeditor.Config['StartupFocus'] = true;
  oFCKeditor.Config['EnterMode'] = 'br';
  oFCKeditor.Create();
</SCRIPT>
<%init>
my %opt = @_;
</%init>
 |