PHP code example of ee-objects / entries

1. Go to this page and download the library: Download ee-objects/entries library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

ee-objects / entries example snippets


use EeObjects\Channels\Entries\Entry;

$entry = ee('ee_objects:ChannelEntryService')->getEntry(5079);
if ($entry instanceof Entry) {
    $my_custom_filed = $entry->get('my_custom_filed');

    $entry->set('my_custom_filed', 'Some Value');
    $entry->save();

    $entry->delete();
}