sinfonie / wordpress_options_item
Library that allows you to save structured data based on the WordPress options saving mechanism.
1.0.0
2020-12-14 22:59 UTC
Requires
- php: >=5.6.0
This package is auto-updated.
Last update: 2025-04-17 04:46:31 UTC
README
Library that allows you to save structured data based on the WordPress options saving mechanism.
- Saves data in the form of an array using the WordPress
network_options
mechanism and creating anItemOption
. - Each ItemOption is a specific table with records, imitating a database table.
- Each ItemOption entry has its own records:
- numeric key
id
, - date added
date_added
, - update date
date_updated
, - user id who added
user_added
, - user id who modified
user_updated
.
- numeric key
- You can cascade delete entries from different ItemOptions. In this case, you must specify a reference to the appropriate record from another ItemOption.
- You can freely specify whether the ItemOptions record writes the
null
value.
Requirements
- PHP > 5.6.0
- Wordpress > 5.3.6
Installation
Install via composer:
composer require sinfonie/wordpress_options_item
Install via git over https:
git clone https://github.com/sinfonie/wordpress_options_item.git
manual download: https://github.com/sinfonie/wordpress_options_item/archive/master.zip
Configuration
Please remember to specify the appropriate path for the library in your project.
You can find simple implementaion in examples below: