REL= ALTERNATE
-
I’m trying to setup a rel alternate that change dynamically for each page url.
The problem is i could use <?php get_site_url(); ?> but i use a different subdomain for it :
ca.exemple.com/fr/ and http://www.exemple.com
I have been trying to do this but it doesn’t work, anyone can help ?
<?php
$current_url = explode(“ca.exemple.com/fr/”,curPageURL());
$current_url = $current_url[1];
$current_url = “http://www.exemple.com$current_url”;
?>
<link rel=’alternate’ hreflang=’en-ca’ href='<?php $current_url; ?>’/>
The topic ‘REL= ALTERNATE’ is closed to new replies.