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

login

Check if specific user is online outside wp

You could always try using the wp_login action hook: function custom_check_for_user($user_login, $user) { if($user->ID == 123) { // Where 123 is the particular user’s ID // Do something here, eg. PHP mail() function } } add_action(‘wp_login’, ‘custom_check_for_user’, 10, 2); Further reading: https://codex.wordpress.org/Plugin_API/Action_Reference/wp_login

Categories login Tags login

WordPress Logout Problem [closed]

The answer is in this post: How to log out without confirmation ‘Do you really want to log out?”? side note: running an old version of WP like that (3.6) is super risky from a security standpoint. Do your future self a favor and update it!

Categories login Tags login

503 Login WordPress [closed]

I’ve had 503 errors when using shared hosting services with Fasthosts / Rackspace etc. Typically, they don’t last long, but if yours are – then there is something going on with the server you are sharing. You might want to check that the memory limit in the config is 96 MB but that shouldn’t be … Read more

Categories login Tags login

404.php only works if I’m logged in. Everybody else redirects to wp-login.php – why?

The solution was straightforward, though it took me forever to find it. The website has a “Members” plugin (by Justin Tadlock) and the option “Redirect all logged-out users to the login page before allowing them to view the site.” was checked. So I just unchecked that box, problem solved.

Categories pages Tags login, pages, private

Show/Hide Div for Login Mask

You are calling jQuery wrong by the shorthand $. If you will look in your console you will see an error that $ is not a function / undeclared etc (this is due to jQuery’s conflict mode if I am not wrong). Your code should look something like this: <script type=”text/javascript”> jQuery(function($) { $( “a.toggle”).click(function() … Read more

Categories CSS Tags css, javascript, login

How to unpublish my new site while working on it?

If you will want to do something by you self than you will have to create a custom html or php file a redirect your site to it, this can be done by using template_include, you will have do to something like: function coming_soon_page( $template ) { if (!is_user_logged_in()) { $cs_template = locate_template( array( ‘path/to-your/comingsoon-page.php’ … Read more

Categories login Tags login

How to Remove default “Login” link

You’ll probably need to ask the theme author about this. If you would like to try fix this yourself, the code for this will probably be located in header.php, just do a search for “log in” and remove/comment out the markup/function that places it there.

Categories login Tags login

Hide Author page from others

If I understood correctly, redirecting based on post count, as you are doing, is wrong. What you need is to check if current user is the same that the author’s profile; if it is the same, do nothing, it is not the same, redirect to own profile; if it a guest user, redirect to login … Read more

Categories login Tags author-template, login, wp-redirect

I want login using email not username wordpress front end

Your code has some problems: You are using deprecated function get_user_by_email You are using wrong hook wp_authenticate You can this plugin https://wordpress.org/plugins/wp-email-login/ or Your can use this code function wpsc_authenticate_user_by_email( $user, $username, $password ) { // Bailout if( ! is_frontend_login_form() ){ return $user; } $login_page = strtok( $_SERVER[“HTTP_REFERER”], ‘?’ ); //check for valid inputs if( … Read more

Categories login Tags authentication, login

Change homepage content if user is logged in – BuddyPress

I just wrote some code to do something a bit different, but it should work for what you’re trying to do. It’s hooked in at the wp hook, which will prevent redirect loop errors. This will go in either a functions.php file or your own custom plugin (recommended). add_action(‘wp’,’restrictEnterSite’); function restrictEnterSite(){ // Make a template … Read more

Categories PHP Tags buddypress, homepage, login, php
Older posts
Newer posts
← Previous Page1 … Page72 Page73 Page74 … Page164 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
  • Post Navigation Elementor
  • Custom Elementor controls not appearing in the widget Advanced tab using injection hooks
  • WPFacet multiple loop displaying duplicate content
  • Get the name of the template/*html file used
  • Fix: WordPress.DB.PreparedSQL.NotPrepared Plugin Check (PCP)
  • Removing unnecessary CSS and JS code from wp_head()
  • hexagonal image gallery. Am I on the right track? [closed]
  • Trying to Add Paging to Single Post Page
  • Sharing media files between live and staging servers
© 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