Wordpress: Automatically mark advertising links to Amazon and Co

Wordpress blogs are often the target of warnings for missing identification.

As you know, I often refer to Amazon in this blog when I recommend products that I personally like or use myself. Even if there are any innovations that I may not have used myself yet, but which are worth mentioning from my point of view, I like to set links to online retailers or manufacturers. For the reader this is basically a practical service, but German law unfortunately sees things differently: For bloggers, competition law is a rather difficult jungle that can give you a warning about any missteps. As the author of the blog, you were usually completely unaware of the situation and you are accordingly surprised when a warning comes into your house.

Practical example: Amazon partner links

Every blogger who tries to earn a bit of money with his blog is probably familiar with an example from practice: Anyone who, for example, links to Amazon and integrates their partner ID in order to receive commissions, acts - as far as I can after reading can judge some specialist texts - commercially, because he has an intention to earn money with the article and the link. In this case, it is important to mark the links to Amazon as advertising. Otherwise you can be warned for surreptitious advertising or similar things and may have to pay a proper fine. Of course you want to avoid this and accordingly it makes sense to mark the affiliate links in the entire blog.

Automatic marking of affiliate links

Regarding the labeling of Amazon and other affiliate links, I looked at big players like Heise and Giga and saw there that they put an asterisk "*" behind every link to Amazon and then write "in the footer of the page"* = sponsored link"

Link marking Giga
Here you can see the identification that Giga.de uses for the Amazon links. This can also be found at other large portals and for this reason is probably currently the best legal and technical solution.

Having to maintain all of this manually in a blog is a bit annoying and prone to errors. Especially if you have been filling your blog for years and now have to mark all the links afterwards, it quickly becomes a very time-consuming activity. For this reason I was looking for a way to automatically add an asterisk to these links to amazon.de or to other affiliate domains. I got a little help with this the article by Clemens offered, although the implementation of variant 1 in my Wordpress blog directly in the style.css of the theme simply did not want to work. For this reason I “tinkered” a solution that can be implemented with a plugin and can be easily adapted for other domains apart from amazon.de.

My solution with a Wordpress plugin to mark external links

I've had this for years Link Indication Plugin in use, with which you can automatically provide external links with target="_blank" so that they are opened in a new window or tab. On the other hand, you can also set links to certain domains to nofollow and also add small graphics, so that you have a small “W” after Wikipedia links, for example – like here: Wikipedia entry by Steve Jobs.

Unfortunately, the plugin has not been updated for years, but it still works perfectly with Wordpress 4. And there shouldn't be any major security gaps due to the limited functionality.

Update 30.05.2017/7/XNUMX: The plugin “Link Indication” is unfortunately not compatible with PHP XNUMX. This means that if your web hosting is running with it, you may get an error message on the WordPress site after activating the plugin, or part of the content will be cut off (since the output starts where the error message normally appears). I had the plugin modified by a programmer to make it PHP 7 compatible. If you would like to have it, please send me a short email using the address in the imprint.

Update 9.8.2017/XNUMX/XNUMX: Simple labeling via CSS. For example, if you want to mark all links to Amazon via the CSS file, there is an easy way to do this that works completely without a plugin. Using the example of Amazon links, it would look like this:

a [href * = "amazon.de"]: after {content: "(advertising link)"; }

As a result, the addition “(advertising link)” is displayed behind every link to amazon.de. Unfortunately, currently also with pictures, which is a bit of a shame. If I find a way to hide this tag on photos, I'll post it here.

Once you have installed and activated the plugin, two settings are important: at the top you make a tick so that the css file is used in the plugin directory and at the bottom of the domains you add amazon.de with an entry and select the CSS class "star". I've included a graphic for you here with all my settings, with the important ones marked in red:

Link Indication Plugin settings
These settings are entered in my Link.Indication plug-in. Imitation desired. :)

Now only one entry is missing in the CSS file of the plugin. You can find this in the plugin directory, which you call up with an FTP program of your choice (I use Transmit from Panic on the Mac):

/ wp-content / plugins / link-indication /

The “link-indication_style.css” file is in this directory. Call it up with a text editor and add the following line below:

a.stern: after {content: "*"; }

Then you save the file and call up a post with an Amazon link. A ”*” should now appear after the link. If you use other affiliate providers, such as Affili.net, then you can add their tracking domain “webmasterplan.com” to the domain list in the link indication plugin and also use “star” as the CSS style. . In this way, other links are also marked quickly.

Small book tip on the side ...

Social Media Marketing & LawWith this label, your blog has definitely become a bit more legally secure. But there are numerous other problem areas that can quickly cost an inexperienced blogger hundreds or thousands of euros through warnings. The lawyer Thomas Schwenke has to an informative book called “Social Media Marketing & Law” written that explains many things such as Facebook buttons, data protection, statistics plugins and the like in conjunction with German law for bloggers. So that it is really helpful, solutions are of course also described how you should design your blog and social media communication so as not to run into a warning trap. Money well spent, sure!


My tips & tricks about technology & Apple

Did you like the article and did the instructions on the blog help you? Then I would be happy if you the blog via a Steady Membership would support.

8 Responses to “Wordpress: Automatically mark advertising links to Amazon and Co.”

  1. Pingback: WordPress - Clearly mark advertising links

  2. Hi Jens,

    thank you for the plugin tip! I didn't even know that.

    I also keep it that way that I mark affiliate links on my pages with an asterisk and the corresponding note in the footer.
    Unfortunately, in the heat of the moment, it happens every now and then that I forget the asterisk. The plugin can be a really good help here. Will definitely try it out!

    Best regards,

  3. Hi Jens,

    I came across this post through another blog that linked here.

    I will try out the option you have described in the morning right away. I hope that works.

    Best regards,

    Rainer (aka Azon professional)

    1. I'll keep my fingers crossed that it helps. Please excuse me for removing your page from the comment. I don't want my blog to be bombarded with links to money-making and keyword domains and short “Great tip, I'll try that!” comments. I hope for understanding.

  4. Oh how awesome, was my first thought when I read this! :-)

    That was the solution to my problem: to star hundreds of Amazon links in tens of posts.

    Thought, done - everything was done in 5 minutes! :-)

    But unfortunately it doesn't work: Now only the headline of the last post is displayed. All other content is gone as long as the plugin is active. If I switch it off, everything is back immediately.
    Tried it in 2 blogs with different themes - identical behavior.
    Don't understand how so little CSS can do that.

    Do you have an idea?

    1. Hello Karsten! I could imagine that it is because of the plugin. I couldn't handle PHP7 anymore and it threw errors. A programmer redesigned it so that it is compatible with PHP7. I'll send it to you by email! Then you still have to make the adjustments from the article that are necessary in the WP-Admin. I've already changed the CSS. LG! Jens

      1. hey jens,

        Thank you for the effort. Yes, I have PHP 7 too! :-)

        Because I wanted to have it done, I researched further and came up with this solution, which only inserts additional CSS and does not require a plugin:

        a[href*=”amazon.com”]:after, a[href*=”amazon.de”]:after, a[href*=”amzn.to”]:after { content: “*”; }

        That's it. :-)

        The catch was that Amazon not only produces links under amazon.de and .com. But also under the somewhat strange TLD amzn.to. You have to come on it for now! :-)

        Best regards,

        the Karsten

        1. Hello Karsten! Well, that is of course the most elegant solution! One less plugin can't hurt either! I still leave the plugin active because I want to mark other links with the graphics. Certainly I can use CSS somehow, but I'm not that big of a hero. : D But thanks for your addition! It's really great! LG! Jens

Post a comment

Your e-mail address will not be published. Required fields are marked with * marked

In the Sir Apfelot Blog you will find advice, instructions and reviews on Apple products such as the iPhone, iPad, Apple Watch, AirPods, iMac, Mac Pro, Mac Mini and Mac Studio.