-
1. Re: Changing Page name and Portlet title
mholzner Jan 3, 2006 9:14 AM (in response to jency)The title that is shown in the browser is set by the layout.
In the portal core war look for layouts/generic/index.jsp , and there for the title tag.
The title of each portlet is set in the portlet.xml descriptor
Look for the portlets you want to change the title for (their title) and change it in the portlet.xml -
2. Re: Changing Page name and Portlet title
vmarco Jan 3, 2006 3:41 PM (in response to jency)Martin,
I had this same problem. I found the page names, however, the docs indicate there must be a page named "default". I would like my default page to be named "Home".
Can I do this in configuration?
I did code around it with a new NavigationPortlet, but if it can be done in configuration, I'd rather do it there. -
3. Re: Changing Page name and Portlet title
mholzner Jan 3, 2006 4:52 PM (in response to jency)To my knowledge the 'default' is hard coded in 2.2. I don't know any way around it without coding. So I guess you did what was necessary.
see also http://jira.jboss.com/jira/browse/JBPORTAL-465 -
4. Re: Changing Page name and Portlet title
julien1 Jan 3, 2006 5:05 PM (in response to jency)we could add a default name property at the parent node that would say which page to look for as default page to handle that.
-
5. Re: Changing Page name and Portlet title
vmarco Jan 3, 2006 7:20 PM (in response to jency)"mholzner" wrote:
The title that is shown in the browser is set by the layout.
In the portal core war look for layouts/generic/index.jsp , and there for the title tag.
Doesn't this prevent me from controlling the title per page? Doesn't it also means to control the title of my site I am now required to create my own layout? I must be missing something here. I should have the ability to specify both a site-wide title or per page title in the *-object.xml descriptor. Otherwise the ability to reuse layouts will be severely diminished."mholzner" wrote:
The title of each portlet is set in the portlet.xml descriptor
Look for the portlets you want to change the title for (their title) and change it in the portlet.xml
This approach also seems insufficient. Shouldn't I be able to specify the title on a per PortletInstance or Window granularity. That way I could have multiple windows of the same Portlet (or multiple instances of the same portlet) with different displayed titles.
I think the title in the portlet.xml is great for a default though.
My 2 cents. -
6. Re: Changing Page name and Portlet title
jency Jan 4, 2006 4:22 AM (in response to jency)Do you mean we cannot change the name "default" for the default page(tab)?
The title for portlets can be changed via portlet.xml; but the "default" page contains a portlet whose title is "JBoss portal" and I could not find any reference to it portlet.xml. Which files should I modify to change this?
Thanks in advance
Jency -
7. Re: Changing Page name and Portlet title
mholzner Jan 4, 2006 11:25 AM (in response to jency)"vmarco" wrote:
Doesn't this prevent me from controlling the title per page? Doesn't it also means to control the title of my site I am now required to create my own layout? I must be missing something here. I should have the ability to specify both a site-wide title or per page title in the *-object.xml descriptor. Otherwise the ability to reuse layouts will be severely diminished.
I agree that this isn't at a level where it should be at the moment, but it should be rather simple to write a jsp tag that allows the layout to set the title via a JSTL expression (that can use the current page's title or whatever to create the title string); Once we have that, then what about localization of the page title? That's missing as well so far. Remeber: this is open source so feel free to chime in ;)"vmarco" wrote:
This approach also seems insufficient. Shouldn't I be able to specify the title on a per PortletInstance or Window granularity. That way I could have multiple windows of the same Portlet (or multiple instances of the same portlet) with different displayed titles.
I agree 100%, but I'm not sure if this is currenty possible (i.e. I don't think so); again: the window title should be localizable as well -
8. Re: Changing Page name and Portlet title
mholzner Jan 4, 2006 11:32 AM (in response to jency)"jency" wrote:
Do you mean we cannot change the name "default" for the default page(tab)?
At the moment (2.2), yes, that's what I'm saying. Not without coding."jency" wrote:
The title for portlets can be changed via portlet.xml; but the "default" page contains a portlet whose title is "JBoss portal" and I could not find any reference to it portlet.xml. Which files should I modify to change this?
I'll have to look at that. My build is currently broken, so give me some time ;) -
9. Re: Changing Page name and Portlet title
vmarco Jan 4, 2006 1:18 PM (in response to jency)"mholzner" wrote:
I agree that this isn't at a level where it should be at the moment, but it should be rather simple to write a jsp tag that allows the layout to set the title via a JSTL expression (that can use the current page's title or whatever to create the title string); Once we have that, then what about localization of the page title? That's missing as well so far. Remeber: this is open source so feel free to chime in ;)
Yeah, I figured this would eventually be done much like regions are pulled in with the <p:region> tag. I'm still ramping up on this portal framework. Once I have a portal under my belt, I do plan to jump in and contribute. Just need to make sure I'm not missing an intended API or descriptor setting."mholzner" wrote:
I agree 100%, but I'm not sure if this is currenty possible (i.e. I don't think so); again: the window title should be localizable as well
Good. I am both patient and willing to contribute down the road on these things, but feel I shouldn't waste time as a contributor just coming up to speed on basics of using the product. Just like with the portal, I too need to walk before I run with this thing. -
10. Re: Changing Page name and Portlet title
mholzner Jan 4, 2006 6:23 PM (in response to jency)"jency" wrote:
The title for portlets can be changed via portlet.xml; but the "default" page contains a portlet whose title is "JBoss portal" and I could not find any reference to it portlet.xml. Which files should I modify to change this?
This portlet is the CMSPortlet. It sets the title programmatically at runtime.
The title comes from the file name that is currently displayed :String title = (file.getContent().getTitle() != null) ? file.getContent().getTitle() : file.getContent().getName(); resp.setTitle(title);
-
11. Re: Changing Page name and Portlet title
ramesa Jan 4, 2006 11:44 PM (in response to jency)Hi Jency,
If u r using Jboss portal 2.0 change the title hard coded value jboss portal 2.0 as u wish like My portal in jboss/server/default/deploy/jboss-portal.sar/portal-core.war/index.jsp. Restart the server and check it is changed to the title u wish.
Regards,
Ramesa -
12. Re: Changing Page name and Portlet title
jency Jan 5, 2006 7:38 AM (in response to jency)Martin,
As you said, this is the CMSPortlet. But in which file should I modify the code to change the "JBoss Portal" title?
Thanks
Jency