When I import my Liferay Freemarker templates using the Liferay resource importer their language value set to Velocity. This causes subsequent problems when Liferay tries to run them with Velocity. After import I have to manually change their language setting to Freemarker for my pages to run correctly.
Is there a way to import them so that the language is set to Freemarker?
I think you probably hit Liferay issue. Good news is that, it is already been resolved. You can check the committed files attached to LPS on left hand side.
HTH
Related
I am trying to limit the languages to only English. We have not yet translated any of our content, so having Liferay able to change it's language isn't helpful, and has caused some issues when user's accidentally stumble across URLs that have an alternate language in them.
So we want to limit the language to only English. I have set the following in portal-ext.properties:
locales.enabled=en_US
However, if I then access with a different language in the url ('iw' for example), the page is still translated.
So, am I not understanding what this setting does? Does it only limit the languages available in the language picker or something? I would appreciate any suggestions as this has become a frequent occurrence for our users as Google has also indexed some of our pages in different languages.
We are using Liferay 7 GA 7.
Thanks!
I have tested this on my liferay-ce-portal-tomcat-7.3.5-ga6-20200930172312275 server:
I used these properties in my portal-ext.properties file:
locales=en_US
locales.enabled=en_US
locale.prepend.friendly.url.style=0
When the portal started up, I visited these sites and indeed the pages were not translated as you requested:
http://localhost:8080/iw
http://localhost:8080/de
Please let me know if you had another use case in mind
Some useful resources:
https://issues.liferay.com/browse/LPS-65042
https://docs.liferay.com/portal/7.3-latest/propertiesdoc/portal.properties.html
for me helped adding
locales=en_US
locales.enabled=en_US
to this path bundles/portal-setup-wizard.properties, bundles/portal-ext.properties
I look for a tutorial, help or an example that tells me what I have to do to write a grid element like 2-colums in basic typo3 (v9) with fluid but no other extension like gridelements, DCE, Templa Voila, etc. I want the same gridelements can do but I dont want to be depended to this extention and move it in my own site extention.
I tried the same with normal content elements (CE) like here:
https://docs.typo3.org/c/typo3/cms-fluid-styled-content/9.5/en-us/AddingYourOwnContentElements/Index.html
But how can I nest a CE in a CE? And how can I do this by drag&drop in the backend?
You can't. The page module doesn't support nesting
You can't nest CEs in a CE. On database level this would mean that you have to make a tt_content record a subrecord of a parent tt_content record. You run into several problems, basically the multilanguage support will be broken and the shortcut element does not function as you will expect it to. That is why the extensions "gridelements" and "mask" exist.
I integrated the gridelements configuration into my sitepackage. So I do not need to bother anymore with it.
Just for your info:
There is now an initiative that works on integrating this functionality into the core (Structured Content Initiative, https://typo3.org/article/a-structured-content-initiative/). Stay tuned to it.
There is nothing special about providing Gridelements via external files, since it's based on TSconfig, TypoScript and Fluid. That's why there is not that much about it in the documentation, since it's the same thing you would do with any other kind of sitepackage. The TSconfig and TypoScript parameters are already explained there, while the Fluid would be up to you anyway.
To have a kind of kickstarter just take any extensions providing Gridelements layouts as an example. A very popular one would be bootstrap_grids, which can be found in the TER or here: https://github.com/laxap/bootstrap_grids
You don't necessarily need the flexform controller of that extension, but the Configuration and Resources folders, show you how to configure stuff and you can see how that is included via ext_localconf.php
There are even comments i.e. in the TSconfig files to explain what is possible there and how to handle i.e. mixed environments with record and file based setups. Although it would be recommended to go for files.
You would at least have to add the necessary backend rendering methods to a draw item hook, that will modify the preview of the container element.
So basically you would have to rewrite everything that DCE, Flux, Gridelements or other similar extensions already do.
Which brings us to the question, why you want to avoid those extensions, since especially those three are well known, widely spread, well supported and available for currently supported TYPO3 versions.
I have been following the steps outlined here: https://dev.liferay.com/develop/tutorials/-/knowledge_base/6-2/importing-resources-with-your-themes
My custom structures and templates are being imported. The problem that I have is that I also want to define an ADT to be imported. Nothing happens when I create the directory structure outline here:https://dev.liferay.com/develop/tutorials/-/knowledge_base/6-2/creating-plugins-to-share-structures-templates-and-more
Is the "templates-importer" standard deprecated? Can the "resources-importer" and "templates-importer" not be used at the same time?
I don't see any exceptions in the log and there's nothing to indicate why the ADT is not being imported. I have checked in the site template that is generated and in the global site.
Suggestions? Do I really need to create a hook to import the ADT?
You can use only one of those two, but they share common code and functionality (here are if...else statements responsible for chosing one of). If you use Resources Importer already, you can add your ADT's to resources-importer folder (in the same way it is done within templates-importer) and it will be imported as well.
I have a hook project which resources-importer which contains (among others) 4 ADTs. They are located in the following folders:
resources-importer/templates/application_display/asset_category
resources-importer/templates/application_display/asset_entry
First one is imported as ADT for Categories Navigation portlet and second for Asset Publisher portlet.
I am new in opencms.I am working on application of opencms8.5 . Actually my application already developed in struts and spring and now i have to integrate that with opencms . Actually when i am trying to generate container page in English then it's creating page in Punjabi language. Can some one tell me how i have to do that.
second question is while i am trying to change my folder name in opencms workplace then it's giving error
Runtime error in JPA layer: org.apache.openjpa.persistence.PersistenceException
Please help me .
I have a few questions, the language you want is in the workplace? or the text onlie/offline?
For the wokplace
you just have to chage your language preferences.
For the pages:
I guess your cms is set on English and Punjabi. So you have to search for the porperty locale or locale-availabe (the second one is for change between languages in the elements) in the container page or folder set the locale "en".
I'm using Liferay Portal 6.1.0 GA1
SCENARIO:
After configure a portal-ext.properties like:
locales=es_ES,en_US
time.zones=Europe/Paris
And running the server OK... (only those languages and timezone)
I want to add a new language through Control Panel -> Portal Settings -> Display Settings, writting
es_ES,en_US,it_IT to AVAILABLE LANGUAGES
But I get:
Please enter a valid locale error.
I also tried to stop LR and edit portal-ext.properties but I got the same.
Can you help me?
Thx a lot!
Alberto
Looks like issue is with number of Languages you are selecting from Display Settings. As after adding only 2 locales(es_ES,en_US) from portal-ext.properties, when you go to Control Panel -> Display Settings, it's displaying around 10+ languages in Current. So after adding English to current and save it's trying to validate all the languages with the locales= values provided in portal-ext.properties.
And when it tries to validate language other than the one you've provided in portal-ext.properties it will give error.
What you can do here is,
- First remove all the entries from Current back to Available
- Add only "English(ES)" to Current one
- Save
Reference : here
ASWER my own question:
I tried to add Italian (beta phase) so I tried:
locales=es_ES,en_US
locales.beta=it_IT
time.zones=Europe/Paris
But that does not work in LR Portal 6.1.0. So then I tried:
locales=es_ES,en_US,it_IT
time.zones=Europe/Paris
And solved