[英]Set CKEditor4 Value with PHP
如何使用PHP设置CKEditor4值? 我将变量放在标签中,但是它没有将要从数据库中获取的数据加载到其中。
<td class="rightpan">
<textarea name="editor1"><?=stripslashes($descriptionH); ?></textarea>
<script>
CKEDITOR.replace( 'editor1', {
removePlugins: 'elementspath'
});
</script>
有人能帮我吗? 它是属于replace()函数的东西吗,例如Value:$ descriptionH或其他东西?
<td class="rightpan">
<textarea id="editor1" class="ckeditor" name="editor1"><?php echo htmlspecialchars($descriptionH, ENT_QUOTES); ?></textarea>
<script>
$('#editor1').ckeditor(function() {},
{
toolbar: [
['Source','Styles', 'Format','TextColor','BGColor'],
['Image','Table','HorizontalRule','SpecialChar','PageBreak'],
['Cut','Copy','Paste','PasteText','PasteFromWord','-','Scayt'],
['Bold', 'Italic', '-', 'NumberedList', 'BulletedList', '-', 'Link', '-', 'About'],
['JustifyLeft','JustifyCenter','JustifyRight','JustifyBlock']
],
width: 650,
height: 350
}
);
</script>
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.