1

I'm working on a news website that has been redeveloped in Joomla 5 using the FlexiContent extension to manage news articles.

I want to implement a functionality that restricts full access to news articles. Specifically, I want unregistered users to be able to see the article listing and read the introduction text of each article. However, when they try to access the full article, the site should prompt them to log in.

As a reference, the site The Atlantic allows unregistered users to read the first article but requires them to log in to access full articles after that.

I hope I've explained it clearly.

Thank you.

1 Answer 1

3

This answer explains how to do what you want in the core Joomla com_content feature, you may or may not have to adapt the information here to suit FlexiContent.

In your Article you place the Text you want the public to see at the top of your editor window and then insert a 'Read More' line after that text. In this editor the Read More option is in the 'CMS Content' dropdown while other editors will show a button/icon.

What you see editor image of basic text with read more

The same text as above but showing the raw HTML

Depending on whether you want to control this at the Menu level or in each individual article, you will find these settings under the Options tab in both Articles and Menu editors.

Firstly you need to Show the Intro Text, that is what appears above the Read More element.

Show the intro text settings field.

And further down you will need to set the Unauthorised Links to to Show also. Showing the Unauthorised Links settings field.

The article also needs to have the Access set to Registered or higher to prevent the public user from seeing the whole article. Access field settings showing Registered.

Now looking at the Article in the front end should show the Intro text only and if someone clicks on the Read More button or Article Title/link they should be redirected to the login/Register page. enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.