target="_self" reported as invalid tag attribute in Google Search Console
Is there a way to have the plug-in automatically strip out any invalid 'target' attributes on links?
According to the ampproject:
The href attribute value must not begin with javascript:. If set, the target attribute value must be _blank.
Google Search Console has reported content containing anchors with target="_self" as invalid tag attribute values.
If you are wordpress users you may add target _blank using this plugin https://wordpress.org/plugins/wp-links/screenshots/
Yeah, the wp-amp plugin itself should be stripping those attribute tags though. We shouldn't need to use a separate plugin in order to accomplish what the wp-amp plugin should be taking care of.
Yes and in our case we are small blogging network running MU installation and can't fully control what our users are publishing. Would be nice if wp-amp could just take care of these kinds of issues for us.
I'm finding a number of other validation related issues that I'd expect the plug-in to address. Hopefully the next release will correct some of these.
Do you want to replace _self with _blank for both AMP page and your original Webpage ?? @flexdaddy
Is _blank the only value that is AMP friendly?
If so, _self and _top should be removed or replaced with _blank by the wp-amp plugin.
yea but the AMP plugin doesn't do that .... we can still get around that issue though