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

  • Home
  • SEARCH
  • 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 8689221
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T23:35:25+00:00 2026-06-12T23:35:25+00:00

I am working on MVC 4 Web Api with Jquery and Jqgrid, till now

  • 0

I am working on MVC 4 Web Api with Jquery and Jqgrid, till now I was posting multiple data to my post controller action.

My action looked like the one below…

[ActionName("FetchProducts")]
public List<ABC> PostProducts(Product model)
{
    return _service.GetSomething(model);
}

public class Product{
    public string Name {get;set;}
    public string Category {get;set;}
    //.... and alteast 5 more properties
}

and my jquery call was something like the one below…

$.ajax({  
type: "POST",  
url: /api/FetchProduct,  
data: this.getData(),  
contentType: "application/json; charset=utf-8",
dataType: "json",
success: callback
});

function getData(){
    return JSON.stringify({
            Name: "from somewhere" ,
            Category: "from somewhere",
            Price: "from somewhere",
            ABC: "from somewhere",
            XYZ: "from somewhere",
            //... and many more....
        }); 
}

and this works ! but my friend at work says

I am actually only getting data and should use ‘GET’ and not ‘POST’. As GET is used to retrieve remote data, and POST is used to insert/update remote data.

and I also feel he is right. So how should I do this with ‘GET’ ?

do I have to pass all these parameters (there are atleast 10 of them) as query string ?

like for eg : api/FetchProduct/?Name='aaa'&&Category='vvv'&&.........

So my question is what should one do in such a scenario ? I would like to know what other devs think about this. Thanks

  • 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-06-12T23:35:26+00:00Added an answer on June 12, 2026 at 11:35 pm

    As you query string grows, you will run into problems with the maximum length of the URL, which is browser dependent.

    If you have a lot of parameters to pass, a POST is perfectly acceptable even if you are really only GETting data. What you will lose, however, is the ability for the user to bookmark a particular page with the query string.

    One case where you should absolutely never use GET is if any of the parameters you are passing are sensitive.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a ASP.NET MVC 4 application with Web API. It's working great. But
I'm working with the mvc 4 web api to build a service layer that
Here's the situation. What I am working with: - ASP.NET MVC 4 Web API
I have a working ASP.NET MVC web application to manage projects and customers. Now
I'm experienced in working with MVC web applications (Zend Framework). When I was looking
I'm working on a MVC based web app on LAMP that needs some records
I'm working on an intranet MVC web application, using Fluent NHibernate. As everyone knows,
I'm currently working on an Asp.net MVC Web application. In my solution, there're two
I am working on a sql server 2008 DB and asp.net mvc web E-commerce
When working with web-designers in a Spring-MVC and JSP environment, are there any tools

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.