Yes, but the problem is that I wanted to be able to simply write
something like <input type="text" id="calenrdar1"/> to create a pop-up
calendar :(.
I can easily replicate javascript code, so that it is repeated in
every occurence of the component, but there is a <div> that should be
displayed only once, right after <head> tag.  I already have a working
version that requires the user to add a seperate component for the
<div>, I have done it with the old wicket 0.9.2-alpha (last time I had
some slack time :) ), but it is a duct-tape solution...

:(

Thanks,
Kamil


On Mon, 7 Feb 2005 14:58:04 +0100, Maurice Marrink
<[EMAIL PROTECTED]> wrote:
> I too use a lot of JavaScript with and in popups.
> And I have decoupled it as much as possible just like juergen suggests.
> 
> I even use the container he mentions. It's very easy, just create a
> dummy Panel and put this in the html file :
> <wicket:panel>
>         <span id="wicket-script">
>         <!-- if you want generated script just put a label on the panel
> with your script -->
>         </span>
> <!-- or use the script tag directly -->
> </wicket:panel>
> 
> in the body onload I execute the function in my panel only if it exists:
> if(window.functionName)
>         functionName();
> 
> Maurice
> 
> -----Oorspronkelijk bericht-----
> Van: Juergen Donnerstag [mailto:[EMAIL PROTECTED]
> Verzonden: maandag 7 februari 2005 14:24
> Aan: [email protected]
> Onderwerp: Re: [Wicket-develop] java script - "insertion points"
> 
> Kamil,
> 
> yes there has been a discussion around it and we decided not to put it
> into 1.0. The workarounds I can think of:
> 
> a) simply put the reference to *.js into the header section of your
> page markup or inline it. You're component than doesn't know anything
> about it, but would rely on it. I know that this approach is not super
> elegant (javascript and component disconnected), but it is easy and it
> works.
> 
> b) your component may have a <div id="wicket-myscript"> region
> (actually a HtmlContainer), which you yourself
> setVisible(true/false).The region may contain the inline javascript.
> 
> c) Eelco has designed some components in order to tests his ideas.
> Sorry, but I forgot how exactly they work (please scan the mail
> archiv). May be he provides an example to you
> 
> Juergen
> 
> On Mon, 7 Feb 2005 13:56:16 +0100, Kamil Rembalski <[EMAIL PROTECTED]>
> wrote:
> > Hi guys,
> >
> > I am trying to create a popup calendar component, which involves
> > massive javascript. I remember a discussion about special markup
> > elements that would allow the components to render some parts of their
> > markup only once per page and in the given section. Was there any
> > progress on this since then? I can't think of any elegant workaround
> > and I can't do without it... This may quite an issue for some
> > components...
> >
> > Cheers,
> > Kamil
> >
> > -------------------------------------------------------
> > This SF.Net email is sponsored by: IntelliVIEW -- Interactive
> Reporting
> > Tool for open source databases. Create drag-&-drop reports. Save time
> > by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc.
> > Download a FREE copy at http://www.intelliview.com/go/osdn_nl
> > _______________________________________________
> > Wicket-develop mailing list
> > [email protected]
> > https://lists.sourceforge.net/lists/listinfo/wicket-develop
> >
> 
> -------------------------------------------------------
> This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting
> Tool for open source databases. Create drag-&-drop reports. Save time
> by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc.
> Download a FREE copy at http://www.intelliview.com/go/osdn_nl
> _______________________________________________
> Wicket-develop mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/wicket-develop
> 
> -------------------------------------------------------
> This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting
> Tool for open source databases. Create drag-&-drop reports. Save time
> by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc.
> Download a FREE copy at http://www.intelliview.com/go/osdn_nl
> _______________________________________________
> Wicket-develop mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/wicket-develop
>


-------------------------------------------------------
This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting
Tool for open source databases. Create drag-&-drop reports. Save time
by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc.
Download a FREE copy at http://www.intelliview.com/go/osdn_nl
_______________________________________________
Wicket-develop mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/wicket-develop

Reply via email to