Notifications
Clear all
Topic starter
24/04/2018 4:25 pm
Hi,
Am really enjoying the plugin, thank's for that.
My theme uses a login with ajax modal pop up for user login/logout/registration
I have set up users to be logged before being able to comment in my test site. The link works but does not open the pop up
I have looked up in the form.php of the plugin and guess that"s where I could change / add something for the pop up to open.
Could you give me on a tip on how I could achieve that ?
Thank's
25/04/2018 5:31 pm
Hi Electrochick,
I suggest you use the following code, put it in current active functions.php file, and you can make changes as like as you want:
add_filter('loginout', 'myLoginLink');
if (!function_exists('myLoginLink')) {
function myLoginLink($link) {
if (preg_match('#<a[\r\n\t\s]*href=["\']([^"\']+)["\'][^<>]*>#isu', $link, $matches)) {
$url = $matches[1] . '#mypopuplink';
$link = '<a style="color:#000;font-size:16px;font-weight:700;" href="' . $url . '">';
$link .= 'Login';
$link .= '</a>';
}
return $link;
}
}