Usage
- Method 1: replacing ALL textareas in a page with THE SAME settings
<textarea name="fck1" cols="50" rows="6"></textarea>
<textarea name="fck2" cols="50" rows="6"></textarea>
<textarea name="fck3" cols="50" rows="6"></textarea>
<script> $(function(){ $('textarea').fck({path: '/path/to/fck/directory/'}); }); </script>
- Method 2: replacing SOME textareas in a page with THE SAME settings
In this example, only textarea fck3 will not be converted into a FCKEditor.
<textarea name="fck1" class="fck" cols="50" rows="6"></textarea>
<textarea name="fck2" class="fck" cols="50" rows="6"></textarea>
<textarea name="fck3" cols="50" rows="6"></textarea>
<script> $(function(){ $('textarea.fck').fck({path: '/path/to/fck/directory/'}); }); </script>
- Method 3: replacing SOME textareas in a page with DIFFERENT SETTINGS (see demo)
<textarea name="fck1" cols="50" rows="6"></textarea>
<textarea name="fck2" cols="50" rows="6"></textarea>
<textarea name="fck3" cols="50" rows="6"></textarea>
<script>
$(function(){
$.fck.config = {path: '/path/to/fck/directory/', height:300 };
$('textarea#fck1').fck(/* default settings */);
$('textarea#fck2').fck({ toolbar:'MyCustomerToolbar' });
$('textarea#fck3').fck({ toolbar:'MyCustomerToolbar', height:200 });
});
</script> -
下载插件