Questions tagged [querystringparameter]

A query string parameter is a name-value pair in the query string of the URL of a certain web page. It can be used to manipulate the content on the page.

querystringparameter
Filter by
Sorted by
Tagged with
789 votes
35 answers
1.7m views

How to get URL parameter using jQuery or plain JavaScript?

I have seen lots of jQuery examples where parameter size and name are unknown. My URL is only going to ever have 1 string: http://example.com?sent=yes I just want to detect: Does sent exist? Is it ...
LeBlaireau's user avatar
  • 17.3k
591 votes
12 answers
1.1m views

How to pass an array within a query string?

Is there a standard way of passing an array through a query string? To be clear, I have a query string with multiple values, one of which would be an array value. I want that query string value to be ...
Yarin's user avatar
  • 179k
77 votes
4 answers
75k views

Build query string from parameters object

How to build a url with query parameters in Angularjs. I see the API $location.search() the problem is $location(url) is to redirect to the url. In my case, I want to pass a url and key:value pairs ...
bsr's user avatar
  • 58k
29 votes
3 answers
27k views

How to parse/read multiple parameters with restify framework for Node.JS

Scenario: We developer are trying to replace a web service (written in C#.Net) with Node.JS Restful API. Issue: Now we need to handle the incoming request as is (we don't have control over it). So ...
Amol M Kulkarni's user avatar
25 votes
4 answers
12k views

Django Admin Custom Change List Arguments: Override /?e=1

I'm trying to pass in a custom argument to the Django Admin change list view so I can filter the list in a specialized way. I'd like to filter the queryset on 2 fields, start_date and end_date, based ...
Joe J's user avatar
  • 10.4k
24 votes
4 answers
60k views

Checking for null and missing query string parameters in PHP

I want to be able to distinguish between existing query string parameters set to null, and missing parameters. So the parts of the question are: How do I check if a parameter exists in the query ...
Yarin's user avatar
  • 179k
12 votes
3 answers
43k views

What is a valid URL query string?

What characters are allowed in an URL query string? Do query strings have to follow a particular format?
Aran Mulholland's user avatar
11 votes
3 answers
36k views

How to parse querystring parameter from URL in Fastify server?

I am a totally new to fastify but I have a fastify server running. I want to parse query string such as: http://fake.com/?user=123&name=ali I want to get "user" and "name" values from the URL ...
web developer guy's user avatar
10 votes
4 answers
11k views

Remove null params in HttpParams

I have a criteria object for which some attributes can be null, if I don't do anything the query string include those like &p=undefined which is not desirable since at the WebApi these come as"...
Anand's user avatar
  • 1,507
9 votes
2 answers
8k views

asp:QueryStringParameter and empty query string parameter

I haveasp:GridView displaying client requests using asp:SqlDataSource. I want to limit displayed information by client: View.aspx has to display everything, View.aspx?client=1 has to display only ...
abatishchev's user avatar
  • 99.2k
9 votes
4 answers
3k views

How to remove blank values params from query string

I have a search form, with lot of options, Submitted to a route with Get request. URL is something like this: http://localhost:3000/restaurants/search?utf8=%E2%9C%93&city=&cuisine=&...
Mohit Jain's user avatar
  • 43.6k
7 votes
1 answer
19k views

In Google Analytics 4 (GA4) how can I see page views by path and querystring when only "Page path and screen class" is available?

In GA4 Reports > Engagement > Pages and screens, above the list of pages viewed, there is a dropdown with the following options: Page title and screen class Page path and screen class Page ...
Andre Gibson's user avatar
5 votes
2 answers
28k views

how to return a view with querystring parameters in MVC5?

Very basic but not sure how to do since i am new to mvc. I have to return a view based on a if condition. if true, i should return a view with a guid value as querystring parameter else return a ...
kaarthick raman's user avatar
5 votes
4 answers
6k views

Cast all keys in dictionary to uppercase

This is probably a very simple question but google has let me down sofar and keeps pointing me towards python solutions. I have a webpage where applciations/users can supply querystringparameters.To ...
User999999's user avatar
  • 2,500
5 votes
1 answer
2k views

Having a custom QueryStringBindable in the scope with Play 2.4.3

I would like to have java.sql.Date and Option[java.sql.Date] in my Play-scala project as a query-paramater, which don't come as a default with the Play framework. Play-version I'm using is 2.4.3. I ...
mpartan's user avatar
  • 1,306
5 votes
1 answer
3k views

RouteUrl replace "&" with "&" in query string parameters

I have the following code: @Url.RouteUrl("NewMessage", new { parentThreadId = Model.thread.id, cacheBustParam = currentUserId }) When the page get rendered the page source looks like: /somepath/...
PanKak's user avatar
  • 133
5 votes
1 answer
2k views

How should you build an OData URI?

I'm looking to build URIs such as https://example.com/data/customers?$top=100. Is there a UriBuilder for creating OData URIs (i.e. which can handle characters such as $ appropriately)? Full info I ...
JohnLBevan's user avatar
  • 23.5k
4 votes
3 answers
19k views

MVC 3 Reload current page with modified querystring values

Background: I have an MVC layout (master) view which uses @Html.RenderAction to display a dropdown in the left side navigation panel. This dropdown will be displayed on all the pages of the site. ...
andytech's user avatar
  • 143
4 votes
2 answers
6k views

Get request URL from grails controller

My grails controller gets invoked by the following URLs /center/madrid/12-de-octubre /center/madrid/12-de-octubre?opt=1 I need the controller to behave differently if there are any parameters after ...
user3028981's user avatar
4 votes
1 answer
14k views

How to pass the value from one asp page to another asp page using queryString?

How to pass the value from one asp.net page to another asp.net web page using queryString.It means test1.aspx and test2.aspx are two web pages. In test1.aspx, i have the string value, string abc="...
V.V's user avatar
  • 873
4 votes
1 answer
7k views

mod_rewrite to change query string parameter name

I need help writing a mod rewrite rule to change the name of a query string parameter. I want to change the name, not the value. old name partner new name a_aid so a link like this http://domain....
ChatGPT's user avatar
  • 5,476
4 votes
1 answer
227 views

Recognize the pattern: what system is malforming my query string parameters?

We have a fairly complicated ASP.NET MVC project with cross domain login widgets and a lot of semi-legacy code. There is a system where we login people through an iframe. The url for the iframe we ...
Dirk Boer's user avatar
  • 8,845
3 votes
3 answers
16k views

Parse a query string parameter to java object

I have query string like that: ObjectGUId=1abcde&ObjectType=2&ObjectTitle=maximumoflife&Content=racroi&TimeStamp=2012-11-05T17:20:06.056 And I have Java Object: LogObject{ ...
Sonrobby's user avatar
  • 3,142
3 votes
6 answers
4k views

Parse form submission data from query string / jQuery.serialize() containing duplicate keys without losing values

I am trying to figure out how I can handle possible duplicate array keys. I have this form with a select dropdown which can select multiple options (more than 1). And I am using jQuery.serialize() to ...
user avatar
3 votes
3 answers
6k views

How to remove spaces from a query string using Jquery?

Iam using query sting in jquery to get URL values iam using function getUrlVars() { var vars = [], hash; var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&...
þÍńķ's user avatar
  • 353
3 votes
2 answers
5k views

asp.net SqlDataSource SelectCommand using LIKE with QueryString

<asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:ConnectionString %>" SelectCommand="SELECT ProductName, ProductPrice FROM Product WHERE (@type ...
Alvis Chen's user avatar
3 votes
1 answer
294 views

Jquery adding querystring parameter without page refreshing

I want to add query string to URL without refreshing page using Jquery. Is it possible? I don't want to use #. sample: http://test.com/prodcuts after appending query string http://test.com/...
user3194721's user avatar
3 votes
1 answer
2k views

ASP.NET DataPager not preserve the QueryString parameters order

I've a ListView with a DataPager the paging in the buttons (1,2,3,...) do not preserve the order of the parameters in querystring which is a bad thing in an SEO context (the bot thinks it is duplicate ...
arik's user avatar
  • 336
3 votes
0 answers
2k views

Idiomatic Query string parameter parsing in nodejs on AWS Lambda

Consider the following a nodeJS function running on AWS Lambda, serving http requests: module.exports.fetchLogLines = (event, context, callback) => { // Parse the 'token' param string argument ...
Adam Matan's user avatar
  • 132k
3 votes
1 answer
2k views

C# WebApi Query Parameter Parsing

I have a query string coming in from a jquery grid that I am trying to parse into parameters within C# Web API, but I am unable to get one of the properties to populate. Query String: ?current=1&...
Michael Sanders's user avatar
3 votes
1 answer
3k views

How to log query string parameters with Postman

I'm using the tests of Postman to log into the console some of the details included in a JSON response. The part of the test that logs is the following: var data = JSON.parse(responseBody); if (data....
Lele B.'s user avatar
  • 31
3 votes
1 answer
646 views

Provide a UIWebview with a querystring when using loadData

I am loading an HTML file into an UIWebview from the MainBundle and would like to pass in a query string, since the HTML file checks for a GET parameter (?device=1) to do some extra calculations. I ...
cornelius7's user avatar
3 votes
1 answer
3k views

WCF REST : Case insensitive Query String Parameters, suggested naming convention - use underscore or?

It appears the query string parameters you can pass to a rest method in WCF REST is case insesitive - actually this makes sense. What the best naming convention for parameters with 2 words, using an ...
Martin's user avatar
  • 24.1k
2 votes
1 answer
14k views

Using 'querystring.parse' built-in module's method in Node.JS to read/parse parameters

Scenario: Consider the following code: var querystring = require('querystring'); var ParamsWithValue = querystring.parse(req._url.query); Then I am able to read any query string's value. E.g: If ...
Amol M Kulkarni's user avatar
2 votes
2 answers
4k views

How to filter results by multiple query parameters if I don't know beforehand how many query strings I may receive from client side?

I want to send in response some data according to searching by query parameters (using .find function of mongoose) from the client side. What do I need to do is a search according to the parameters ...
fight_club's user avatar
2 votes
1 answer
1k views

Query string degenerate cases

I am looking around looking for a correct regualr expression for validating URI query strings. I found some answers here or here but I still have doubts on the edge cases, where the key or the value ...
marcosh's user avatar
  • 8,880
2 votes
2 answers
11k views

Redirecting to a page hiding query string parameters asp.net

I am working for a project which has web garden scenario and cannot keep any data in session/inmemory. The asp.net page opens from Appian(bpm tool) and we pass id through query string. Now, client is ...
rahulsen002's user avatar
2 votes
3 answers
9k views

How to escape backslashes in querystring

I have an SqlDataSource that takes a value from querystring and bind it with a gridview. Everything works nicely unless the querystring value has a backslash in it. How do I escape the backslash? ...
dam's user avatar
  • 171
2 votes
1 answer
1k views

Tool for parsing querystrings, creating URL encoded params etc?

before writing my own :-) I was wondering if anyone knows a tool to parse a URL and extract all the params into a easier viewable format, a grid maybe? (these urls are extremely long :- ) And also ...
Martin's user avatar
  • 24.1k
2 votes
1 answer
9k views

How to pass the query string parameters in the AWS API Gateway?

Following is my Lambda handler which is expecting the users data from the queryStringParameters:- export const lambdaHandler = async (event, context) => { try { const ...
vinod827's user avatar
  • 1,364
2 votes
1 answer
351 views

Does Express.js respect RFC-3986 for query string?

Does ExpressJs respect/use the RFC-3986 standard when decoding query string parameters? Why the direct char "è" is accepted but the encoded version "%E8" isn't? Test Expressjs http ...
Andrea Franchini's user avatar
2 votes
2 answers
5k views

Django Template: Add Variable Into URL As Parameter

What's the proper way to add {{gamestoday|lookup:i}} into the <a href={%url 'stats'%}>. Do I need to make changes to urls.py? {% load tags %} <center> <div class = "...
Bogdan Andrei's user avatar
2 votes
2 answers
7k views

construct a dynamic url using path variables in spring controller

i would like to generate a dynamic url like http://example.com/path/to/page?name=ferret&color=purple where i can send name and color two separate input fields from my form to controller as a ...
pradeep kumar 's user avatar
2 votes
2 answers
9k views

Error The length of the query string for this request exceeds the configured maxQueryStringLength value [duplicate]

Hi Im developing a web application its working fine but yesterday i had a problem when i click a link it gives error The length of the query string for this request exceeds the configured ...
skhurams's user avatar
  • 2,135
2 votes
0 answers
338 views

Alternative to System.Web.HttpUtility.ParseQueryString that uses a case-insensitive comparer?

If you include a query string on the HREF of the "Launch" link on the publish.htm page that ClickOnce generates when you publish a Windows desktop application: HREF="...
Tim's user avatar
  • 8,849
2 votes
0 answers
152 views

How to specify more then one value for one key in RouteValueDictionary [duplicate]

I need to redirect to a page with multiple values for the same querystring key. like: ?x=abc&x=yz This is a constraint, I can not change how this service accepts his parameters. How can this be ...
Stijn Van Antwerpen's user avatar
2 votes
0 answers
115 views

Large querystring compression [duplicate]

Possible Duplicate: How to compress/decompress a long query string in PHP? I have a huge amount of data inside my subquerystring for tracking needs. I loose a lot of my data because of this too ...
Dark's user avatar
  • 505
2 votes
1 answer
1k views

Using Query String Parameter to Select Column in asp.net

I am trying to use asp:QueryStringParameter to change witch SQL table column I want to get. But when I try, I just get the Query String Parameter as every row of a new column. Here is what I have so ...
Z Allen's user avatar
  • 21
2 votes
0 answers
541 views

mvc 2 passing a parameter as a QueryString

If I have for example a controller home with a ActionResult videoInfo Home/VideoInfo that pop up a form where put id and after clicking button getinfo it will redirect me to a page where info about a ...
studentsss's user avatar
1 vote
2 answers
7k views

How do I get the QueryString values into a the RouteValueDictionary using Html.BeginForm()?

I've found that Html.BeginForm() automatically populates the routeValueDictionary with the RawUrl (ie. QueryStringParamters). However I need to specify an HtmlAttribute so I need to use the override.....
Justin's user avatar
  • 10.8k

1
2 3 4 5