How to get current run mode of an AEM instance (author or publisher) | Adobe Higher Education
Skip to main content
Level 2
October 16, 2015
解決済み

How to get current run mode of an AEM instance (author or publisher)

  • October 16, 2015
  • 2 の返信
  • 8607 ビュー

Hi,

How we can know current run mode of AEM instace i.e. Author or Publisher

Similar to getting WCMMode using  WCMMode.fromRequest(request)

Thanks

LM

このトピックへの返信は締め切られました。
ベストアンサー edubey
Please use below code:- <% pageContext.setAttribute("runModes", sling.getService(SlingSettingsService.class).getRunModes().toString()); %>

2 の返信

smacdonald2008
Level 10
October 16, 2015

Here is a community code example:

http://wemcode.wemblog.com/check-run-mode

edubey
edubey回答
Level 10
October 16, 2015
Please use below code:- <% pageContext.setAttribute("runModes", sling.getService(SlingSettingsService.class).getRunModes().toString()); %>