• 0

simultaneous HTTP requests to multiple addresses?


Question

suppose i have 3 different addresses (well, different port numbers) :

http://127.0.0.1:8888

http://127.0.0.1:8889

http://127.0.0.1:8890

and i wish to send an identical HTTP request to those addresses , all at the same time

what is the best method to accomplish this?

ideally, i would like some kind of webpage made up of two halves... one half is to choose what is the HTTP request to send (something like what the HTML href 1.htm , href 2.htm, href 3.htm and so on... do) , and the other half is a list of checkboxes to select which addresses to send the HTTP request to

Link to comment
Share on other sites

5 answers to this question

Recommended Posts

  • 0

I hope you are sure that you have specific reason to do it like that. Anyway, you didn't specify the language.

If it's client side, then you can use JavaScript and Ajax. If you use some API, like jQuery, the job is extremely easy.

If you are doing server side programming, you can do the requests with the language you are using. For example, with PHP you can use cURL.

Link to comment
Share on other sites

  • 0

i am using this:

http://r4.rabidhamster.org/phpBB3/viewtopic.php?f=6&t=105

as well, I also have 4 monitors hooked up to my computer at once (hence the 127.0.0.1 with 3 different port numbers, the fourth screen is used to display the webpage)

so I have 3 processes listening at port 8888,8889 and 8890 , and i want to issue commands to them simultaneously... these processes respond to HTTP requests like that which is generated by this html code:

 <a target="CMD" href="cmd.html?cmd=addovr&sc=134">

Link to comment
Share on other sites

  • 0

Use PHP for this, you can't do AJAX requests across domains, IPs or ports.

Can if you use image, frame, link, script, form or canvas elements as the middle man, but that isn't ajax neither recommended :D

Link to comment
Share on other sites

This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.