Skip to content

Commit

Permalink
Abide to the way Joomla wants Http PATCH payload
Browse files Browse the repository at this point in the history
When using PATCH, articletext MUST be splitted in two parts (introtext and fulltext) or use at least just introtext in order to work properly
  • Loading branch information
Mr Alexandre ELISÉ authored Nov 23, 2022
1 parent a7e4c2d commit 0a83e58
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions docs/general-concept/webservices.md
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,8 @@ $articleId = 1; // The Article ID of a specific Article
$data = [
'id' => $articleId,
'title' => 'How to add an article via the Joomla 4 API?',
'articletext' => 'Use the HTTP POST method at the /content/articles endpoint.',
'introtext' => 'When using PATCH, articletext MUST be splitted in two parts or use at least just introtext in order to work properly',
'fulltext' => 'MORE CONTENT if you wish',
];

$dataString = json_encode($data);
Expand Down Expand Up @@ -324,7 +325,8 @@ $articleId = 1; // The Article ID of a specific Article
$data = [
'id' => $articleId,
'title' => 'How to add an article via the Joomla 4 API?',
'articletext' => 'Use the HTTP POST method at the /content/articles endpoint.',
'introtext' => 'When using PATCH, articletext MUST be splitted in two parts or use at least just introtext in order to work properly',
'fulltext' => 'MORE CONTENT if you wish',
];

$dataString = json_encode($data);
Expand Down

0 comments on commit 0a83e58

Please sign in to comment.