alter
Change-Id: Ia2af41dc827e18e65f64d0afbfa5d155fcae5c7f
This commit is contained in:
parent
fcd79fb935
commit
c9f42b42f1
@ -96,8 +96,8 @@ getAuthors()方法返回的是用户相关的信息:
|
||||
PostRequest post = new PostRequest();
|
||||
post.setPostTitle("测试Title");
|
||||
post.setPostContent("这是一段测试文章内容");
|
||||
post.setCategories("分类1","分类2");
|
||||
post.setTags("a", "b", "c");
|
||||
post.addCategories("分类1","分类2");
|
||||
post.addTags("a", "b", "c");
|
||||
post.setPostName("test-post-name");
|
||||
int postId = wp.newPost(post);
|
||||
```
|
||||
|
@ -73,8 +73,8 @@ public class WordPressTest {
|
||||
PostRequest post = new PostRequest();
|
||||
post.setPostTitle("测试PostName");
|
||||
post.setPostContent("这是一段测试文章内容");
|
||||
post.setCategories("分类");
|
||||
post.setTags("a", "b", "c");
|
||||
post.addCategories("分类");
|
||||
post.addTags("a", "b", "c");
|
||||
post.setPostName("test-post-name");
|
||||
int postId = wp.newPost(post);
|
||||
System.out.println(postId);
|
||||
|
Loading…
x
Reference in New Issue
Block a user