Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 857303
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 15, 20262026-05-15T08:22:43+00:00 2026-05-15T08:22:43+00:00

How can i send an Array with a HTTP Get request? I’m Using GWT

  • 0

How can i send an Array with a HTTP Get request?

I’m Using GWT client to send the request.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-15T08:22:44+00:00Added an answer on May 15, 2026 at 8:22 am

    That depends on what the target server accepts. There is no definitive standard for this. See also a.o. Wikipedia: Query string:

    While there is no definitive standard, most web frameworks allow multiple values to be associated with a single field (e.g. field1=value1&field1=value2&field2=value3).[4][5]

    Generally, when the target server uses a strong typed programming language like Java (Servlet), then you can just send them as multiple parameters with the same name. The API usually offers a dedicated method to obtain multiple parameter values as an array.

    foo=value1&foo=value2&foo=value3
    
    String[] foo = request.getParameterValues("foo"); // [value1, value2, value3]
    

    The request.getParameter("foo") will also work on it, but it’ll return only the first value.

    String foo = request.getParameter("foo"); // value1
    

    And, when the target server uses a weak typed language like PHP or RoR, then you need to suffix the parameter name with braces [] in order to trigger the language to return an array of values instead of a single value.

    foo[]=value1&foo[]=value2&foo[]=value3
    
    $foo = $_GET["foo"]; // [value1, value2, value3]
    echo is_array($foo); // true
    

    In case you still use foo=value1&foo=value2&foo=value3, then it’ll return only the first value.

    $foo = $_GET["foo"]; // value1
    echo is_array($foo); // false
    

    Do note that when you send foo[]=value1&foo[]=value2&foo[]=value3 to a Java Servlet, then you can still obtain them, but you’d need to use the exact parameter name including the braces.

    String[] foo = request.getParameterValues("foo[]"); // [value1, value2, value3]
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Using cURL I can send a GET request with a body. Example: curl -i
I'm using C++ and wondering if I can just send an entire int array
I can send requests to friends using Multi Friend Request Selector inside my Page
How can i send an array from the masterViewController to the DetailViewController in a
I can only send string or numeric values,how to send an array?
I know that soap can send XML over http, is there any way to
I'm transferring files from an existing http request using cURL like so... $postargs =
Problem : How can I get a successful TURN Connection using the iOS XMPPFramework
How this UIButton rewind can send notification to UIButton play to perform playpauseaction method
In Javascript I can send XML string to JSP server (XmlAction.jsp): Javascript Code: var

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.