Adding a language to Liferay - liferay

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

Related

The enabled languages setting in Liferay portal-ext.properties file doesn't seem to work

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

Customize Search Portlet in Liferay DXP 7

I would like your support in order to get some help in customizing the search component in Liferay DXP 7.0 Enterprise.
I have reviewed all the available documentation but although I have found many articles about the issue, the step by step is not so clear for me.
I need to customize the native search component:
Change the input component to give suggestions while the user is typing the search terms
Change the search result page look and feel.
Anyone ever implemented anything like this?
I know this is an old thread, but StackOverflow keeps showing it as the first open question when I am navigation this particular tag...So here are some pointers, as this is a pretty broad topic...
The search is really confusing for adding customization. Mainly you have to provide some of them as contributors, using the asset framework. following the regular steps to build an asset for the asset publisher you will hit the best place to find documentation about the search contributors.
About the search page, best is to create a new page, besides the default one for extra freedom. As long you use the friendly URL /search it will a basic replacement. In this page you can add everything you need, except for translations for the friendly URL - not great. Another option is to keep the default page (which will not be visible in the build area 7.1.x, but you can edit after you search something and fall inside it).

Magento - countrycode friendly URL's

I'm trying to change magento url's for the store switcher. Currently in Magento when you have multi store views for a different country code it shows like: myurl.com/?_store=french&_from_store=default
Does anyone know if it's possible to change it so that it shows myurl.com/fr. This would need doing for all different language types using the country code.
Thanks for any help you can offer.
M
here you can find your solution to manage like as above you want
http://magento-rohan.blogspot.in/2012/10/magento-managing-multiple-website-stores.html
you will do this easily using above link also for video
www.magentocommerce.com/magento-on-the-fly/multiple-sites/
hope this will sure help you.
You're one configuration setting away. Just go into System > Configuration > Web > URL Options and set 'Add Store Code to URLs' to 'Yes'.

MX Google maps throws a "failed to open dir" php error

I have MX Google Maps installed on an ExpressionEngine website.
When editing a field ( any field ) I'm greeted by this error:
A PHP Error was encountered
Severity: Warning
Message:
opendir(/opt/www/old_site/themes/third_party/mx_google_map/maps-icons/):
failed to open dir: No such file or directory
Filename: mx_google_map/ft.mx_google_map.php
Line Number: 212
MX google maps tries to use the theme folder path specified in an old site.
I've used the correct theme folder path in my general configuration and global template preferences, but MX google maps seems to stick to the old path.
Do I have to change it somewhere else, what am I doing wrong ?
I think I've had this problem before, and I'm pretty sure Max Lazar saves the path in the database for some reason. Do a search for www/old_site/ on your DB and see if you get any results.
Cheers,
Rob
Looking at the add-on source code, it appears to be checking a setting path_markers_icons, and if that is blank, defaulting to the EE theme path.
You should be able to find the path_markers_icons setting under the global fieldtype settings (under Add-ons > Fieldtypes). I suggest you make the setting blank so that it uses the built in EE theme path and doesn't trip you up in future.
Also, going by your line number it looks like you're not running the latest version (or at least the version that I just downloaded), so I suggest you upgrade.
Shot in the dark here: did you have a look in the exp_site table and in the site_system_preferences field? To echo Rob's thoughts, I vaguely remember having problems with that one on an MSM site, albeit not with that add-on. It's base 64 encoded so use this to decode.
http://www.opinionatedgeek.com/dotnet/tools/base64decode/
If your "old" theme_folder_path value in there, change it and base 64encode it to see if it changes something. Although, specifying theme_folder_path and theme_folder_url in config.php should override whatever is in the DB.

Translating string in Drupal

I've developed a site in english (admin & front end) but the site needs to be in a Dutch. Locale and i18n modules have been installed.
Dutch has been added to the list of languages and set as default in admin/settings/language.
I'm now wondering how I can translate strings like the date output? For ex, when I print out a date from a view, it still outputs the days and months in English.
In admin/settings/language/configure I've selected "path prefix only" but I don't get the language code in the url's and links. How is this achieved?
Thanks
You can translate month names, days and much more using Translation interface. Navigate to:
Administer -> Site Building -> Translate interface (admin/build/translate) -> Search (admin/build/translate/search)
and use the search form to locate the string you wish to translate.
Since you've already added Dutch to your site, you can download entire Dutch translation on http://localize.drupal.org. Site is currently in beta, so you will have to login using your Drupal.org credentials.
Use this link to export Dutch translation of Drupal. Just make sure you choose All in one file format so you can easily import it in your site using Translate interface -> Import
To get the language code in the URLs you will have to enable Multilingual support for each content type you need translated (admin/content/types) by opening edit and selecting desired option under Workflow settings -> Multilingual support.
After that make sure that you specify Dutch/English language while adding or editing nodes.

Resources