
The short answer: WordPress has, in the dashboard, a file editor that lets you change the code of the theme and plugins. One typo there takes the site down, and whoever gets into the dashboard without permission can plant malicious code. One line in wp-config.php switches it off. There are two or three more settings in the same file that harden the site.
The settings
| Line | What it does |
| define( 'DISALLOW_FILE_EDIT', true ); | Hides the theme and plugin editors in the dashboard. Touches nothing else. The most useful. |
| define( 'FORCE_SSL_ADMIN', true ); | Forces the dashboard and login onto https. Only if the site already has a certificate. |
| define( 'WP_POST_REVISIONS', 10 ); | Keeps only the latest versions of each post, instead of all: it helps keep the database lean. |
| define( 'DISALLOW_FILE_MODS', true ); | Careful: it also blocks installing and updating plugins, themes and WordPress itself. Only for sites managed another way. |
| Security keys (salts) | Changing them logs everybody out of the dashboard. Useful after a suspected break-in. |
Step by step
|
|
|
|
|
| This reinforces; it does not protect on its own. A switched-off editor does not stop someone who already has an administrator password from installing a malicious plugin. The real defence is a well-protected login and up-to-date plugins: Protecting the WordPress login. |
| If the file was damaged, see Rebuilding the wp-config.php connection. Another door to consider: XML-RPC. |
|
Want help reviewing your WordPress security? Open a ticket with the address. Open a support ticket |
RECOMMENDED PRODUCT WordPress hosting One-click install, updates handled, and speed that holds up. from 5.940,00 Kz/mo (3-year plan, with coupon) See plans |
- 0 Users Found This Useful











