-
Author
-
December 22, 2016 at 04:01 #147771RoaderParticipant
Hi there!
In spanish:
Laura, cómo puedo restringir el acceso a wp-admin o wp-login?
Por ejemplo, si yo pongo seventhqueen.com/wp-admin , aunque esté logueado en My Account, no me da acceso al DashBoard ni siquiera como Suscriptor.
Sin embargo, usando el usuario de prueba si pongo misitio.com/wp-admin, estándo logueado como Suscriptor, me abre el DashBoard y yo no quiero eso.
De hecho, lo que quiero es cambiar wp-admin y wp-login por cualquier otro. wp-banana p. ej. Pero he fallado en conseguirlo.
Attachments:
You must be logged in to view attached files.December 23, 2016 at 05:49 #147845LauraModeratorHola, quiza esto ayude https://codecanyon.net/item/hide-my-wp-amazing-security-plugin-for-wordpress/4177158 es un plugin muy bueno para la seguridad de la web, eso si, ten mucho cuidado con las opciones y haz copias de seguridad si lo usas 🙂
Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solutionLaura Solanes - Graphic Designer and Web Designer
Please be patient as I try to answer each topic as fast as i can.
If you like the theme or the support you've received please consider leaving us a review on Themeforest!
Always happy to help you 🙂
December 29, 2016 at 07:44 #148278LauraModeratorPHP es mucho mas complicado que usar un plugin especialmente diseñado para eso.
Si prefieres php te recomiendo contratar a un desarrollador que lo haga por ti.
El foro esta para resolver problemas relacionados con el tema, no podemos ofrecer soportes para pedidos o caracteristicas adicionalesHi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solutionLaura Solanes - Graphic Designer and Web Designer
Please be patient as I try to answer each topic as fast as i can.
If you like the theme or the support you've received please consider leaving us a review on Themeforest!
Always happy to help you 🙂
December 29, 2016 at 21:41 #148313RoaderParticipantMi querida Laura. Los plugins necesitan soporte, un código PHP estable no.
Tampoco hay necesidad de contratar, ya que solo necesito leer y aplicar.
Lo que quiero saber es cómo uds aseguraron el Wp-Login, pues veo que lo tienen protegido en el Demo.
Yo sé como protegerlo, el problema es que quizás hay algo que me falta y por eso me da error cuando uno hace click en Log Out. En el Demo permite hacer Log Out sin pedir confirmación de la Clave protectora.
January 2, 2017 at 11:28 #148513LauraModeratorHola, si puedes escribirlo en inglés se lo asignaré a radu 🙂
Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solutionLaura Solanes - Graphic Designer and Web Designer
Please be patient as I try to answer each topic as fast as i can.
If you like the theme or the support you've received please consider leaving us a review on Themeforest!
Always happy to help you 🙂
January 2, 2017 at 12:49 #148518RoaderParticipantOk, más tarde. Pero lo que digo es que ya uds tienen la forma de aplicar protección al Login sin que esta afecte el LogOut de los Suscriptores. Eso es lo que quiero saber.
Por otro lado qué me dices del Plugin AIO Wp Security and Firewall?
January 4, 2017 at 17:02 #148720RaduModeratorI don’t understand Spanish but related to the topic title, this is the solution for what you need: https://wordpress.org/plugins/remove-dashboard-access-for-non-admins/
No quick solution PHP snippets !
Cheers
R.Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solutionJanuary 29, 2017 at 23:25 #151292RoaderParticipantLaura, a partial solution is:
In functions.php:
COPY CODE// Restrict WP Dashboard add_action( 'init', 'blockusers_init' ); function blockusers_init() { if ( is_admin() && !current_user_can( 'administrator' ) && !( defined( 'DOING_AJAX' ) && DOING_AJAX ) ) { wp_redirect( home_url() ); exit; } }
In .htaccess (fist line only)
// Change wp-login to your custom url
RewriteRule ^your-custom-login-name$ http://your-domain.com/wp-login.php [NC,L,R]
January 29, 2017 at 23:37 #151293RoaderParticipantOther solution is:
An .htaccess in wp-admin folder:
COPY CODE# Protect wp-admin by my IP order deny,allow allow from 0000000000 #Change it for your IP deny from all <Files admin-ajax.php> Order Allow,Deny Allow from All Satisfy Any </Files>
————————
But, there are some problems…
Radu. I found this code ===> But, does not work. :-/
I dont know if is Sweetdate Registration Form or BuddyPress… The problem is, that you can Register with whatever Email, i.e. mydog@mydogisbig.comAnd, there is not a button of field to Resend the Email Confirmation, after you complete.
COPY CODE// Restrict WordPress Registration to Email Whitelist function is_valid_email_domain($login, $email, $errors ){ $valid_email_domains = array("yahoo.com","hotmail.com","outlook.com","gmail.com","aol.com","mail.com");;// whitelist email domain lists $valid = false; foreach( $valid_email_domains as $d ){ $d_length = strlen( $d ); $current_email_domain = strtolower( substr( $email, -($d_length), $d_length)); if( $current_email_domain == strtolower($d) ){ $valid = true; break; } } // if invalid, return error message if( $valid === false ){ $errors->add('domain_whitelist_error',__( '<strong>ERROR</strong>: you can only register using @gmail.com or @outlook.com emails' )); } } add_action('register_post', 'is_valid_email_domain',10,3 );
-
AuthorPosts
You must be logged in to reply to this topic.