• Hello Fabrik Community

    Fabrik is now in the hands of the development team that brought you Fabrik for Joomla 4. We have recently transitioned the Fabrik site over to a new server and are busy trying to clean it up. We have upgraded the site to Joomla 4 and are running the latest version of Fabrik 4. We have also upgraded the Xenforo forum software to the latest version. Many of the widgets you might have been used to on the forum are no longer operational, many abandoned by the developers. We hope to bring back some of the important ones as we have time.

    Exciting times to be sure.

    The Fabrik 4.0 Official release is now available. In addition, the Fabrik codebase is now available in a public repository. See the notices about these in the announcements section

    We wish to shout out a very big Thank You to all of you who have made donations. They have really helped. But we can always use more...wink..wink..

    Also a big Thank You to those of you who have been assisting others in the forum. This takes a very big burden off of us as we work on bugs, the website and the future of Fabrik.

Override default Joomla Login page

  • Views Views: 25,410
  • Last updated Last updated:
  • Copying The Template​

    Copy the contents of:

    components/com_users/views/login/tmpl

    to:

    your_template/html/com_users/login

    Override The Language Files​

    To override the language file associated with this component, copy the necessary string ie:

    COM_USERS_LOGIN_USERNAME_LABEL="User Name"

    from:

    language/en-GB/en-GB.com_users.ini

    to a file called:

    language/overrides/en-GB.override.ini

    and:

    JGLOBAL_PASSWORD="Password"

    JLOGIN="Log in"

    JLOGOUT="Log out"

    JGLOBAL_YOU_MUST_LOGIN_FIRST="Please login first"

    from:

    language\en-GB\en-GB.ini

    to the same override file as above ie:

    language/overrides/en-GB.override.ini

    For the login module, copy:

    MOD_LOGIN_VALUE_USERNAME="User Name"

    MOD_LOGIN_REMEMBER_ME="Remember Me"

    MOD_LOGIN_FORGOT_YOUR_PASSWORD="Forgot your password?"

    MOD_LOGIN_FORGOT_YOUR_USERNAME="Forgot your username?"

    from:

    language/en-GB/en-GB.mod_login.ini

    to the same override fille as above ie:

    language/overrides/en-GB.override.ini

    Style The Form​

    This is an 'embedded' method of styling that only effects the login form - if anyone can provide code for how to define this styling as a separate fieldset in the Joomla template css, please do!

    In your new copy of templates/your_template/html/com_users/login/deafult_login.php, find:

    PHP:

    <form action="<?php echo JRoute::_('index.php?option=com_users&task=user.login'); ?>" method="post">

    <fieldset>
    <?php foreach ($this->form->getFieldset('credentials') as $field): ?>
    <?php if (!$field->hidden): ?>
    <div class="login-fields"><?php echo $field->label; ?>
    <?php echo $field->input; ?></div>
    <?php endif; ?>
    <?php endforeach; ?>
    <button type="submit" class="button"><?php echo JText::_('JLOGIN'); ?></button>
    <input type="hidden" name="return" value="<?php echo base64_encode($this->params->get('login_redirect_url', $this->form->getValue('return'))); ?>" />
    <?php echo JHtml::_('form.token'); ?>
    </fieldset>
    </form>

    and replace with:

    PHP:


    <form action="<?php echo JRoute::_('index.php?option=com_users&task=user.login'); ?>" method="post">

    <fieldset style="border: 1px solid #CCCCCC; border-radius: 5px 5px 5px 5px; margin: 50px auto 0 auto; padding-bottom: 50px; padding-left: 50px; padding-top: 50px; width: 350px;">
    <p style="margin-bottom: 5px;">type a message here if you would like.</p>
    <?php foreach ($this->form->getFieldset('credentials') as $field): ?>
    <?php if (!$field->hidden): ?>
    <div class="login-fields"><?php echo $field->label; ?>
    <?php echo $field->input; ?></div>
    <?php endif; ?>
    <?php endforeach; ?>
    <button type="submit" class="button" style="float: right; margin: 10px 87px 0 0;"><?php echo JText::_('JLOGIN'); ?></button>
    <input type="hidden" name="return" value="<?php echo base64_encode($this->params->get('login_redirect_url', $this->form->getValue('return'))); ?>" />
    <?php echo JHtml::_('form.token'); ?>
    </fieldset>
    </form>

Back
Top