Skip Navigation

This is the technical support forum for WPML - the multilingual WordPress plugin.

Everyone can read, but only WPML clients can post here. WPML team is replying on the forum 6 days per week, 22 hours per day.

This topic contains 6 replies, has 2 voices.

Last updated by Sergio 5 years, 1 month ago.

Assigned support staff: Bruno.

Author Posts
October 15, 2016 at 10:07 pm #1116155


Hello, I installed the AMP plugin, and I see that it does not validate: The attribute 'href' in tag 'link rel=stylesheet for fonts' is set to the invalid value 'hidden link'.

You provided a workaround here:

But I would like not to use workarounds. Can I kindly ask you to provide an official solution?

Yoast for example already long time ago provided a new plugin Glue for Yoast SEO & AMP.

Can you also provide an official solution to this?

Thank you

October 17, 2016 at 8:38 pm #1117237


Thank you for contacting us.

As reported in another topic, this was escalated to our developers.

Unfortunately, I do not have a deadline for when it will be fixed. At this point, the best option is the workaround.

Please let me know if I can help in any other questions you may have.

Thank you.

October 17, 2016 at 11:23 pm #1117296


1) Will the workaround work also for future WPML updates? For example I make the workaround and then update wpml to a future version, will I have to re-make the workaround? (ie. put the php code, put the .css code in my header, etc).

2) The AMP code is not valid, however it is still valid HTML.... so why the language switcher does not appear here? hidden link

3) I just added


. Now the AMP code passes and is valid. But if I check the normal non-AMP pages, the language switcher is still there.
Should I do also this part of the workaround? "and maybe migrate the language-selector.css file to be included in the pages instead." When should I do it and when I should not? I don't see any difference now that I set this:


4) Are the WPML developers already working with the AMP developers? Or you are waiting for some other information or internal green light to proceed working on a solution?

5) For some strange reason I was not notified by email when I received your reply in this thread. I had to manually enter this forum to see that you replied. Maybe you have some issues sending emails to gmail?

Thanks in advance

October 18, 2016 at 9:45 pm #1118155


1) The following line should be added in the wp-config.php file:


So when you update WPML, this line will not be lost.

About styles, depending on how you add it. If you add in the style.css file of your theme after theme update, this should be lost.

I recommend using WPML > Languages and look for Additional CSS. Thus, even updating the plugin or theme, this should not be lost.


2) Is this page translated? This can be a cache problem also. Please, could you clear the cache to check?


3) Have you tried to clear the cache of your website? If not, please, could you clean it and see if it persists?


4) At the moment I know that our developers are aware of this. This has been escalated. Our developers will look the escalated tickets and try to fix the problem - if our side. If this is a compatibility issue, they may have to contact the author of the AMP.


5) Perhaps the message was sent to the spam box. Have you checked? I use Gmail to follow the ticket and your message was received correctly.

Please let me know if I can help in any other questions you may have.

Thank you.

October 18, 2016 at 11:23 pm #1118175


3) Hello, yes I always clear the cache using wp-super-cache and I refresh the browser with Ctrl+F5.

I have


. And it's working. The link to that css is not there in the header.

However I expect (but don't want) that the language switcher will disappear from the honmepage (non AMP page) but if you take a look here hidden link the language flags are still there.

I do want them there. But I don't understand why they are there even though the language-selector.css is not being loaded in the header anymore.

Is it normal? Or maybe the language-selector.css is for another kind of language switcher menu, than the one I have?

Why in the AMP pages there is no language selector?


October 18, 2016 at 11:51 pm #1118183


P.s. and I have no emails about/from WPML in my spamfolder... strange

October 21, 2016 at 8:52 am #1120150


Can you please let me know asap? I'd like to try it in another big site of mine, but for that site I must be 100% sure what that code really does and what changes is supposed to do on the language flags on both html and html-amp pages.

The topic ‘[Closed] AMP and WPML incompatible – please help with a solution (not workaround)’ is closed to new replies.