Form submission with multiple targets

Discussions

Web tier: servlets, JSP, Web frameworks: Form submission with multiple targets

  1. Form submission with multiple targets (2 messages)

    Is there anyway way I can forward my request parameters to multiple websites?

    I run a web site that stores links to guestbooks. I would like to create a form that would be able to submit its contents to multiple targets.

    I.E.

    User fills details into a form
    User hits submit
    A servlet takes those parameters and sends it to the appropriate targets

    In the backend, I would query the appropriate targets and send the request parameters to those targets.

    Basically I want to be able to (legitimately) spam guestbooks instead of having to visit each guestbook to make my form submissions. Thanks in advance for any ideas.

     
  2. Server side:

    After u get the list of the targets, for every target create a URL connection and set all the form paramters in the URL Connection object and do the submit to the target.

    May be u can use this helper class from Servlets.com. Actually u can implement this by urself but anyways this might help in making the HTTP related GET, POST kind of requests without having to understand URL, URLConnection etc..

    http://servlets.com/cos/javadoc/com/oreilly/servlet/HttpMessage.html


    Client Side:
    ------------
    U can also do this from the client side ...

    Create a javascript array with the list of targets that u want to submit the form to.

    Have a dummy frame (Hidden frame with size 1,1) and have a dummy form with all the form parameters in HIDDEN tags.
    When the user submits the actual form, loop through all the targets and update the hidden frame's form with the actual form values and set the proper target and submit. After some delay, load the hidden frame again with the initial dummy hidden form page, and do the same operation till u finish all the targets.

    There are so many other ways u can do this ... doesn't necessarily have to be a hidden frame ...

  3. Form submission with multiple targets[ Go to top ]

    thanks! i'll give the server side solution a shot :)