X-Git-Url: https://jasonwoof.com/gitweb/?p=ckeditor.git;a=blobdiff_plain;f=_samples%2Fenterkey.html;h=e6e6c8ffa2f1b72a4ed75d6d54fe60b57635b526;hp=def67ae4d3a5c577f86665c6101fd85cedbe3b23;hb=48b1db88210b4160dce439c6e3e32e14af8c106b;hpb=9afde8772159bd3436f1f5b7862960307710ae5a diff --git a/_samples/enterkey.html b/_samples/enterkey.html index def67ae..e6e6c8f 100644 --- a/_samples/enterkey.html +++ b/_samples/enterkey.html @@ -1,11 +1,11 @@ - ENTER Key Configuration - CKEditor Sample + ENTER Key Configuration — CKEditor Sample @@ -35,9 +35,36 @@ window.onload = changeEnter; -

- CKEditor Sample +

+ CKEditor Sample — ENTER Key Configuration

+
+

+ This sample shows how to configure the Enter and Shift+Enter keys + to perform actions specified in the + enterMode + and shiftEnterMode + parameters, respectively. + You can choose from the following options: +

+ +

+ The sample code below shows how to configure CKEditor to create a <div> block when Enter key is pressed. +

+
CKEDITOR.replace( 'textarea_id',
+	{
+		enterMode : CKEDITOR.ENTER_DIV
+	});
+

+ Note that textarea_id in the code above is the id attribute of + the <textarea> element to be replaced. +

+
+
- When ENTER is pressed:
+ When Enter is pressed:
- When SHIFT + ENTER is pressed:
+ When Shift+Enter is pressed:
@@ -77,10 +104,10 @@ window.onload = changeEnter;