Cat Picks
WJCT WordPress Skills Test Repo for plugin
by Shoaib Chaudhry · github.com/shoaib707/cat-picks · website
★ 0stars
0forks
Install
No release zip yet. The repository archive installs, but the folder name will carry the branch suffix and updates will not flow:
wp plugin install https://github.com/shoaib707/cat-picks/archive/refs/heads/main.zipA WordPress plugin built for the WJCT Full Stack Developer skills test.
What It Does
- Registers a public custom post type named Cat Picks.
- Adds a Featured By meta field to Cat Picks in WordPress admin.
- Saves the field with nonce, capability, and sanitization checks.
- Displays the Featured By value on the front end when viewing a single Cat Pick.
Note: the prompt says to display the value on a single Staff Pick. Since the requested custom post type is Cat Picks, this plugin displays it on single Cat Pick views.
Installation
- Copy this folder into
wp-content/plugins/cat-picks. - In WordPress admin, go to Plugins.
- Activate Cat Picks.
Testing
- In WordPress admin, go to Cat Picks > Add New.
- Add a title and content.
- Enter a value in the Featured By meta box.
- Publish the Cat Pick.
- View the single Cat Pick on the front end and confirm the Featured By value appears below the content.
With More Time
- I would add a small block or template part integration so themes can place the Featured By value more flexibly.
- I would add automated tests around post type registration and meta saving if this were going into a larger production codebase.
AI Assistance
I used ChatGPT Codex to assist me with the plugin, used WordPress documentation for implementation approach, and drafted this README using ChatGPT.