Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions docs/content_management/content_api/browsing_content.md
Original file line number Diff line number Diff line change
Expand Up @@ -149,14 +149,14 @@

To retrieve the fields of the selected content item, you can use the following command:

```php hl_lines="13-14 16-22"
```php hl_lines="9-10 13-18"
[[= include_file('code_samples/api/public_php_api/src/Command/ViewContentCommand.php', 4, 7) =]] // ...
[[= include_file('code_samples/api/public_php_api/src/Command/ViewContentCommand.php', 37, 55) =]]
}
```

Line 9 shows how [`ContentService::loadContent`](/api/php_api/php_api_reference/classes/Ibexa-Contracts-Core-Repository-ContentService.html#method_loadContent) loads the content item provided to the command.
Line 14 makes use of the [`ContentTypeService`](/api/php_api/php_api_reference/classes/Ibexa-Contracts-Core-Repository-ContentTypeService.html) to retrieve the content type of the requested item.
Line 10 makes use of the [`ContentTypeService`](/api/php_api/php_api_reference/classes/Ibexa-Contracts-Core-Repository-ContentTypeService.html) to retrieve the content type of the requested item.

Check failure on line 159 in docs/content_management/content_api/browsing_content.md

View workflow job for this annotation

GitHub Actions / vale

[vale] docs/content_management/content_api/browsing_content.md#L159

[Ibexa.VariablesGlobal] Use global variable '[[= product_name_base =]]' instead of 'Ibexa'
Raw output
{"message": "[Ibexa.VariablesGlobal] Use global variable '[[= product_name_base =]]' instead of 'Ibexa'", "location": {"path": "docs/content_management/content_api/browsing_content.md", "range": {"start": {"line": 159, "column": 88}}}, "severity": "ERROR"}

Lines 12-19 iterate over fields defined by the content type.
For each field they print out its identifier, and then using [`FieldTypeService`](/api/php_api/php_api_reference/classes/Ibexa-Contracts-Core-Repository-FieldTypeService.html) retrieve the field's value and print it out to the console.
Expand Down