Advertisement

How to Redirect to Login Page from "No Access" Error Message

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.
Windows Defender SmartScreen Issues <-- please read this if using Windows 10.
Locked
JohnSmithers
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 227
Joined: Mon Feb 11, 2013 9:22 am

How to Redirect to Login Page from "No Access" Error Message

Post by JohnSmithers » Tue Mar 05, 2019 10:58 am

I have created a new user group to have access to pages hidden from the public.

I have assigned one page to display only to this new group and above in the hierarchy.

This page is currently showing the following standard error to the public: "Error You are not authorised to view this resource".

I wish this error message to also provide either a login form, or a link to a login page: how do I do this most effectively?

Advertisement
annahersh
Joomla! Guru
Joomla! Guru
Posts: 734
Joined: Wed Aug 15, 2018 8:23 pm

Re: How to Redirect to Login Page from "No Access" Error Message

Post by annahersh » Tue Mar 05, 2019 8:08 pm

Edit the language via the override. Extensions > Languages > Overrides
Select the client side from the selection field
Click New
Search for the string
Click the one most suitable
Enter the text in the field on the left.
language-override.jpg
Though this method is not entire ideal since it still prepend the Error text and is wrapped in a warning element. To eliminate the Joomla notice entirely will require template override file.

Extensions > Templates > Templates
Click the name of your default template
Click the overrides tab
Under the column titled Layouts, click Joomla
Then click System

Edit message.php
You do not have the required permissions to view the files attached to this post.

JohnSmithers
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 227
Joined: Mon Feb 11, 2013 9:22 am

Re: How to Redirect to Login Page from "No Access" Error Message

Post by JohnSmithers » Sat Mar 16, 2019 11:28 am

Thanks :-)

User avatar
Per Yngve Berg
Joomla! Master
Joomla! Master
Posts: 31842
Joined: Mon Oct 27, 2008 9:27 pm
Location: Romerike, Norway

Re: How to Redirect to Login Page from "No Access" Error Message

Post by Per Yngve Berg » Sat Mar 16, 2019 12:44 pm

Not sure what your problem is here. Is the Article restricted and the menu item public?

Advertisement

Locked

Return to “Administration Joomla! 3.x”