Overview #
TrafficShield provides a WordPress integration that allows users to cloak their pages without modifying core files manually. This can be done via a plugin or by adding the script in theme files.
Method 1: Using a Plugin #
- Install a Code Insertion Plugin
- Go to WordPress Admin Panel > Plugins > Add New
- Search for Insert Headers and Footers or a similar plugin.
- Install and activate it.
- Add the JavaScript Code
- Go to Settings > Insert Headers and Footers
- Paste the TrafficShield JavaScript snippet in the Footer section.
- Save changes.
Method 2: Editing Theme Files #
- Open Your Theme Editor
- Navigate to Appearance > Theme File Editor
- Open the
header.php
file.
- Insert the JavaScript Code
- Paste the following script before the closing
</head>
tag:<script src="https://yourdomain.com/cloak.js"></script>
- Paste the following script before the closing
- Save and Verify
- Visit your website and check if cloaking works as expected.