Skip to content

Commit

Permalink
LPS-9675 Blogs Portlet: 'Blogs Entry' content field accepts a Null St…
Browse files Browse the repository at this point in the history
…ring if you do not click on the CKEditor.

git-svn-id: svn://svn.liferay.com/repos/public/portal/trunk@53518 05bdf26c-840f-0410-9ced-eb539d925f36
  • Loading branch information
Bruno Basto committed May 22, 2010
1 parent 4b9fc42 commit a1dde25
Showing 1 changed file with 12 additions and 2 deletions.
14 changes: 12 additions & 2 deletions portal-web/docroot/html/js/editor/ckeditor.jsp
Original file line number Diff line number Diff line change
Expand Up @@ -47,12 +47,22 @@ String cssClasses = ParamUtil.getString(request, "cssClasses");
CKEDITOR.config.customConfig = '<%= request.getContextPath() %>/html/js/editor/ckeditor/ckconfig.jsp?p_l_id=<%= plid %>&p_main_path=<%= HttpUtil.encodeURL(mainPath) %>&doAsUserId=<%= HttpUtil.encodeURL(doAsUserId) %>&cssPath=<%= HttpUtil.encodeURL(cssPath) %>&cssClasses=<%= HttpUtil.encodeURL(cssClasses) %>';
}
function getCkData() {
var data = CKEDITOR.instances.CKEditor1.getData();
if (CKEDITOR.env.gecko && (CKEDITOR.tools.trim(data) == '<br />')) {
data = '';
}
return data;
}
function getHTML() {
return CKEDITOR.instances.CKEditor1.getData();
return getCkData();
}
function getText() {
return CKEDITOR.instances.CKEditor1.getData();
return getCkData();
}
</script>
</head>
Expand Down

0 comments on commit a1dde25

Please sign in to comment.