I’m trying to have my author bio links go to a custom page rather than WordPress’s prebuilt page.
I’m using Astra, and and the active theme is a child theme.
I’ve added the following code into the functions.php file on the child theme:
add\_filter( ‘author\_link’, ‘my\_author\_link’ );
function my\_author\_link() {
return home\_url( ‘/about-us/authorsname/’ );
}
On my staging site, this code works great. On a test site that I have (different theme) this code also works great. However, on my live site, it doesn’t work at all. Nothing breaks, but the author pages doesn’t change.
I’ve edited the code using FileZilla (FTP), and confirmed the code is in place by looking in the file manager.
I can’t seem to find any information on what could be the cause. Any input would be greatly appreciated.
[ad_2]
Maybe you are using a child theme?