Placing The Meta Referrer Tag

One of the important functions of the tourism website whidbeycamanoislands.com is to serve as a lodging directory, sending people to the websites owned by various motels, B&B’s, etc.

I recently upgraded security to https. Shortly thereafter, the owners of the website eaglesnestinn.com/ reported that referral traffic had dropped to zero. It’s also a secure site.

Their developer found that now I need to add a referrer tag into the head of each page.

It’s described in these two pages:


The second link even helpfully adds a code snippet and instructions. I added the snippet to my child theme, but it apparently doesn’t work.

There’s a test page:
http://www.whatismyreferer.com/

If you create a link to that page, when you click on it, you should get the referring page in the blue box, But, of course, it isn’t.

Here’s my test page:
https://whidbeycamanoislands.com/test-referrer/

Any idea what I’m doing wrong?

Thanks.

Hi there,

I checked the page that you have linked but I can’t seem to see the the referrer meta tag is added on the page. Please try to add this code in the functions.php file of the child theme and make sure that the child theme is active:

function add_meta_tags() {
?>
    <meta name="referrer" content="always"/>
<?php }
add_action('wp_head', 'add_meta_tags');

Hope this helps.

That did it. Thanks!

On further review, this is not always working. I’m testing further.

Hello There,

Please make sure that your site url in Settings > General > Site URL is using https too! You can also do a search and replace for http to https to make sure that all resources will be loaded in https.

Hope this helps.

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.