Versioning
Handle the versioning of content items
since |
4.0.0 |
---|---|
package |
Joomla CMS |
Methods
delete
Method to delete the history for an item.
delete( typeAlias, id) :
static
since |
4.0.0 |
---|
Arguments
- typeAlias
string
Typealias of the component- id
int
ID of the content item to delete
Response
bool
true on success, otherwise false.
get
Method to get a list of available versions of this item.
get( typeAlias, id) : object||string|int
static
since |
4.0.0 |
---|
Arguments
- typeAlias
string
Typealias of the component- id
int
ID of the content item to get
Response
array<string|int, object>
A list of history items
store
Method to save a version snapshot to the content history table.
store( typeAlias, id, data, note = '') :
static
since |
4.0.0 |
---|
Arguments
- typeAlias
string
Typealias of the content type- id
int
ID of the content item- data
mixed
Array or object of data that can be en- and decoded into JSON- note
string
Note for the version to store
Response
bool
True on success, otherwise false.