One confusing part of upgrading to MT4 is all that all the new templates and my old templates end up all mixed together. I created a “Temp41” blog from scratch just to have a reference set of code to help sort out the mess.
I missed that the javascript template is now “mt.js” instead of “mt-site.js” and that both were still being generated. Since this is where I store the CCode/TCode javascript (anti-spam), it was important to retire mt-site.js and get the obfuscator function into mt.js.
CCode and TCode works in before saving spam feedbacks to MT system. CCode/TCode makes it very difficult for spam-bots to guess tb URL and the required ct input fields. Target ct/tb URLs to send spams are calcuated from unrevealed entry/trackback data and obfuscated by Javascript.
Steps to install CCode/TCode in MT4 (vs. MT3.)
- Download MT4 version.
- Remove old plug-in code and add new plug-in code in MT system.
- Place obfuscator.js code into: mt.js template:
mt41:default_templates:javascript.mtml - Refresh mt.js in each blog to bring it in.
- Install the tag into the Comments Form template. This is an improvement because the new sub-template approach means only updating one sub-template vs. multiple templates under MT3. Put it under this line:<input type=”hidden” name=”entry_id” value=”” />
- Republish individual archives.