I'm developing Liferay Portal project, and when I navigate to localhost:8080, it's redirecting to "localhost:8080/en".
I did all localization settings for my language (Turkish), but it didn't work. Basically when I navigate to localhost:8080, I want it to redirect to localhost:8080/tr. How can I do this?
Please change the default language from en_US to tr_TR. Please add the portal-ext.properties to your server level or in ROOT/WEB-INF/classes and add the following property.
company.default.locale=tr_TR
after this, restart the server and it should work. This may not work for the existing User, so, please change the user's default language as well from the Profile.
Related
I have a problem with Liferay 7.1 changing language automatically. I have two languages polish(default) and english. The problem is when guest is opening page on portal with link with english url. Liferay automatically redirects him to polish version of url. I know that this is because of FriendlyURLServlet.
How to change this behavior? Are there any properties to turn off this redirect? Or the only option is to overwrite this class?
I have a new installation of OpenCMS (JDK11, tomcat8, MySQL). I followed the documentation to add my own template and modified it accordingly (Creating a template JSP). I also created a new site but I'm unable to find the correct URL to display it. For now I only have one web page and I published it.
The site's server URL is IPaddress:8081 as suggested by the documentation, but going to IPaddress:8081/opencms gives me a 404.
Tried deleting the demo site from the sites section but it still shows by default when going to IPaddress:8080/opencms (even after changing my site's port to :8080 and restarting tomcat).
Anyone with experience in setting up new sites from templates that can guide me?
Thank you very much.
it's not easy to guess what's wrong with your setup.
I ask some questions. Maybe they guide you in the right direction.
Did you create content in your site? If so and 3. is set correctly, you should be able to see your content by calling the server URI of your site, which you set in opencms-system.xml plus "opencms", plus the folder you created within the workplace. Don't add sites/yoursite. Example: IPaddress:8081/opencms/yourfolderinworkplace/. Be aware, that this only works, if your Tomcat listens to port 8081. If you are on your local machine, you can use 12
7.0.0.2, 127.0.0.3... for your different sites. So you can use port 8080 for all your sites.
Can you open (not edit) a page by clicking on it from within the workplace?
Did you set the template property correctly? It should contain the path to your master template jsp of your module. This is usually stored in the templates folder of your module.
When deleting the demo content, did you also publish it? If not, the pages are still visible in the so called Online project.
On your production server you should use Apache to differ between your sites.
Hope this helps.
Best regards
Kai
I have set up a new role in my Sitecore 8 (update 3) instance and have assigned the following roles to it (as well as giving read/write access to my content tree):
sitecore\Sitecore Client Translating
sitecore\Sitecore Client Users
sitecore\Sitecore Client Authoring
sitecore\Sitecore Client Designing
When logged in and using the Content Editor, I can change language ok. When I change language in the Page Editor Experience Editor however, (using Experience > Language menu item) I get a 404 error. If I clear the URL in the browser to the root (hostname) the language appears to have been changed.
Edit: Additional Information
It's worth noting that:
The solution does not use translated items. We have a separate content tree (within a single instance) for each site/language.
The linkManager is configured to use DisplayName for the URL.
Please share the snapshot of your new content tree structure and link manager config settings if possible. Meanwhile, can you please revert link manager settings and check if it works fine? Also use firebug net tab with persist to see the URLs requested while click on second language.
Also, please check following cookies values if updated your-site-name#lang:-
website#lang
here webiste is name of default sitecore site
Moreover, when your Experience Editor is loaded, just to make sure, click on default language from language menu to see if it works even for default language.
As said keep your firebug open with persist and keep eye on net tab with all to see if any resource request having 404.
The problem
We're running IIS on Windows 8.1 with Update. We're at the Orchard CMS first time setup screen, and IIS is giving 401s for all static content. We have read the following to no avail:
IIS 7.5 no images css js showing
IIS 7.5 no images css js showing
The official Orchard deployment documentation
Based on those, this is what I have tried that doesn't work.
Turn on the IIS feature to Serve Static Content.
Give IIS_IUSRS permission to Read, write & execute.
Give the site's application pool permission to Read, write & execute.
What does work though is the nuclear option: to give Everyone the Read permission (unless we want to proceed with the Orchard setup; then we need to give Everyone even more permissions.) That leads me to believe that I must give permission to some principle with less scope than Everyone but more scope than both IIS_IUSRS and the application pool combined.
Who/what is that principle?
Pictures to show the problem
We receive a 401 on ..\Themes\SafeMode\Styles\site.css
The task manager confirms that the site is running as the orchard user.
The security properties of the ..\Themes\SafeMode\Styles\ directory gives Read permission to orchard.
Why does it only work when we give Read permission to Everyone?
I had a similar problem. Under authentication, I right clicked "Anonymous Authentication" and clicked "Edit". That shows a dialog giving you the ability to set the identity of the anonymous user. I set it to "Application pool identity" and that fixed the problem for me.
.
This may not be the most secure configuration though, but I'm on a dev server so I don't care.
Try turn on the Static Content and Directory Browsing features under Internet Information Services->World Wide Web Services->Common HTTP Features node.
In my case I had to set Read permission for IUSR user for the web site folder.
So, what I had to do to fix this problem was the following:
(and please understand, that this is not ASP or PHP script related, the server wouldn't even show basic simple .html files, yet would serve out PHP results all day long!)
Two fold…
Had to set the application pool for each site, under advanced settings, to use LocalSystem for it’s process
Under site, advanced settings, security, add the IUSR account to have read & list contents access, for the site… :-)
See any problems with doing that?
'cuz it's working....
Updating windows feature for WWW services/Common Http Features/static content by selecting Static Content checkbox fixed my IIS not service static content issue.
Open IIS -> go to advanced settings of selected website and open Physical Path Credentials -> Select specific user and enter your local user credentials. Open below screenshot for further visualising the things:
IIS Settings
I know this is not specifically a programming question, but programmers will often have to do this work.
How do I create a website with Liferay portal - the docs are pretty light on this fundamental issue and are all for version 4.4. I am using version 5.2 and the docs don't seem to be relevant.
Do you know what the basic steps are. So far I have logged in as the bruno user and can see the 7cogs website and edit it. But I now need to create my own website (for my company) and be able to develop portlets to add to the parts of the page.
Further I notice that the docs talk about doing work in Eclipse. If our website is all static HTML, (the reason we want liferay is mainly so that we can edit content items using its content management tools), then will there be any need for Java dev, or will it all be drag n drop and clicking to get setup. Any guidance will be much appreciated.
Liferay can be used as a simple CMS, without much Java knowledge : creating, editing and positioning of web content fragments are drag'n'drop and use of the included rich text editor.
But to start using Liferay for your company, there are two main steps : a technical configuration (database, etc.), and a look'n'feel customization.
The technical part
First of all, you should get rid of the 7cogs website : this is called a hook in the Liferay wording. To do that, if you are using Tomcat for the application server, just delete the 7cogs directory as stated here.
You can now create the configuration file for your installation : it's a simple text properties file, named portal-ext.properties and placed in the webapps/ROOT/WEB-INF/classes folder of your tomcat installation.
This file handles most of the configuration of the Liferay portal, for example :
the name of your company
if you want to display a terms of use page on first login
if you want anybody to be able to create an account on your portal
the database where the data will be stored
To do this, the properties in the portal-ext.properties override default properties found in a embedded portal.properties file located in the jar file portal-impl.jar, in the webapps/ROOT/WEB-INF/lib directory. Just unzip the jar file in a temporary folder to access the portal.properties file.
A sample portal-ext.properties file :
company.default.web.id=yourcompany.com
terms.of.use.required=false
company.security.strangers=false
jdbc.default.driverClassName=com.mysql.jdbc.Driver
jdbc.default.url=jdbc:mysql://localhost/lportal?useUnicode=true&characterEncoding=UTF-8&useFastDateParsing=false
jdbc.default.username=root
jdbc.default.password=root
Once done, you can startup your application server. As the default admin (named test, something you can change in the portal-ext.properties file), you can access to the centralized web "control center", located in the "dock" (the strange menu labelled "welcome Test" in the upper right part of any page once logged in).
I would advise you to read the administration guide, useful for most administrative tasks.
The "branding" part
Liferay uses "Themes" to automatically decorate the portal pages (logo, navigation, portlet borders...) using images, CSS, Javascript (JQuery) and the templating language Velocity. The themes are bundled in a .war file, like a standard web application, and deployed on the fly either via the control center or by dropping the file in the deploy directory of the server.
Liferay can use several themes at the same time, one for each community (a group of pages, users and content) for example.
Creating your own theme can be done afterwards, using the "Plugins SDK".
The Wiki, forums and blogs can be very useful.