so to make it clear
when you click on the link (that popups up the popup)
you also want to submit the form?
That is not possible because its a normal link. That doesn't a submit.
For this you have to make that link somekind of submit button.

But popup a window when you submit the form must be handled differently i
guess
by submitting the form as normal to the normal page. And then append some
javascript
to the return page that popups the window.

or you could try to have a submit button that sets the target of the form to
a different window
But then when you click that button you fist have some javascript that sets
the target of the form
before it submits the form.

johan


On 2/7/07, Borst, Gordon <[EMAIL PROTECTED]> wrote:

Hi...

Sorry for that.. I will try again with example...

I have 2 classes. "DataPresentation" with the PageLink und the class
"UpdatePage" extends WebPage.
It is a problem similar to the linkomatic example of wicket, where a popup
is create by BookmarkablePagelink,
But i has to fire an onsubmit function before loading popup.


Extract from DataPresentation.html:

<form wicket:id="dateSelectForm" onSubmit="selectAll()">

        ... all the stuff of formular ...

    <div class="bottomLine">

        <input wicket:id="submitButton" type="submit" value="Weiter"
style="width:200px;" />

    </div>
</form>



Extract from DataPresentation.java:

....
// Add the submit button
// this was the old version

//add(new Button("submitButton"));


            //POPUP
                // new way to solve the problem with popup

            PopupSettings popupSettings = new PopupSettings(
PageMap.forName
("popuppagemap"),
PopupSettings.SCROLLBARS | PopupSettings.RESIZABLE ).setHeight(
                                768).setWidth(1024);

                // Popup example

            BookmarkablePageLink BPLink = new
BookmarkablePageLink("submitButton", UpdatePage.class)
            {
                public void onClick()
                        {

                        }
            };

            BPLink.setPopupSettings(popupSettings);
            add(BPLink);



                // for the old version with simple Button
                public void onSubmit()
                {
                        // Make a FilterSettings object and add the lists
of selected filters
                        // all filters will be added in HashMap (
filterMap ) of FilterSettingsInstance "settings"
                   FilterSettings settings = new FilterSettings();
                   addFilterList(FilterSettings.FilterType.host,    hostFilters,
settings);
                   addFilterList(FilterSettings.FilterType.domain,  
domainFilters,
settings);
                   addFilterList(FilterSettings.FilterType.service,
serviceFilters, settings);
                   addFilterList(FilterSettings.FilterType.process,
processFilters, settings);

                   // Set the grouping type
                   // takes grouping from html and cast and save the model
in groupingType of settings
                   settings.setGroupingType((FilterSettings.FilterType)
get("grouping").getModelObject());


                   // Update PointOfView by Model
                   PointOfView.setPointOfView( (PointOfView.POVType)
get("poviews").getModelObject() );

                   // Set Memory
                   Memory.setPage(this.findPage());
                   Memory.setSelViews( selectedViews );
                   Memory.setTFrame( timeFrame );
                   Memory.setFSettings( settings );


           // For all selected views
           for(Iterator it = selectedViews.iterator(); it.hasNext(); )
           {
                   TimeSeriesSet numberOfCallsValues = null;

                   switch((ViewType)it.next())
                   {

                   // Number of calls
                   case numberOfCalls:

                           // Read the "number of calls" values from the
database
                           if (numberOfCallsValues == null)
                           {
                                   numberOfCallsValues =
readNumberOfCalls(timeFrame, settings);
                           Memory.setCallValues( numberOfCallsValues );
                           }
                           break;

                   // Call duration
                   case durationOfCalls:

                           // Read the "average duration" values from the
database
                           if (numberOfCallsValues == null)
                           {
                                   numberOfCallsValues =
readAvgDuration(timeFrame, settings);
                           Memory.setDurValues( numberOfCallsValues );
                           }
                           break;
                   } // switch

           } // for

                   // Set the next page
           setResponsePage(UpdatePage.update());
        }
...



So the onClick()-function is still used for this PageLink... But before
open the popup with "UpdatePage"
I has to fire the onSubmit function.

Can i overload the onClick-function or how does it work???

Thanks in advance

Gordon Borst







-------------------------------------------------------------------------------------

-----Ursprüngliche Nachricht-----
Von: [EMAIL PROTECTED] [mailto:
[EMAIL PROTECTED] Im Auftrag von Eelco Hillenius
Gesendet: Mittwoch, 7. Februar 2007 05:39
An: wicket-user@lists.sourceforge.net
Betreff: Re: [Wicket-user] Problem: BookmarkablePageLink does not
fireonSubmit...


I'm afraid I don't understand your problem... Could you explain with some
example code maybe? Or something in a quickstart?

Eelco


On 2/6/07, Borst, Gordon <[EMAIL PROTECTED]> wrote:
>
>
>
> Good Morning,
>
> In a project I tried to create an interface with two html-pages.
>
> The first page is a form with a final submit button... The
> onsubmit()-function works fine and all datas are updated fine by their
> models.
>
> This was so when the second page, so called presentation page was
> loaded in the same window.
>
> Now i tried to add a BookmarkablePageLink, and excluded all statements
> to build the new page in on UpdatePage-Class which will be called.
>
> This new Page in the Popup ( so also the presentation page ) has only
> the default dataset and not the selected date because no onsubmit()
> will by called
>
> When firing the SubmitButton.
>
> Why is this so? How do i manage this or is there any other way to call
> a new page with wicket??
>
> Thanks for any kind of help
>
> _______________________________________
>
> Mit freundlichen Grüßen
>
> Gordon Borst
>  T-Systems GEI GmbH
>
> Industry Business Unit Telecommunications
> Solution & Service Center Billing
> Billing EAI ( G 118 )
>
> Hausadresse: Pascalstraße 51, 52076 Aachen
>  Postanschrift : Postfach 500 144, 52085 Aachen
>  Telefon: +49 (2408) 943 - 18 77
>  Email: [EMAIL PROTECTED]
>
> ----------------------------------------------------------------------
> ---
> Using Tomcat but need to do more? Need to support web services,
security?
> Get stuff done quickly with pre-integrated technology to make your job
> easier.
> Download IBM WebSphere Application Server v.1.0.1 based on Apache
Geronimo
> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
> _______________________________________________
> Wicket-user mailing list
> Wicket-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wicket-user
>
>

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job
easier. Download IBM WebSphere Application Server v.1.0.1 based on Apache
Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job
easier.
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier.
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

Reply via email to