Disable Forgot Username and Password

Need help with the Administration of your Joomla! 3.x site? This is the spot for you.

Moderator: General Support Moderators

Forum rules
Forum Rules
Absolute Beginner's Guide to Joomla! <-- please read before posting, this means YOU.
Forum Post Assistant - If you are serious about wanting help, you will use this tool to help you post.
CookieOfficial5
Joomla! Apprentice
Joomla! Apprentice
Posts: 30
Joined: Fri May 18, 2018 6:59 am

Disable Forgot Username and Password

Postby CookieOfficial5 » Mon Jun 18, 2018 5:04 am

I have it set so only Admins can issue Username and Passwords and I want to disable the use of Forgot Username and Password so they have to email the support team. How can I achieve this

User avatar
toivo
Joomla! Exemplar
Joomla! Exemplar
Posts: 9533
Joined: Thu Feb 15, 2007 5:48 am
Location: Oxford, UK
Contact:

Re: Disable Forgot Username and Password

Postby toivo » Mon Jun 18, 2018 5:45 am

You can create overrides for the login module, mod_login, and the login view of the com_users component. These tutorials tell all about overrides and show how to use the Template Manager to create them:
https://docs.joomla.org/How_to_override ... omla!_core
https://docs.joomla.org/J3.x:How_to_use ... _Overrides

Check first the html folder of your default template if it already has subfolders mod_login and com_users because it may contain existing overrides, depending on the template. if you look at the Beez3 template, it has an override for mod_login.
Toivo Talikka, Global Moderator
my first programs were assembled and run in 16KB :)
troubleshooting smtp and other articles https://talikka.com/joomla

User avatar
Krki
Joomla! Intern
Joomla! Intern
Posts: 87
Joined: Wed Feb 21, 2007 7:57 pm
Location: Zagreb, Croatia

Re: Disable Forgot Username and Password

Postby Krki » Mon Jun 25, 2018 12:14 pm

Hello

This suggestion solves issue only partially because Remind and Reset features
will only be hidden from module display but not completely disabled.

Someone can still use these url parts:

Code: Select all

index.php?option=com_users&view=remind
index.php?option=com_users&view=reset

and use these features.

Imho, there should an option in backend in user settings, to completely enable or disable each setting.


Best Regards

User avatar
toivo
Joomla! Exemplar
Joomla! Exemplar
Posts: 9533
Joined: Thu Feb 15, 2007 5:48 am
Location: Oxford, UK
Contact:

Re: Disable Forgot Username and Password

Postby toivo » Tue Jun 26, 2018 3:39 pm

You can override both views. Using the Protostar template as an example, create the file templates/protostar/html/com_users/remind/default.php and add the following lines into it:

Code: Select all

<?php
/**
 * @package     Joomla.Site
 * @subpackage  com_users
 *
 * @copyright   Copyright (C) 2005 - 2018 Open Source Matters, Inc. All rights reserved.
 * @license     GNU General Public License version 2 or later; see LICENSE.txt
 */

defined('_JEXEC') or die;
die;
If you want to display a special message instead of a blank page, replace the second die statement with something like:

Code: Select all

JFactory::getApplication()->enqueueMessage('Mind your own business!', 'error');
return false;
Toivo Talikka, Global Moderator
my first programs were assembled and run in 16KB :)
troubleshooting smtp and other articles https://talikka.com/joomla


Return to “Administration Joomla! 3.x”

Who is online

Users browsing this forum: No registered users and 6 guests