@@ -36,8 +36,8 @@ class WordpressClient
36
36
* Create a new client with credentials
37
37
*
38
38
* @param string $xmlrpcEndPoint The wordpress XML-RPC endpoint
39
- * @param string $username The client's username
40
- * @param string $password The client's password
39
+ * @param string $username The client's username
40
+ * @param string $password The client's password
41
41
* @param \Illuminate\Log\Writer $logger
42
42
*/
43
43
public function __construct ($ xmlrpcEndPoint , $ username , $ password , Writer $ logger = null )
@@ -137,8 +137,9 @@ function getAuth()
137
137
/**
138
138
* Retrieve a post of any registered post type.
139
139
*
140
- * @param integer $postId post id The id of selected post
141
- * @param array $fields Optional. List of field or meta-field names to include in response.
140
+ * @param integer $postId the id of selected post
141
+ * @param array $fields (optional) list of field or meta-field names to include in response.
142
+ *
142
143
* @return array
143
144
* @link http://codex.wordpress.org/XML-RPC_WordPress_API/Posts#wp.getPosts
144
145
*/
@@ -158,8 +159,9 @@ function getPost($postId, array $fields = array())
158
159
/**
159
160
* Retrieve list of posts of any registered post type.
160
161
*
161
- * @param array $filters Optional
162
- * @param array $fields Optional
162
+ * @param array $filters optional
163
+ * @param array $fields optional
164
+ *
163
165
* @return array array of struct
164
166
* @link http://codex.wordpress.org/XML-RPC_WordPress_API/Posts#wp.getPosts
165
167
*/
@@ -176,11 +178,12 @@ function getPosts(array $filters = array(), array $fields = array())
176
178
/**
177
179
* Create a new post of any registered post type.
178
180
*
179
- * @param string $title the post title
180
- * @param string $body the post body
181
- * @param array $categorieIds the list of category ids
182
- * @param integer $thumbnailId the thumbnail id
183
- * @param array $content the content array, see more at wordpress documentation
181
+ * @param string $title the post title
182
+ * @param string $body the post body
183
+ * @param array $categorieIds the list of category ids
184
+ * @param integer $thumbnailId the thumbnail id
185
+ * @param array $content the content array, see more at wordpress documentation
186
+ *
184
187
* @return integer the new post id
185
188
*
186
189
* @link http://codex.wordpress.org/XML-RPC_WordPress_API/Posts#wp.newPost
@@ -202,12 +205,13 @@ function newPost($title, $body, array $content = array())
202
205
/**
203
206
* Edit an existing post of any registered post type.
204
207
*
205
- * @param integer $postId the id of selected post
206
- * @param string $title the new title
207
- * @param string $body the new body
208
- * @param array $categorieIds the new list of category ids
209
- * @param integer $thumbnailId the new thumbnail id
210
- * @param array $content the advanced array
208
+ * @param integer $postId the id of selected post
209
+ * @param string $title the new title
210
+ * @param string $body the new body
211
+ * @param array $categorieIds the new list of category ids
212
+ * @param integer $thumbnailId the new thumbnail id
213
+ * @param array $content the advanced array
214
+ *
211
215
* @return boolean
212
216
*
213
217
* @link http://codex.wordpress.org/XML-RPC_WordPress_API/Posts#wp.editPost
@@ -221,7 +225,8 @@ function editPost($postId, array $content)
221
225
/**
222
226
* Delete an existing post of any registered post type.
223
227
*
224
- * @param integer $postId the id of selected post
228
+ * @param integer $postId the id of selected post
229
+ *
225
230
* @return boolean
226
231
*
227
232
* @link http://codex.wordpress.org/XML-RPC_WordPress_API/Posts#wp.deletePost
@@ -236,7 +241,8 @@ function deletePost($postId)
236
241
* Retrieve a registered post type.
237
242
*
238
243
* @param string $postTypeName the post type name
239
- * @param array $fields Optional. List of field or meta-field names to include in response.
244
+ * @param array $fields (optional) list of field or meta-field names to include in response.
245
+ *
240
246
* @return array
241
247
*
242
248
* @link http://codex.wordpress.org/XML-RPC_WordPress_API/Posts#wp.getPostType
@@ -252,6 +258,7 @@ function getPostType($postTypeName, array $fields = array())
252
258
*
253
259
* @param array $filter
254
260
* @param array $fields
261
+ *
255
262
* @return array list of struct
256
263
*
257
264
* @link http://codex.wordpress.org/XML-RPC_WordPress_API/Posts#wp.getPostTypes
@@ -292,6 +299,7 @@ function getPostStatusList()
292
299
* Retrieve information about a taxonomy.
293
300
*
294
301
* @param string $taxonomy the name of the selected taxonomy
302
+ *
295
303
* @return array taxonomy information
296
304
*
297
305
* @link http://codex.wordpress.org/XML-RPC_WordPress_API/Taxonomies#wp.getTaxonomy
@@ -319,7 +327,8 @@ function getTaxonomies()
319
327
* Retrieve a taxonomy term.
320
328
*
321
329
* @param integer $termId
322
- * @param string $taxonomy
330
+ * @param string $taxonomy
331
+ *
323
332
* @return array
324
333
*
325
334
* @link http://codex.wordpress.org/XML-RPC_WordPress_API/Taxonomies#wp.getTerm
@@ -334,7 +343,8 @@ function getTerm($termId, $taxonomy)
334
343
* Retrieve list of terms in a taxonomy.
335
344
*
336
345
* @param string $taxonomy
337
- * @param array $filter
346
+ * @param array $filter
347
+ *
338
348
* @return array
339
349
*
340
350
* @link http://codex.wordpress.org/XML-RPC_WordPress_API/Taxonomies#wp.getTerms
@@ -353,6 +363,7 @@ function getTerms($taxonomy, array $filter = array())
353
363
* @param string $slug
354
364
* @param string $description
355
365
* @param integer $parentId
366
+ *
356
367
* @return integer new term id
357
368
*
358
369
* @link http://codex.wordpress.org/XML-RPC_WordPress_API/Taxonomies#wp.newTerm
@@ -385,6 +396,7 @@ function newTerm($name, $taxomony, $slug = null, $description = null, $parentId
385
396
* @param integer $termId
386
397
* @param string $taxonomy
387
398
* @param array $content
399
+ *
388
400
* @return boolean
389
401
*
390
402
* @link http://codex.wordpress.org/XML-RPC_WordPress_API/Taxonomies#wp.editTerm
@@ -401,6 +413,7 @@ function editTerm($termId, $taxonomy, array $content = array())
401
413
*
402
414
* @param integer $termId
403
415
* @param string $taxonomy
416
+ *
404
417
* @return boolean
405
418
*
406
419
* @link http://codex.wordpress.org/XML-RPC_WordPress_API/Taxonomies#wp.deleteTerm
@@ -415,6 +428,7 @@ function deleteTerm($termId, $taxonomy)
415
428
* Retrieve a media item (i.e, attachment).
416
429
*
417
430
* @param integer $itemId
431
+ *
418
432
* @return array
419
433
*
420
434
* @link http://codex.wordpress.org/XML-RPC_WordPress_API/Media#wp.getMediaItem
@@ -429,6 +443,7 @@ function getMediaItem($itemId)
429
443
* Retrieve list of media items.
430
444
*
431
445
* @param array $filter
446
+ *
432
447
* @return array
433
448
*
434
449
* @link http://codex.wordpress.org/XML-RPC_WordPress_API/Media#wp.getMediaLibrary
@@ -442,9 +457,12 @@ function getMediaLibrary(array $filter = array())
442
457
/**
443
458
* Upload a media file.
444
459
*
445
- * @param string $name
446
- * @param string $mime
447
- * @param string $bits Binary data (no encoded)
460
+ * @param string $name file name
461
+ * @param string $mime file mime type
462
+ * @param string $bits binary data (no encoded)
463
+ * @param boolean $overwrite (optional)
464
+ * @param int $postId (optional)
465
+ *
448
466
* @return array
449
467
*
450
468
* @link http://codex.wordpress.org/XML-RPC_WordPress_API/Media#wp.uploadFile
@@ -473,6 +491,7 @@ function uploadFile($name, $mime, $bits, $overwrite = null, $postId = null)
473
491
* Retrieve comment count for a specific post.
474
492
*
475
493
* @param integer $postId
494
+ *
476
495
* @return integer
477
496
*
478
497
* @link http://codex.wordpress.org/XML-RPC_WordPress_API/Comments#wp.getCommentCount
@@ -501,6 +520,7 @@ function getComment($commentId)
501
520
* Retrieve list of comments.
502
521
*
503
522
* @param array $filter
523
+ *
504
524
* @return array
505
525
*
506
526
* @link http://codex.wordpress.org/XML-RPC_WordPress_API/Comments#wp.getComments
@@ -515,7 +535,8 @@ function getComments(array $filter = array())
515
535
* Create a new comment.
516
536
*
517
537
* @param integer $post_id
518
- * @param array $comment
538
+ * @param array $comment
539
+ *
519
540
* @return integer new comment_id
520
541
*
521
542
* @link http://codex.wordpress.org/XML-RPC_WordPress_API/Comments#wp.newComment
@@ -530,7 +551,8 @@ function newComment($post_id, array $comment)
530
551
* Edit an existing comment.
531
552
*
532
553
* @param integer $commentId
533
- * @param array $comment
554
+ * @param array $comment
555
+ *
534
556
* @return boolean
535
557
*
536
558
* @link http://codex.wordpress.org/XML-RPC_WordPress_API/Comments#wp.editComment
@@ -545,6 +567,7 @@ function editComment($commentId, array $comment)
545
567
* Remove an existing comment.
546
568
*
547
569
* @param integer $commentId
570
+ *
548
571
* @return boolean
549
572
*
550
573
* @link http://codex.wordpress.org/XML-RPC_WordPress_API/Comments#wp.deleteComment
@@ -557,6 +580,7 @@ function deleteComment($commentId)
557
580
558
581
/**
559
582
* Retrieve list of comment statuses.
583
+ *
560
584
* @return array
561
585
*
562
586
* @link http://codex.wordpress.org/XML-RPC_WordPress_API/Comments#wp.getCommentStatusList
@@ -571,6 +595,7 @@ function getCommentStatusList()
571
595
* Retrieve blog options.
572
596
*
573
597
* @param array $options
598
+ *
574
599
* @return array
575
600
*
576
601
* @link http://codex.wordpress.org/XML-RPC_WordPress_API/Options#wp.getOptions
@@ -592,6 +617,7 @@ function getOptions(array $options = array())
592
617
* Edit blog options.
593
618
*
594
619
* @param array $options
620
+ *
595
621
* @return array
596
622
*
597
623
* @link http://codex.wordpress.org/XML-RPC_WordPress_API/Options#wp.setOptions
@@ -657,6 +683,7 @@ function getUsers(array $filters = array(), array $fields = array())
657
683
* Retrieve profile of the requesting user.
658
684
*
659
685
* @param array $fields
686
+ *
660
687
* @return array
661
688
*
662
689
* @link http://codex.wordpress.org/XML-RPC_WordPress_API/Users#wp.getProfile
@@ -675,6 +702,7 @@ function getProfile(array $fields = array())
675
702
* Edit profile of the requesting user.
676
703
*
677
704
* @param array $content
705
+ *
678
706
* @return boolean
679
707
*
680
708
* http://codex.wordpress.org/XML-RPC_WordPress_API/Users#wp.editProfile
0 commit comments