公司让用wordpress开发一个新的cms系统,由于资料有限,主要还是英文,伤透了脑筋!!!
现总结如下,望大家少走弯路
1、表结构,这问仁兄总结的不错
http://blog.youkuaiyun.com/ppiao1970hank/article/details/6301812
2、函数的参考建议去官网看看
3、保留段落前面的空格 修改 /wp-admin/edit-form-advanced.php 496行左右,tinymce编辑器的配置
添加
<?php wp_editor( $post->post_content, 'content', array(
'dfw' => true,
'drag_drop_upload' => true,
'tabfocus_elements' => 'insert-media-button,save-post',
'editor_height' => 360,
'tinymce' => array( //编辑器的配置
'resize' => false,
'add_unload_trigger' => false,
'paste_as_text' => true, //纯文本字符粘贴
'entity_encoding' => "named", //保留段落空格,转换为 
'entities' => "160,nbsp,162,cent,8364,euro,163,pound", //保留段落空格
),
) ); ?>