scaffold_custom_table
Create a custom database table with automated dbDelta migration, CRUD model, activation hook, and uninstall cleanup for WordPress plugins.
Instructions
Generate a custom database table with dbDelta() migration, CRUD model class using $wpdb, activation hook, and uninstall cleanup.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| rootNamespace | Yes | Plugin root namespace | |
| tableName | Yes | Table name without prefix (e.g., "analytics_events") | |
| columns | Yes | Columns as "name:type" pairs (e.g., "event_type:varchar(50),user_id:bigint(20),data:longtext,created_at:datetime") | |
| textDomain | Yes | Plugin text domain |