PHP code example of nestboxphp / babbler

1. Go to this page and download the library: Download nestboxphp/babbler 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/ */

    

nestboxphp / babbler example snippets


add_entry(
    string $category,
    string $subCategory,
    string $title,
    string $content,
    string $author,
    string $created = null,
    string $published = "",
    bool   $isDraft = false,
    bool   $isHidden = false
): int|false

edit_entry(
    string|int $entry_id,
    string     $editor,
    string     $category = "",
    string     $subCategory = "",
    string     $title = "",
    string     $content = "",
    string     $published = "",
    bool       $isDraft = null,
    bool       $isHidden = null,
): int|false

delete_entry(int $entry_id): bool

search_entries(string $words, string $category = "*", bool $strict = true, int $buffer = 100): array

search_title(string $title): array

search_url_title(string $title): array

fetch_entry_table(string $orderBy = "", string $sort = "", int $limit = 50, int $start = 0): array

fetch_entry(int $entry_id): array

fetch_categories(): array

fetch_sub_categories(string $category = ''): array

fetch_entries_by_category(string $category, string $subCategory = '', string $orderBy = 'created', string $sort = '', int $start = 0, int $limit = 10): array

fetch_entry_by_category_and_title(string $category, string $title, string $subCategory = ''): array