I like this Idea but, how do you solve language issue?
I mean, how can i do in concrete class to provide a different title
depending on language.

Now i'm working with a properties file with <wicket:message key="page.title"
/>
Defining a properties file for every page it seems to work but it is not so
confortable.

Thanks for the answer!


2011/4/12 Michael O'Cleirigh <[email protected]>

> You can normally use wicket in the <head> or <wicket:head> sections.
>
> I use this approach to set my page favicon (which is the <link> tag).
>
> It should also work for the <title> tag.
>
> e.g. put a wicket:id into the title tag in the head section of the base
> page:
>
> <html>
> <head>
> <title wicket:id="title"></title>
> </head>
> <body>
> <wicket:child/>
> </body>
> </html>
>
> And then in your BasePage:
>
> onInitialize() {
>
>    add (new Label("title", provideTitleModel());
>
> }
>
> /**
>  * Let the concrete child classes provide the content for the title.
>  */
> protected abstract IModel<String>provideTitleModel();
>
> Regards,
>
> Mike
>
>  Hi I don't know the best way to make title of page depends on subpage.
>>
>> I have a BasePage with a header, footer, etc. My concrete pages extends
>> from
>> BasePage. Then I want to have different title on each page.
>>
>> What do you recomend?
>>
>> Thanks
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>
>

Reply via email to