掲示板
How to change portlet title on the basis of language selected?
11年前 に Neetu Mishra によって更新されました。
How to change portlet title on the basis of language selected?
Junior Member 投稿: 75 参加年月日: 12/05/21 最新の投稿
Hi,
I am creating a custom portlet & I want to change portlet title on the basis of language selected by the user. I know how to change the portlet's content but didn't get any solution to change the portlet's title.
Thanks in advance!!
Regards,
Neetu
I am creating a custom portlet & I want to change portlet title on the basis of language selected by the user. I know how to change the portlet's content but didn't get any solution to change the portlet's title.
Thanks in advance!!
Regards,
Neetu
11年前 に DarshanKumar N Bhatia によって更新されました。
RE: How to change portlet title on the basis of language selected? (回答)
Junior Member 投稿: 85 参加年月日: 10/03/02 最新の投稿
For any kind of portlet (custom /inbuilt one):
To change Title for particular locale :
1) Deploy portlet on page.
2) Click on Look and feel --> Portlet Configuration Tab
Check : Use Custom Title
Provide ur custom title Name and select a language corresponding to it.
Save.
Test it : By Putting langauge Portlet and changing to various locale.
To change Title for particular locale :
1) Deploy portlet on page.
2) Click on Look and feel --> Portlet Configuration Tab
Check : Use Custom Title
Provide ur custom title Name and select a language corresponding to it.
Save.
Test it : By Putting langauge Portlet and changing to various locale.
11年前 に Dhrutika Parekh によって更新されました。
RE: How to change portlet title on the basis of language selected? (回答)
Expert 投稿: 435 参加年月日: 09/02/09 最新の投稿
Hi Nitu,
One solution is as provided in above post if you do it by configuration,
Other way is by changing in xml:
Regards,
Dhrutika
One solution is as provided in above post if you do it by configuration,
Other way is by changing in xml:
- Enter Resource bundle path in your portlet.xml.(i.e. <resource-bundle>com.my.langauage.Resource.Navigation.Language</resource-bundle>)
- On defined path place Language_*.properties files.
- In these files make respective language entries (i.e.Language_en.properties : javax.portlet.title=Navigation ,Language_es.proeprties=Navegaci\u00F3n)
Regards,
Dhrutika
11年前 に Neetu Mishra によって更新されました。
RE: How to change portlet title on the basis of language selected?
Junior Member 投稿: 75 参加年月日: 12/05/21 最新の投稿
Thanks Dhrutika & DarshanKumar for your quick replies!!
Hey DarshanKumar, this is also a nice way of doing it. I knew about the custom titles but didn't knew that we can change it on the basis of language as well. So thanks once again.
Hey Dhrutika I have a question about resource bundle path:
It might be very simple question but apologize me for that.
Since, I am placing language_*.properties files in docroot/WEB-INF/src/content folder so is it ok to put resource bundle path like this??
I have tried this but it's not working, so I think I am missing some thing. Please help me regarding this. Thanks once again!!
Thanks in advance!!
Hey DarshanKumar, this is also a nice way of doing it. I knew about the custom titles but didn't knew that we can change it on the basis of language as well. So thanks once again.
For any kind of portlet (custom /inbuilt one):
To change Title for particular locale :
1) Deploy portlet on page.
2) Click on Look and feel --> Portlet Configuration Tab
Check : Use Custom Title
Provide ur custom title Name and select a language corresponding to it.
Save.
Hey Dhrutika I have a question about resource bundle path:
Enter Resource bundle path in your portlet.xml.(i.e. <resource-bundle>com.my.langauage.Resource.Navigation.Language</resource-bundle>)
It might be very simple question but apologize me for that.
Since, I am placing language_*.properties files in docroot/WEB-INF/src/content folder so is it ok to put resource bundle path like this??
<resource-bundle>content</resource-bundle>
I have tried this but it's not working, so I think I am missing some thing. Please help me regarding this. Thanks once again!!
Thanks in advance!!
11年前 に Muzakir Khan によって更新されました。
RE: How to change portlet title on the basis of language selected?
Regular Member 投稿: 112 参加年月日: 12/03/15 最新の投稿Neetu Mishra:
Since, I am placing language_*.properties files in docroot/WEB-INF/src/content folder so is it ok to put resource bundle path like this??<resource-bundle>content</resource-bundle>
I have tried this but it's not working, so I think I am missing some thing. Please help me regarding this. Thanks once again!!
Try this,
<resource-bundle>content/language.properties</resource-bundle> BOL
Regards
Khan
11年前 に Neetu Mishra によって更新されました。
RE: How to change portlet title on the basis of language selected? (回答)
Junior Member 投稿: 75 参加年月日: 12/05/21 最新の投稿
Hi Muzakir,
Thanks for your reply.
I have tried this but it was flagging a warning in Eclipse that file name should not end with .properties. So I have tried this:
& it's working.
Thanks once again for your suggestion!!
Thanks for your reply.
Try this,
<resource-bundle>content/language.properties</resource-bundle>
I have tried this but it was flagging a warning in Eclipse that file name should not end with .properties. So I have tried this:
<resource-bundle>content/language.properties</resource-bundle>
& it's working.
Thanks once again for your suggestion!!
9年前 に Akash Jaisawal によって更新されました。
RE: How to change portlet title on the basis of language selected?
Regular Member 投稿: 141 参加年月日: 12/03/03 最新の投稿
I have tried this but it was flagging a warning in Eclipse that file name should not end with .properties. So I have tried this:
& it's working.
Thanks once again for your suggestion!!
Sorry Neetu but i didnt get you point here!
You have tried this "
and it worked?
<resource-bundle>content/language.properties</resource-bundle>
& it's working.
Thanks once again for your suggestion!!
Sorry Neetu but i didnt get you point here!
You have tried this "
<resource-bundle>content/language.properties</resource-bundle>
" but it was flagging a warning in Eclipse that file name should not end with .properties. So You have tried again this:<resource-bundle>content/language.properties</resource-bundle>
and it worked?
9年前 に Akash Jaisawal によって更新されました。
RE: How to change portlet title on the basis of language selected?
Regular Member 投稿: 141 参加年月日: 12/03/03 最新の投稿
Or there should be only:
Sorry if am wrong somewhere!
<resource-bundle>content/language</resource-bundle>
?Sorry if am wrong somewhere!
9年前 に Neetu Mishra によって更新されました。
RE: How to change portlet title on the basis of language selected?
Junior Member 投稿: 75 参加年月日: 12/05/21 最新の投稿Akash Jaisawal:
Or there should be only:?<resource-bundle>content/language</resource-bundle>
Sorry if am wrong somewhere!
Hi Akash,
Thanks for correcting me
I have tried this:
<resource-bundle>content/language</resource-bundle>
9年前 に Akash Jaisawal によって更新されました。
RE: How to change portlet title on the basis of language selected?
Regular Member 投稿: 141 参加年月日: 12/03/03 最新の投稿Neetu Mishra:
Akash Jaisawal:Or there should be only:?<resource-bundle>content/language</resource-bundle>
Sorry if am wrong somewhere!
Hi Akash,
Thanks for correcting me
I have tried this:<resource-bundle>content/language</resource-bundle>
Hello Neetu,
I ve followed these steps but not succeed to achieve the task!
any other way to change the title programmatically?
9年前 に Neetu Mishra によって更新されました。
RE: How to change portlet title on the basis of language selected?
Junior Member 投稿: 75 参加年月日: 12/05/21 最新の投稿
hi Akash,
There is no other way to change the title programatically
There is no other way to change the title programatically
9年前 に Akash Jaisawal によって更新されました。
RE: How to change portlet title on the basis of language selected?
Regular Member 投稿: 141 参加年月日: 12/03/03 最新の投稿Neetu Mishra:
hi Akash,
There is no other way to change the title programatically
ohh..
I tried all the steps you mentioned bit nothing happns
9年前 に Vipin Bardia によって更新されました。
RE: How to change portlet title on the basis of language selected?
Regular Member 投稿: 162 参加年月日: 11/02/28 最新の投稿
Hi Akash,
This should work -
Regards.
This should work -
renderResponse.setTitle(LanguageUtil.get(renderRequest.getLocale(), "keyname"));
Regards.
9年前 に Shreyas Kamthe によって更新されました。
RE: How to change portlet title on the basis of language selected?
Junior Member 投稿: 58 参加年月日: 14/06/09 最新の投稿
Hi everybody,
Can anybody tell me how to customize the portlet for a new added language.
I am trying to set the title to the newly added language but the title shows me "????" .
Can anybody suggest me a solution ?
Is this because i have not made an entry in the portlet.xml ?
Please do reply
Can anybody tell me how to customize the portlet for a new added language.
I am trying to set the title to the newly added language but the title shows me "????" .
Can anybody suggest me a solution ?
Is this because i have not made an entry in the portlet.xml ?
Please do reply