Keeps staging, development and local copies from acting like the live site: intercepts outgoing email, blocks indexing, stops WooCommerce webhooks and marks the environment in the admin.
- Author: BusinessCom - https://businesscom.gr
- Developed and maintained by George Vasiliades - https://github.com/Poseidonas
- License: GPL-2.0-or-later
- Requires WordPress 6.7+ and PHP 8.0+
WordPress knows which environment it runs in through wp_get_environment_type(), but it does almost nothing with that knowledge. A staging copy still emails real customers, still calls live webhooks and can still be indexed by search engines.
This plugin acts on that value. On production it does nothing at all: every guard is skipped before it is registered, so the plugin can stay in a standard plugin set and only becomes active on the copies where it belongs.
| Setting | Effect | Default |
|---|---|---|
| Treat this site as | Automatic uses the WP_ENVIRONMENT_TYPE constant or environment variable, and falls back to the site address (localhost, .local, .test, staging., dev., and the staging hostnames of common hosts). Any of the four environments can be chosen manually instead. |
Automatic |
| Show the environment in the toolbar | Adds the environment name to the admin toolbar for logged-in users. | On |
| Show a notice on the login screen | States which environment the visitor is signing in to. | On |
If nothing is declared and the address looks like a normal domain, the site is treated as production and no guard runs. The settings page always states which environment is in use and where that came from.
Automatic detection checks, in this order: a manual choice on the settings page, the WP_ENVIRONMENT_TYPE constant, the WP_ENVIRONMENT_TYPE environment variable, and finally the site address:
- Local -
localhost,127.0.0.1,::1, or a host ending in.local,.test,.localhost,.wip,.ddev.site,.lndo.site. - Staging - hosts of common managed platforms (
.wpengine.com,.wpenginepowered.com,.kinsta.cloud,.pantheonsite.io,.flywheelsites.com,.flywheelstaging.com,.cloudwaysapps.com,.myftpupload.com,.instawp.xyz,.wpmudev.host,.tempurl.host), hosts starting withstaging.,stage.,test.,testing.,preprod.,uat.,sandbox.,demo., or containing-staging.,-stage.,-dev.,-test.,.staging.,.dev.. - Development - hosts starting with
dev.ordevelopment..
Every one of these lists can be changed with the filters listed below.
| Setting | Effect | Default |
|---|---|---|
| Outgoing email | Block everything, redirect everything to one address, send only to listed recipients, or send normally. | Block everything |
| Redirect address | Where redirected mail goes. The original recipients are preserved in an X-Original-To header. If it is empty, mail is blocked instead. |
empty |
| Allowed recipients | One per line, full addresses (me@example.com) or whole domains (@example.com). Recipients that do not match are removed; if none is left, the message is blocked. |
empty |
| Keep a log of intercepted email | Stores the last 25 intercepted messages with their content and shows them on the settings page. | On |
Blocked messages are reported back to WordPress as sent, so password resets, order flows and forms do not fail. The log is what makes blocking usable: the reset link or order email can be read from the settings page instead of arriving in a real inbox.
| Setting | Effect | Default |
|---|---|---|
| Keep the site out of search engines | Forces search engine visibility off through a filter, sends X-Robots-Tag: noindex, nofollow and disallows crawling in robots.txt. The value saved in the database is never changed. |
On |
| Lock the search engine visibility setting | Prevents the setting on the Reading screen from being changed, with a notice on that screen explaining why. | On |
Shown only when WooCommerce is active.
| Setting | Effect | Default |
|---|---|---|
| Block webhook delivery | Stops WooCommerce webhooks from reaching accounting, shipping or CRM systems. | On |
| Restrict payment gateways | Only the selected gateways stay available at checkout. | On |
| Gateways to keep | Checklist of the gateways registered on the site. | Cash on delivery, bank transfer, cheque |
| Block WooCommerce email separately | Stops order and account email even when outgoing email is set to send normally. | Off |
Email stopped by this switch is dropped before it reaches WordPress mail, so it does not appear in the mail log. Use the outgoing email setting above when those messages should be logged. The plugin declares compatibility with WooCommerce high-performance order storage (HPOS) and the block-based cart and checkout.
| Setting | Effect | Default |
|---|---|---|
| Disable WP-Cron | Stops scheduled tasks from running and refuses new ones. | Off |
| Pause Action Scheduler | Stops the background queue used by WooCommerce and other plugins. | Off |
| Block outgoing requests | Refuses HTTP requests to hosts that are not on the list. Requests to the site itself are always allowed. | Off |
| Allowed hosts | One host per line; subdomains of a listed host are allowed too. | WordPress.org and GitHub hosts |
Settings > Staging. Requires the manage_options capability. The interface is in English and switches to Greek automatically when the site or the user language is Greek.
icxcnika_staging_settings- all settings before they are applied.icxcnika_staging_local_hosts,icxcnika_staging_local_suffixes,icxcnika_staging_host_patterns,icxcnika_staging_host_prefixes,icxcnika_staging_host_fragments- the hostname rules used for detection.icxcnika_staging_http_allowlist- the list of allowed hosts.icxcnika_staging_allowed_gateways- the list of allowed payment gateways.
- Option
icxcnika_staging_settings(the settings). - Option
icxcnika_staging_mail_log(the last 25 intercepted messages, not autoloaded, message bodies truncated at 10,000 characters). - Transient
icxcnika_staging_release(cached GitHub release lookup, 12 hours).
Updates are delivered from GitHub Releases of this repository. WordPress shows them on the Plugins screen like any other update. The build published on wordpress.org has no updater of its own and updates from there. The plugin contacts no other service.
Deleting the plugin removes the options, the mail log, the transient and the cron event. Nothing is left behind.
Εμποδίζει τα αντίγραφα staging, development και local να συμπεριφέρονται σαν το ζωντανό site: αναχαιτίζει τα εξερχόμενα email, μπλοκάρει την ευρετηρίαση, σταματά τα webhooks του WooCommerce και σημειώνει το περιβάλλον στη διαχείριση.
- Δημιουργός: BusinessCom - https://businesscom.gr
- Ανάπτυξη και συντήρηση: George Vasiliades - https://github.com/Poseidonas
- Άδεια: GPL-2.0-or-later
- Απαιτεί WordPress 6.7+ και PHP 8.0+
Το WordPress γνωρίζει σε ποιο περιβάλλον τρέχει μέσω της wp_get_environment_type(), αλλά δεν κάνει σχεδόν τίποτα με αυτή τη γνώση. Ένα αντίγραφο staging συνεχίζει να στέλνει email σε πραγματικούς πελάτες, να καλεί ζωντανά webhooks και μπορεί να μπει στο ευρετήριο των μηχανών αναζήτησης.
Το plugin αξιοποιεί αυτή την τιμή. Στην παραγωγή δεν κάνει απολύτως τίποτα: κάθε προστασία παρακάμπτεται πριν καν καταχωρηθεί, οπότε το plugin μπορεί να βρίσκεται στο σταθερό σετ πρόσθετων και να ενεργοποιείται μόνο στα αντίγραφα όπου ανήκει.
| Ρύθμιση | Ενέργεια | Προεπιλογή |
|---|---|---|
| Αντιμετώπιση του site ως | Η αυτόματη επιλογή χρησιμοποιεί τη σταθερά ή τη μεταβλητή WP_ENVIRONMENT_TYPE και εναλλακτικά τη διεύθυνση του site (localhost, .local, .test, staging., dev., καθώς και τα hostnames staging γνωστών παρόχων). Εναλλακτικά επιλέγετε χειροκίνητα ένα από τα τέσσερα περιβάλλοντα. |
Αυτόματα |
| Εμφάνιση του περιβάλλοντος στη γραμμή εργαλείων | Προσθέτει το όνομα του περιβάλλοντος στη γραμμή διαχείρισης για τους συνδεδεμένους χρήστες. | Ενεργό |
| Εμφάνιση σημείωσης στην οθόνη σύνδεσης | Δηλώνει σε ποιο περιβάλλον συνδέεται ο επισκέπτης. | Ενεργό |
Αν δεν έχει δηλωθεί τίποτα και η διεύθυνση μοιάζει με κανονικό domain, το site αντιμετωπίζεται ως παραγωγή και καμία προστασία δεν τρέχει. Η σελίδα ρυθμίσεων δηλώνει πάντα ποιο περιβάλλον ισχύει και από πού προέκυψε.
Η αυτόματη ανίχνευση ελέγχει, με αυτή τη σειρά: τη χειροκίνητη επιλογή στη σελίδα ρυθμίσεων, τη σταθερά WP_ENVIRONMENT_TYPE, τη μεταβλητή περιβάλλοντος WP_ENVIRONMENT_TYPE και τέλος τη διεύθυνση του site:
- Local -
localhost,127.0.0.1,::1, ή host που τελειώνει σε.local,.test,.localhost,.wip,.ddev.site,.lndo.site. - Staging - hosts γνωστών managed παρόχων (
.wpengine.com,.wpenginepowered.com,.kinsta.cloud,.pantheonsite.io,.flywheelsites.com,.flywheelstaging.com,.cloudwaysapps.com,.myftpupload.com,.instawp.xyz,.wpmudev.host,.tempurl.host), hosts που ξεκινούν μεstaging.,stage.,test.,testing.,preprod.,uat.,sandbox.,demo., ή περιέχουν-staging.,-stage.,-dev.,-test.,.staging.,.dev.. - Development - hosts που ξεκινούν με
dev.ήdevelopment..
Κάθε μία από αυτές τις λίστες αλλάζει με τα φίλτρα που αναφέρονται παρακάτω.
| Ρύθμιση | Ενέργεια | Προεπιλογή |
|---|---|---|
| Εξερχόμενα email | Μπλοκάρισμα όλων, ανακατεύθυνση όλων σε μία διεύθυνση, αποστολή μόνο σε καταχωρημένους παραλήπτες, ή κανονική αποστολή. | Μπλοκάρισμα όλων |
| Διεύθυνση ανακατεύθυνσης | Πού πηγαίνουν τα ανακατευθυνόμενα μηνύματα. Οι αρχικοί παραλήπτες διατηρούνται σε κεφαλίδα X-Original-To. Αν είναι κενή, τα μηνύματα μπλοκάρονται. |
κενό |
| Επιτρεπόμενοι παραλήπτες | Ένας ανά γραμμή, πλήρεις διευθύνσεις (me@example.com) ή ολόκληρα domains (@example.com). Όσοι δεν ταιριάζουν αφαιρούνται· αν δεν μείνει κανείς, το μήνυμα μπλοκάρεται. |
κενό |
| Τήρηση αρχείου αναχαιτισμένων email | Αποθηκεύει τα τελευταία 25 μηνύματα με το περιεχόμενό τους και τα εμφανίζει στη σελίδα ρυθμίσεων. | Ενεργό |
Τα μπλοκαρισμένα μηνύματα αναφέρονται στο WordPress ως απεσταλμένα, ώστε να μη σπάνε οι επαναφορές κωδικού, οι ροές παραγγελιών και οι φόρμες. Το αρχείο είναι αυτό που κάνει το μπλοκάρισμα χρηστικό: ο σύνδεσμος επαναφοράς ή το email παραγγελίας διαβάζεται από τη σελίδα ρυθμίσεων αντί να φτάνει σε πραγματικό γραμματοκιβώτιο.
| Ρύθμιση | Ενέργεια | Προεπιλογή |
|---|---|---|
| Αποκλεισμός από τις μηχανές αναζήτησης | Επιβάλλει την απενεργοποίηση της ορατότητας μέσω φίλτρου, στέλνει X-Robots-Tag: noindex, nofollow και απαγορεύει την ανίχνευση στο robots.txt. Η τιμή που είναι αποθηκευμένη στη βάση δεν αλλάζει ποτέ. |
Ενεργό |
| Κλείδωμα της ρύθμισης ορατότητας | Εμποδίζει την αλλαγή της ρύθμισης στην οθόνη Ανάγνωση, με σχετική σημείωση σε εκείνη την οθόνη. | Ενεργό |
Εμφανίζεται μόνο όταν το WooCommerce είναι ενεργό.
| Ρύθμιση | Ενέργεια | Προεπιλογή |
|---|---|---|
| Μπλοκάρισμα παράδοσης webhooks | Σταματά τα webhooks του WooCommerce από το να φτάνουν σε λογιστικά, μεταφορικά ή CRM συστήματα. | Ενεργό |
| Περιορισμός τρόπων πληρωμής | Στην ολοκλήρωση αγοράς παραμένουν διαθέσιμοι μόνο οι επιλεγμένοι. | Ενεργό |
| Τρόποι πληρωμής που παραμένουν | Λίστα με τους τρόπους πληρωμής που είναι καταχωρημένοι στο site. | Αντικαταβολή, τραπεζική κατάθεση, επιταγή |
| Ξεχωριστό μπλοκάρισμα email του WooCommerce | Σταματά τα email παραγγελιών και λογαριασμού ακόμα και όταν τα εξερχόμενα email είναι σε κανονική αποστολή. | Ανενεργό |
Τα email που σταματούν από αυτόν τον διακόπτη απορρίπτονται πριν φτάσουν στην αποστολή email του WordPress, οπότε δεν εμφανίζονται στο αρχείο email. Χρησιμοποιήστε τη ρύθμιση εξερχόμενων email παραπάνω όταν θέλετε αυτά τα μηνύματα να καταγράφονται. Το plugin δηλώνει συμβατότητα με την αποθήκευση παραγγελιών υψηλής απόδοσης (HPOS) του WooCommerce και με το καλάθι και την ολοκλήρωση αγοράς που βασίζονται σε blocks.
| Ρύθμιση | Ενέργεια | Προεπιλογή |
|---|---|---|
| Απενεργοποίηση WP-Cron | Σταματά την εκτέλεση προγραμματισμένων εργασιών και αρνείται νέες. | Ανενεργό |
| Παύση του Action Scheduler | Σταματά την ουρά παρασκηνίου που χρησιμοποιεί το WooCommerce και άλλα plugins. | Ανενεργό |
| Μπλοκάρισμα εξερχόμενων αιτημάτων | Αρνείται αιτήματα HTTP προς hosts που δεν είναι στη λίστα. Τα αιτήματα προς το ίδιο το site επιτρέπονται πάντα. | Ανενεργό |
| Επιτρεπόμενοι hosts | Ένας ανά γραμμή· επιτρέπονται και τα subdomains ενός καταχωρημένου host. | Hosts του WordPress.org και του GitHub |
Ρυθμίσεις > Staging. Απαιτεί τη δυνατότητα manage_options. Το περιβάλλον είναι στα Αγγλικά και γυρίζει αυτόματα στα Ελληνικά όταν η γλώσσα του site ή του χρήστη είναι Ελληνικά.
icxcnika_staging_settings- όλες οι ρυθμίσεις πριν εφαρμοστούν.icxcnika_staging_local_hosts,icxcnika_staging_local_suffixes,icxcnika_staging_host_patterns,icxcnika_staging_host_prefixes,icxcnika_staging_host_fragments- οι κανόνες hostname που χρησιμοποιούνται για την ανίχνευση.icxcnika_staging_http_allowlist- η λίστα επιτρεπόμενων hosts.icxcnika_staging_allowed_gateways- η λίστα επιτρεπόμενων τρόπων πληρωμής.
- Option
icxcnika_staging_settings(οι ρυθμίσεις). - Option
icxcnika_staging_mail_log(τα τελευταία 25 αναχαιτισμένα μηνύματα, χωρίς autoload, με το σώμα κομμένο στους 10.000 χαρακτήρες). - Transient
icxcnika_staging_release(cache της αναζήτησης έκδοσης στο GitHub, 12 ώρες).
Οι ενημερώσεις έρχονται από τα GitHub Releases αυτού του αποθετηρίου. Το WordPress τις εμφανίζει στη σελίδα Πρόσθετα όπως κάθε άλλη ενημέρωση. Το build που δημοσιεύεται στο wordpress.org δεν έχει δικό του updater και ενημερώνεται από εκεί. Το plugin δεν επικοινωνεί με καμία άλλη υπηρεσία.
Η διαγραφή του plugin αφαιρεί τα options, το αρχείο email, το transient και το cron event. Δεν μένει τίποτα πίσω.