How to obtain the languageid in a Liferay theme wi

2019-05-10 13:14发布

For the current theme im creating there are multiple images that require to change based on the current language.

For example if the user is visiting the page in english we would load image_languageid.jpg

How can you replace languageid with the actual id of the language in velocity & liferay?

Is this a good technique or is there a nicer one?

1条回答
干净又极端
2楼-- · 2019-05-10 13:38

Try adding this line in init_custom.vm or portal_normal.vm

#set ($language_id = $themeDisplay.getLanguageId())
查看更多
登录 后发表回答