X-Git-Url: https://jasonwoof.com/gitweb/?p=ckeditor.git;a=blobdiff_plain;f=_samples%2Fphp%2Freplaceall.php;h=4415fbdc1be6fe6b1cebb7ee877408a6ca7e254d;hp=38efc806ccffd41736903e1c8e9e97f00cd438f4;hb=48b1db88210b4160dce439c6e3e32e14af8c106b;hpb=9afde8772159bd3436f1f5b7862960307710ae5a diff --git a/_samples/php/replaceall.php b/_samples/php/replaceall.php index 38efc80..4415fbd 100644 --- a/_samples/php/replaceall.php +++ b/_samples/php/replaceall.php @@ -1,19 +1,43 @@
-
+ This sample shows how to replace all <textarea>
elements
+ with CKEditor by using PHP code.
+
+ To replace all <textarea>
elements, place the following call at any point
+ after the last <textarea>
element:
+
+<?php +// Include the CKEditor class. +include("ckeditor/ckeditor.php"); + +// Create a class instance. +$CKEditor = new CKEditor(); + +// Path to the CKEditor directory. +$CKEditor->basePath = '/ckeditor/'; + +// Replace all textarea elements with CKEditor. +$CKEditor->replaceAll(); +?>+