Forum Moderators: coopster
I'm trying to replace the standard wordpress login, logout, and signup, links with a new directory $new_url defined earlier in the plugin.
It seems to be showing up as blank... Also the replacement is not working properly when I tested defining the variable within the replacelinks function.
add_filter('the_content', 'replacelinks');
add_filter('comment_text', 'replacelinks');
function replacelinks($content) {
$registerurl = get_bloginfo('url').'/wp-login.php?action=register';
$content = str_replace($registerurl, $new_url.'signup.php', $content);
$profileurl = get_bloginfo('url').'/wp-admin/profile.php';
$content = str_replace($profileurl, $new_url.'profile.php', $content);
$logouturl = get_bloginfo('url').'/wp-login.php?action=logout';
$content = str_replace($logouturl, $new_url.'logout.php', $content);
$loginurl = get_bloginfo('url').'/wp-login.php';
$content = str_replace($loginurl, $new_url.'login.php', $content);
return $content;
}