Skip to content
Read For Learn
Read For Learn
  • Database
    • Oracle
    • SQL
  • C
  • C++
  • Java
  • Java Script
  • jQuery
  • PHP
Read For Learn
  • Database
    • Oracle
    • SQL
  • C
  • C++
  • Java
  • Java Script
  • jQuery
  • PHP

wp-login-form

change register url on wp-login page

Code from @bainternet’s website. function wpse127636_register_url($link){ /* Change wp registration url */ return str_replace(site_url(‘wp-login.php?action=register’, ‘login’),site_url(‘register’, ‘login’),$link); } add_filter(‘register’,’wpse127636_register_url’); function wpse127636_fix_register_urls($url, $path, $orig_scheme){ /* Site URL hack to overwrite register url http://en.bainternet.info/2012/wordpress-easy-login-url-with-no-htaccess */ if ($orig_scheme !== ‘login’) return $url; if ($path == ‘wp-login.php?action=register’) return site_url(‘register’, ‘login’); return $url; } add_filter(‘site_url’, ‘wpse127636_fix_register_urls’, 10, 3);

Categories wp-login-form Tags wp-login-form

Remove lost password form and URL

Hi Please try to use this in your functions.php it will redirect user to login form when user try to access lost password page: add_action(‘init’,’possibly_redirect’); function possibly_redirect(){ if (isset( $_GET[‘action’] )){ if ( in_array( $_GET[‘action’], array(‘lostpassword’, ‘retrievepassword’) ) ) { wp_redirect( ‘/wp-login.php’ ); exit; } } } Or Please follow below approach used from this … Read more

Categories redirect Tags password, redirect, wp-login-form

send users logging in from wp-login.php directly to home page of site, rather than dashboard

You can achieve this by using the Plugin Peter’s Login Redirect. It allows you to send users to a specific page after login, based on the user capabilities. So you can allow administrators to go to the admin section, while members are redirected to the front page. If you want to prevent users from ever … Read more

Categories login Tags dashboard, login, wp-login-form

WordPress 4 invalid username special charachters issue

Are you creating your users via regular means or somehow importing them? Trying to create such user WP prevents me from doing so: ERROR: This username is invalid because it uses illegal characters. Please enter a valid username. The reason for that is that username is validated with validate_username(), which runs sanitize_user() in strict mode. … Read more

Categories PHP Tags htmlspecialchars-decode, login, php, wp-login-form

hook for lostpassword form

What happen if you use this instead ? public function processCaptcha() { if($_POST[‘captcha’]!=$captcha){ global $errors; $errors->add(‘invalid’, ‘<strong>ERROR</strong>: invalid captcha.’); } }

Categories hooks Tags hooks, wp-login-form

Positioning the “Lost your password?” and “← Back to Site”

although I can play around with the CSS If you are not going to use CSS (or jQuery) to modify the position of these elements, you have to create your own login form: Customizing_the_Login_Form#Make_a_Custom_Login_Page. There is no hook in wp-login.php that allows to move these elements inside the form field. Related: Where to put my … Read more

Categories login Tags login, wp-login-form

Redirect user after login/registration globally

This code adapted from: Registration Redirect add_filter( ‘registration_redirect’, ‘ckc_registration_redirect’ ); function ckc_registration_redirect() { return home_url(); } This code adapted from: Login Redirect add_filter( ‘login_redirect’, ‘ckc_login_redirect’ ); function ckc_login_redirect() { // Change this to the url to Updates page. return home_url( ‘/Updates’ ); } Add the code to the functions.php theme (or child theme) file.

Categories redirect Tags login, redirect, user-registration, wp-login-form, wp-redirect

Change Login Page for a Multisite Subsite

You can get the current blog id (which would be the site in a network, your subsite) with get_current_blog_id() and you can get details of a particular site with get_blog_details() from codex: get_blog_details(), passed an id of 1, may return the following object: [blog_id] => 1 [site_id] => 1 [domain] => foo-multi-site.com [path] => /site-path/ … Read more

Categories login Tags login, wp-login-form

Remove built in wordpress login and use only google auth

To remove WP native username/password authentication use the code below. It can be added to the theme (functions.php), to a plugin, or mu-plugin. Just make sure you have another authentication module working before you disable WP native auth. remove_filter(‘authenticate’, ‘wp_authenticate_username_password’, 20, 3);

Categories login Tags login, wp-login-form

WordPress Login Footer URL

Since this is not a standard feature you could achieve this with your own css and js you could add to the page like this <?php function custom_login() { echo ‘<link rel=”stylesheet” type=”text/css” href=”‘.get_bloginfo(‘template_directory’).’/custom-login/custom-login.css” />’; echo ‘<script src=”https://ajax.googleapis.com/ajax/libs/jquery/1.8.0/jquery.min.js”></script>’ echo ‘<script type=”text/javascript” src=”‘. get_bloginfo(“template_url”) . ‘/js/yourScript.js”></script>’; } add_action(‘login_head’, ‘custom_login’); ?> change jquery url as wanted to … Read more

Categories login Tags login, wp-login-form
Older posts
Newer posts
← Previous Page1 … Page29 Page30 Page31 … Page34 Next →
+ More

Recommended Hostings

Cloudways: Realize Your Website's Potential With Flexible & Affordable Hosting. 24/7/365 Support, Managed Security, Automated Backups, and 24/7 Real-time Monitoring.

FastComet: Fast SSD Hosting, Free Migration, Hack-Free Security, 24/7 Super Fast Support, 45 Day Money Back Guarantee.

Recent Added Topics

  • Bug in translation system: load_theme_textdomain() returns true, files are available and accessible but the language defaults to english
  • Custom Elementor controls not appearing in the widget Advanced tab using injection hooks
  • Get the name of the template/*html file used
  • Trying to Add Paging to Single Post Page
  • Sharing media files between live and staging servers
  • How to display the description of a custom post type in the dashboard?
  • Critical error on image display
  • Copying WP data and files into new install?
  • How to determine the DirectAdmin WordPress backup date?
  • How to get list of ALL tables in the database?
© 2026 Read For Learn
Next Page »
  • Database
    • Oracle
    • SQL
  • algorithm
  • asp.net
  • assembly
  • binary
  • c#
  • Git
  • hex
  • HTML
  • iOS
  • language angnostic
  • math
  • matlab
  • Tips & Trick
  • Tools
  • windows
  • C
  • C++
  • Java
  • javascript
  • Python
  • R
  • Java Script
  • jQuery
  • PHP
  • WordPress