{"id":36976286,"url":"https://github.com/arraypress/edd-register-fields","last_synced_at":"2026-01-13T22:11:51.100Z","repository":{"id":331810150,"uuid":"1020847885","full_name":"arraypress/edd-register-fields","owner":"arraypress","description":"A comprehensive library for registering custom fields in Easy Digital Downloads admin interface.","archived":false,"fork":false,"pushed_at":"2025-12-04T22:11:14.000Z","size":22,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-01-11T13:05:08.463Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/arraypress.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-07-16T13:39:03.000Z","updated_at":"2025-12-04T22:11:18.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/arraypress/edd-register-fields","commit_stats":null,"previous_names":["arraypress/edd-register-fields"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/arraypress/edd-register-fields","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/arraypress%2Fedd-register-fields","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/arraypress%2Fedd-register-fields/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/arraypress%2Fedd-register-fields/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/arraypress%2Fedd-register-fields/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/arraypress","download_url":"https://codeload.github.com/arraypress/edd-register-fields/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/arraypress%2Fedd-register-fields/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28402575,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-13T14:36:09.778Z","status":"ssl_error","status_checked_at":"2026-01-13T14:35:19.697Z","response_time":56,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2026-01-13T22:11:50.565Z","updated_at":"2026-01-13T22:11:51.092Z","avatar_url":"https://github.com/arraypress.png","language":"PHP","readme":"# EDD Register Fields - Custom Field Registration for Easy Digital Downloads\n\nAdd custom fields to Easy Digital Downloads download editor, pricing options, and sidebar metaboxes with a simple, clean API.\n\n## Installation\n\n```bash\ncomposer require arraypress/edd-register-fields\n```\n\n## Basic Usage\n\n### Download Settings Fields\n\nAdd custom fields to the download settings tab:\n\n```php\n// Register custom download settings fields\nedd_register_download_settings_fields( [\n    'product_settings' =\u003e [\n        'title'       =\u003e 'Product Settings',\n        'description' =\u003e 'Additional product configuration options',\n        'fields'      =\u003e [\n            'is_featured' =\u003e [\n                'type'        =\u003e 'checkbox_toggle',\n                'label'       =\u003e 'Featured Product',\n                'description' =\u003e 'Mark this product as featured',\n                'default'     =\u003e false\n            ],\n            'product_weight' =\u003e [\n                'type'        =\u003e 'number',\n                'label'       =\u003e 'Weight (for sorting)',\n                'description' =\u003e 'Higher numbers appear first',\n                'default'     =\u003e 0,\n                'attributes'  =\u003e [\n                    'min' =\u003e 0,\n                    'max' =\u003e 9999\n                ]\n            ]\n        ]\n    ]\n] );\n```\n\n### Single Price Options\n\nAdd fields that appear when variable pricing is disabled:\n\n```php\n// Register single price option fields\nedd_register_single_price_fields( [\n    'license_options' =\u003e [\n        'fields' =\u003e [\n            'site_limit' =\u003e [\n                'type'    =\u003e 'number',\n                'label'   =\u003e 'Site Limit',\n                'default' =\u003e 1,\n                'prefix'  =\u003e 'Max:',\n                'suffix'  =\u003e 'sites'\n            ],\n            'includes_support' =\u003e [\n                'type'    =\u003e 'checkbox_toggle',\n                'label'   =\u003e 'Includes Support',\n                'default' =\u003e true\n            ]\n        ]\n    ]\n] );\n```\n\n### Variable Price Options\n\nAdd fields to each variable price row:\n\n```php\n// Register variable price fields\nedd_register_variable_price_fields( [\n    'license_tiers' =\u003e [\n        'title'  =\u003e 'License Options',\n        'fields' =\u003e [\n            'is_popular' =\u003e [\n                'type'    =\u003e 'checkbox_toggle',\n                'label'   =\u003e 'Popular',\n                'default' =\u003e false\n            ],\n            'license_limit' =\u003e [\n                'type'       =\u003e 'number',\n                'label'      =\u003e 'Site Limit',\n                'default'    =\u003e 1,\n                'attributes' =\u003e [\n                    'min' =\u003e 1,\n                    'max' =\u003e 999\n                ]\n            ]\n        ]\n    ]\n] );\n```\n\n### Sidebar Metaboxes\n\nAdd custom metaboxes to the download editor sidebar:\n\n```php\n// Register sidebar metaboxes\nedd_register_sidebar_metaboxes( [\n    'seo_settings' =\u003e [\n        'title'    =\u003e 'SEO Settings',\n        'priority' =\u003e 'high',\n        'sections' =\u003e [\n            'meta_options' =\u003e [\n                'title'  =\u003e 'Meta Options',\n                'fields' =\u003e [\n                    'meta_title' =\u003e [\n                        'type'  =\u003e 'text',\n                        'label' =\u003e 'Custom Meta Title',\n                        'class' =\u003e 'widefat'\n                    ],\n                    'exclude_sitemap' =\u003e [\n                        'type'    =\u003e 'checkbox_toggle',\n                        'label'   =\u003e 'Exclude from Sitemap',\n                        'default' =\u003e false\n                    ]\n                ]\n            ]\n        ]\n    ]\n] );\n```\n\n### Custom Sections\n\nRegister custom sections with configurable fields:\n\n```php\n// Register custom sections\nedd_register_sections( [\n    'custom_section' =\u003e CustomSection::class\n] );\n\n// Example custom section class\nclass CustomSection extends ArrayPress\\EDD\\Fields\\ConfigurableSection {\n    \n    protected $id = 'custom_section';\n    protected $priority = 25;\n    protected $icon = 'admin-tools';\n\n    protected function get_section_config(): array {\n        return [\n            'title'  =\u003e 'Custom Section',\n            'fields' =\u003e [\n                'custom_field' =\u003e [\n                    'type'        =\u003e 'text',\n                    'label'       =\u003e 'Custom Field',\n                    'description' =\u003e 'A custom field example',\n                    'default'     =\u003e ''\n                ]\n            ]\n        ];\n    }\n}\n```\n\n## Field Types\n\n| Type | Description | Example |\n|------|-------------|---------|\n| `text` | Text input | `'type' =\u003e 'text'` |\n| `textarea` | Multi-line text | `'type' =\u003e 'textarea'` |\n| `number` | Number input | `'type' =\u003e 'number'` |\n| `email` | Email input | `'type' =\u003e 'email'` |\n| `url` | URL input | `'type' =\u003e 'url'` |\n| `select` | Dropdown select | `'type' =\u003e 'select'` |\n| `checkbox` | Checkbox | `'type' =\u003e 'checkbox'` |\n| `checkbox_toggle` | EDD toggle | `'type' =\u003e 'checkbox_toggle'` |\n| `radio` | Radio buttons | `'type' =\u003e 'radio'` |\n| `currency` | Currency input | `'type' =\u003e 'currency'` |\n| `color` | Color picker | `'type' =\u003e 'color'` |\n\n## Field Options\n\n### Common Options\n\n| Option | Description | Example |\n|--------|-------------|---------|\n| `type` | Field type | `'text'` |\n| `label` | Field label | `'Product Name'` |\n| `description` | Help text | `'Enter the product name'` |\n| `default` | Default value | `'Default value'` |\n| `required` | Required field | `true` |\n| `class` | CSS classes | `'regular-text'` |\n| `attributes` | HTML attributes | `['min' =\u003e 0, 'max' =\u003e 100]` |\n\n### Select/Radio Options\n\n```php\n'product_type' =\u003e [\n    'type'    =\u003e 'select',\n    'label'   =\u003e 'Product Type',\n    'options' =\u003e [\n        'digital'  =\u003e 'Digital Product',\n        'physical' =\u003e 'Physical Product',\n        'service'  =\u003e 'Service'\n    ],\n    'default' =\u003e 'digital'\n]\n```\n\n### Number Fields\n\n```php\n'priority' =\u003e [\n    'type'       =\u003e 'number',\n    'label'      =\u003e 'Priority',\n    'default'    =\u003e 0,\n    'attributes' =\u003e [\n        'min'  =\u003e 0,\n        'max'  =\u003e 100,\n        'step' =\u003e 5\n    ]\n]\n```\n\n## Requirements\n\n- PHP 7.4+\n- WordPress 5.0+\n- Easy Digital Downloads 3.0+\n\n## Contributing\n\nContributions are welcome! Please feel free to submit a Pull Request.\n\n## License\n\nThis project is licensed under the GPL-2.0-or-later License.\n\n## Support\n\n- [Documentation](https://github.com/arraypress/edd-register-fields)\n- [Issue Tracker](https://github.com/arraypress/edd-register-fields/issues)","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Farraypress%2Fedd-register-fields","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Farraypress%2Fedd-register-fields","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Farraypress%2Fedd-register-fields/lists"}