URL Parameter Stripper
Removes specified substrings or query parameters from URLs before saving them to the DB (posts, comments, options, meta).
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/saulogt/url-parameter-stripper/archive/refs/heads/main.zipA WordPress plugin that strips unwanted substrings or query parameters from URLs before they are persisted to the database. This repository also contains tooling to validate the plugin structure and produce a submission-ready ZIP file for the WordPress.org plugin directory.
Requirements
- Node.js 18+ and pnpm (see
packageManagerfield) - PHP 6.0+ / WordPress 4.5+ for runtime (per plugin header)
zipavailable on your PATH (used by the bundling task)
Project structure highlights
url-parameter-stripper.php: Main plugin entrypointadmin/,includes/: PHP sourceslanguages/: i18n files.distignore: Files excluded from release bundles
Development scripts
pnpm install # install JS tooling dependencies
pnpm run test # run minimal structural checks
pnpm run bundle # uses wp-scripts dist-zip to create url-parameter-stripper.zip
pnpm run test
Runs the PHPUnit suite defined in tests/, currently asserting that the root plugin files exist and include the expected plugin header. Extend this suite as you add more automated checks.
pnpm run bundle
Uses @wordpress/scripts' dist-zip command to package the plugin, respecting .distignore, and outputs url-parameter-stripper.zip at the repository root. Re-run whenever you need a fresh bundle; the previous archive is overwritten.
Release checklist
- Update version numbers and changelog/readme as needed.
- Run
pnpm run testand resolve failures. - (Optional) regenerate translation catalogues via Composer/WP-CLI (
composer run makepot). - Run
pnpm run bundleand verify the reported ZIP size. - Unzip locally (or inspect via
zipinfo) to confirm it contains the plugin slug folder with the expected assets. - Submit
url-parameter-stripper.zipto WordPress.org or deploy to your chosen distribution channel.
Contributing
Bug reports and pull requests are welcome. Please follow WordPress coding standards and keep the bundle workflow in sync if you reorganize files.