Link Cloaking Plugin for WordPress
I’ve created a plugin for WordPress that can cloak outgoing links in your posts and/or pages.
Features
- Choose what to cloak – all links, only the links you specify or no links at all.
- Choose where to cloak – posts, pages or both.
- Configure the URL – you can set the “prefix” part of the URL (see examples below).
- Exception list – links pointing to domains in this list will not be cloaked. For example, this is useful if you have chosen to cloak all links but don’t want to cloak the links to your own domains.
- Compatible with all browsers – the link cloaker plugin doesn’t use JavaScript so it will work even for visitors that have disabled JS.
- “Smart” cloaking – relative, ambiguous or malformed URLs will not be cloaked. Better safe than sorry.
- As of version 1.1, static link cloaking.
New! The premium version of this plugin is now available and includes several new features :
- Cloak links in any part of your site, including the comment section and the sidebar.
- Works with plugin-created links.
- Five new cloaking types – for example, you can display the cloaked URL in a frame, or use a special redirect that hides the referrer.
- Improved link management and click statistics.
- Free automatic updates.
- And more. Check out EclipseCloaker.com for complete details.
Examples
Here’s a link explicitly tagged for cloaking -
<a href="http://evil-guide.tripod.com/"><!--cloak-->A Cloaked Link</a>
And here’s what it looks like in the post – A Cloaked Link
If you have configured the plugin to cloak all links (the default) you don’t need the <!–cloak–> tag inside your links.
Installation
- Download the link-cloaking-plugin.zip file.
- Unzip the file.
- Upload the `link-cloaking-plugin` folder to the `/wp-content/plugins/` directory.
- Activate the plugin through the ‘Plugins’ menu in WordPress.
- (Optional) Go to Options -> Link Cloaking and modify the default settings to your liking.
- Re-save your permalink settings to insert the plugin’s link redirection code to the WordPress .htaccess file :
- WP 2.7 and above : Go to Settings -> Permalinks and click “Save Changes”.
- Older versions of WP : Go to Options -> Permalinks and click “Update Permalinks”.
Download
Version 1.4.1 : link-cloaking-plugin.zip (9 KB)
Requirements :
- WordPress 2.2 – 2.9
mod_rewrite. If “pretty permalinks” work on your blog then you probably have this already.
Sidebar links would be nice
Other than that, a nice handy plug-in.
That’s possible in the premium version of the plugin
Hi White Shadow!
I am very curious about the premium version of Link Cloaking. Just one question as I am currently using the free Link Cloaking Plugin with manual cloaking: can I just switch to the premium version with auto cloaking or are there any preparations neccessary I should be aware of?
That depends on what you mean by “manual cloaking” :
If you mean using the <!–cloak–> tag to specify which links get cloaked, then you can just switch to the premium version with zero hassle. The new plugin is backwards-compatible and will continue to cloak the tagged links.
If you’re referring to the “static” links feature instead, there will be one additional step necessary after you’ve installed the premium version : you’ll need to go to Tools -> Cloaked Links -> Named and click the “Import” button to import those links in the new version’s database.
In general, the update process is intended to be as painless as possible, but if you have any problems you can always ask me
I am using Wordpress 2.8.4. I have set up a new site with just a home page and one post, but when I click on this post it seems to default to the home page and that’s the URL that is shown. I have set up test posts so that I have several and they all do the same thing. I have tried the suggested remedy of putting the code above the wordpress code in the .htaccess file, but still the only page displaying is the home page, no matter which post I click on. And, whenever I update my permalinks the code is reinserted in its original position below the wordpress code, so that I then have the code both above and below the wordpress code.
I have deactivated all other plugins and reverted to the wordpress default theme and this problem only occurs when your plugin is activated. The plugin does cloak my affiliate links, but it seems to be diverting all post URLs to the home page.
I love what this plugin does – do you have a solution for this problem?
Seems like multiple users have been having this problem recently, but I haven’t been able to reproduce it on my own site(s). Could you give me the URL of your site in question so I can run some tests? You can send it via email ( whiteshadow@w-shadow.com ) if you don’t want to reveal it publicly.
Thanks for looking into this. I’ve sent you an email.
We installed your excellent plugin but the cloaked links all open in the same window. We want the links to open in a new window or tab instead.
We are using the “Cloak All Links” option, because editing the thousands of links in all our posts would be unworkable..
Is there a way to have them all open in a new window or a new tab?
Not in the free version, sorry.
Have dropped you an email as I’m getting the 404 error aswell!
Actually cancel my help, like a plonker I didn’t read all the “Read Me” file and hadn;t manually updated the .htaccess file. It all works OK now
Oh well, I’m glad that it works. Please disregard my email that I sent literally five seconds before you posted that comment
If I were to use the default which would cloak all links… some of my links are inserted for better seo (anchor text links to internal pages) would google still see them as anchor text links?
Internal links are excluded from cloaking by default, even if you use the “Cloak all links” setting. You would have to remove your domain name from the exclusion list in Settings -> Link Cloaker to enable internal link cloaking.
But to answer your actual question – yes, I think they would still count as anchor text links even if they were cloaked.
None of the sites I put in the exceptions box are excluded, including my site. What should I do? I really like that feature.
Excellent plugin, thank you! I had trouble with it at first, but after reading through some of these comments I realized that, like a previous commenter I had not read the ReadMe file and so hadn’t updated my permalinks. Once I did that, everything seems to be working beautifully! Thank you for a great plugin!
[...] Link-Cloaking-Plugin : It is easy to install and use. And it doesn’t use JavaScript so it will work even for visitors that have disabled JS. In addition it is pretty much well-supported by its developer. [...]
[...] your intention is to cloak a link, why not use link cloaking software instead. There is an excellent free link cloaker for WordPress from White Shadow. (He even provides a much extended premium link cloaker with many more [...]
I’m just learning my way around wordpress, heard about your plugin and installed it.
A friend pointed out to me some time later that my links were all nofollow. After searching high and low in the theme files, I figured a plugin was to blame – this one.
In the exceptions box, I have all three versions of the domain. And yet, when I create a link inside a post to my home page, that is, just my domain name, it gets a nofollow tag. When I link to another post, it does not.
I tested it by deactivating the plugin, removing the link to the domain, reinserting a link to the domain and checking the page source. No nofollow tag. I removed the link, reactivated the plugin, reinserted the link, checked the pg source – and there it was, a nofollow tag.
Apart from the exceptions box, which I have already made use of, I don’t know what else I can do. Is it a glitch?
You could uncheck the “Nofollow cloaked links” box in the plugin’s settings.
Also, do the links that are nofollowed incorrectly actually work when you click them? If not, what URL do they show?
Thanks for the quick response! . . . I thought of that, but I’d prefer to keep them nofollow. I also checked to see if the links worked before I wrote the first time. They all went to my home page.
I did some more testing, and I got it to work. But . . .
Even though the domain, in all three forms, is in the exception box, it is getting cloaked as if it were an affiliate link if I choose to add alt text and set it to open in a new window (using the link button in the visual view).
If I simply type in the url, it does not cloak and does not add the nofolo tag.
So that’s where the glitch seems to be.
The problem is with setting it to open in a new window. I do that and it gets cloaked and nofolo. I tried adding just the alt tag and that worked fine.
This sounds similar to a problem that another user had. It should be fixed in the latest version of the plugin; download it here.
Thanks! I’m going to update it now and see if that fixes it. The one and only good thing about my procrastination problem is that I didn’t have much content on my site to sift through. (The bad thing, is I didn’t have much content…lol) Anyway, I’m just glad I got rid of all those nofollows.
[...] Cloaking Plugin Mit dem “Link Cloaking Plugin” kann man entweder alle oder nur extra markierte Links “verstecken”. Dafür [...]
I also installed this plugin and like it. But there is a little problem: it isn’t working for all links. Most link work as they should but there are a few that simply redirect back to my front page.
I think there is a bug in the regexp? Could somebody maybe take a look at this?
Could you give me an example? Post the URL of the page where you have the problematic links here, and I’ll take a look.
I suppose I won’ be able to post more than one URL here without being blocked by a spam filter so I send you a mail with some example URLs.
Maybe this has been asked before but will it automatically cloak rss feeds that are pulled into a web site? I got it working for my regular links but not rss feeds. That would be great if it did.
I’m guessing the RSS feeds are pulled in by a plugin. Unfortunately, the free version of the cloaker doesn’t really work with links created by other plugins. You could try the premium version, though