Thats an RFE already. I'm not yet sure what the best approach is. Just thinking.
Juergen On 11/9/05, Johan Compagner <[EMAIL PROTECTED]> wrote: > ok then pre process and do it at markup loading time. > The only problem i see with this then that people will start to complaind > that they don't > see changes when they alter there messages > So suddenly we also have to watch those?? > > johan > > > > On 11/9/05, Juergen Donnerstag <[EMAIL PROTECTED]> wrote: > > > > On 11/9/05, Johan Compagner <[EMAIL PROTECTED]> wrote: > > > if you do the replacement at parse time. > > > then every html in the markup cache is specified by a locale? > > > (even if there is not locale in the name of the html) > > > > > > > Thats already the case. The markup id includes locale style etc. But > > multiple entries may reference the same markup file. > > > > > To me it looks like that <wicket:message can only be executed at > runtime > > > because then the locale is know > > > > But it is known at markup load time as well. We even take it into > > consideration to search for the proper markup file: > > <name>_<locale>_<style>.html > > > > > But we could store one for every locale we encouter if that is > > > faster/better somehow > > > > > > johan > > > > > > > > > > > > On 11/9/05, Juergen Donnerstag < [EMAIL PROTECTED]> wrote: > > > > > > > > We have different options (as explained in my first mail) > > > > - do the replacement while loading the markup, prior to xml reading > > > > it. The cached version will have the messages replaced > > > > - analyze the attributes while reading xml. The cached version will > > > > have the messages replaced for the attrbutes. <wicket:message> will be > > > > "executed" at render time > > > > - do the replacement after rendering the page. Some kind of > > > post-processing > > > > > > > > Not sure yet what the best approach is > > > > > > > > Juergen > > > > > > > > On 11/9/05, Andrew Berman < [EMAIL PROTECTED]> wrote: > > > > > Hmmm....well, I do think it would provide value to have the > attribute > > > way as > > > > > well. How much slower do you think it is going to make it? Anyone > else > > > > > have any suggestions? > > > > > > > > > > --Andrew > > > > > > > > > > > > > > > On 11/9/05, Johan Compagner < [EMAIL PROTECTED] > wrote: > > > > > > i can live with: > > > > > > > > > > > > <wicket:message key="..">Default Text</wicket:message> > > > > > > > > > > > > and > > > > > > > > > > > > <input type="button" value="message:key=my-key"/> > > > > > > > > > > > > But i think the second one will be pretty hard. > > > > > > Because then we have to parse the complete xml and see if in any > > > attribute > > > > > something starts with message:key > > > > > > even for non wicket tags as above? > > > > > > > > > > > > johan > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > On 11/9/05, Andrew Berman <[EMAIL PROTECTED] > wrote: > > > > > > > Oh and the other nice feature would be that if you do it like > this: > > > > > <wicket:message key="..">My Text</wicket> that the My Text would be > the > > > > > default text if the key is not found. > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > On 11/9/05, Andrew Berman <[EMAIL PROTECTED]> wrote: > > > > > > > > Well, I guess not being able to do it in JavaScript would be > ok, > > > but I > > > > > think there definitely needs to be a way to do it in attributes. > > > > > > > > > > > > > > > > Here is the link for how Tapestry 4.0 does it: > > > > > > > > > http://jakarta.apache.org/tapestry/UsersGuide/localization.html > > > > > > > > > > > > > > > > --Andrew > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > On 11/9/05, Juergen Donnerstag < [EMAIL PROTECTED] > > > > > wrote: > > > > > > > > > On 11/9/05, Andrew Berman < [EMAIL PROTECTED]> wrote: > > > > > > > > > > I like <wicket:message key=".."/> as long as it would work > how > > > > > normal JSP > > > > > > > > > > tags currently work. In other words, I would be able to > do > > > this: > > > > > > > > > > > > > > > > > > > > <input type="button" value="<wicket:message > > > key='labelKey'/>"/> > > > > > > > > > > > > > > > > > > > > or > > > > > > > > > > > > > > > > > > > > <script> > > > > > > > > > > alert("<wicket:message key='labelKey'/>"); > > > > > > > > > > </script> > > > > > > > > > > > > > > > > > > > > > > > > > > > > No, that was not the intend and I don't like it either. > > > > > > > > > <wicket:message ..> would be a normal XML tag. To retrieve a > > > i18n > > > > > > > > > message for a tag attribute I'd go for <input type="button" > > > > > > > > > value="message:key='labelKey'/>"/>. > > > > > > > > > > > > > > > > > > The following is a bit tricky and I'm not sure how well > it'll > > > realy > > > > > > > > > work, because you kind of have to analyze JS. > > > > > > > > > <script> > > > > > > > > > alert("message:key='labelKey'/>"); > > > > > > > > > </script> > > > > > > > > > > > > > > > > > > Juergen > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > ------------------------------------------------------- > > > > > > > > > SF.Net email is sponsored by: > > > > > > > > > Tame your development challenges with Apache's Geronimo App > > > Server. > > > > > Download > > > > > > > > > it for free - -and be entered to win a 42" plasma tv or your > > > very > > > > > own > > > > > > > > > Sony(tm)PSP. Click here to play: > > > > > http://sourceforge.net/geronimo.php > > > > > > > > > > _______________________________________________ > > > > > > > > > Wicket-user mailing list > > > > > > > > > Wicket-user@lists.sourceforge.net > > > > > > > > > > > > > > > > > > https://lists.sourceforge.net/lists/listinfo/wicket-user > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > ------------------------------------------------------- > > > > SF.Net email is sponsored by: > > > > Tame your development challenges with Apache's Geronimo App Server. > > > Download > > > > it for free - -and be entered to win a 42" plasma tv or your very own > > > > Sony(tm)PSP. Click here to play: > > > http://sourceforge.net/geronimo.php > > > > _______________________________________________ > > > > Wicket-user mailing list > > > > Wicket-user@lists.sourceforge.net > > > > > https://lists.sourceforge.net/lists/listinfo/wicket-user > > > > > > > > > > > > > > > > ------------------------------------------------------- > > SF.Net email is sponsored by: > > Tame your development challenges with Apache's Geronimo App Server. > Download > > it for free - -and be entered to win a 42" plasma tv or your very own > > Sony(tm)PSP. Click here to play: > http://sourceforge.net/geronimo.php > > _______________________________________________ > > Wicket-user mailing list > > Wicket-user@lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/wicket-user > > > > ------------------------------------------------------- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42" plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php _______________________________________________ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user