Is it possible to restrict content editing in classic mode ?

nagasreenug4839 04-10-2018

Hi All,

Recently we got requirement from client, client want to restrict content authoring in classic mode (cf#) based on usergroup .Is it possible to restrict like that ?

Client want users need to authoring content in touch ui mode not in classic mode.,Even if users forcibly open page in classic mode(page open with  CF#) we should not allow the access.

Accepted Solutions (1)

Accepted Solutions (1)

rajas66269496 04-10-2018

You need to use sling filters and need to follow below design.

Steps :

  • As you are using author instance so you must execute only in author environment. you must add this in run mode configurations
  • Inside doFilter() method you need to check the URL contains "cf#" or not. and it is good to check run mode also author or publish along with "cf#"
  • Use configuration manager to configure groups
  • Read groups from the configurations and iterate
  • Now get the username and check whether he is in a particular group or not
  • If the user in a specified group then you can perform redirection to touch UI page, by replacing "cf#" to "editor.html"

Example :