stray closing /TABLE in the no-ticket case
[freeside.git] / httemplate / elements / htmlarea.html
index 7c40e61..dba744e 100644 (file)
@@ -12,7 +12,7 @@ Example:
 </%doc>
 
 % #init
-<SCRIPT TYPE="text/javascript" src="<% $p %>elements/ckeditor/ckeditor.js">
+<SCRIPT TYPE="text/javascript" src="<% $fsurl %>elements/ckeditor/ckeditor.js">
 </SCRIPT>
 
 % #editor
@@ -20,7 +20,8 @@ Example:
 
 <SCRIPT TYPE="text/javascript">
 
-  CKEDITOR.replace('<% $opt{'field'} %>',
+  var <% $opt{'field'} %>_editor =
+    CKEDITOR.replace('<% $opt{'field'} %>',
                    <% encode_json($config) %>
   );
 
@@ -31,11 +32,11 @@ Example:
 my %opt = @_;
 my $config = {
   'height'              => ($opt{height} || 420),
-  'startupFocus'        => JSON::true,
+  'startupFocus'        => Cpanel::JSON::XS::true,
   'skin'                => 'kama',
   'toolbarCanCollapse'  => JSON::true,
   'removePlugins'       => 'elementspath',
-  'basePath'            => $p.'elements/ckeditor/',
+  'basePath'            => $fsurl.'elements/ckeditor/',
   'enterMode'           => 2,
   %{ $opt{config} || {} },
 };