Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What's the term for the part of the URL after the question mark?

http://www.example.com?foo

What's the term for the foo part of the URL?

like image 904
Emanuil Rusev Avatar asked Oct 24 '10 09:10

Emanuil Rusev


People also ask

What is after question mark in URL?

Its name is query string. After the question mark you can pass key-value pairs and use them server-side.

Can URL have question marks?

Yes, it is valid.

What is a query string in a URL?

A query string is the portion of a URL where data is passed to a web application and/or back-end database. The reason we need query strings is that the HTTP protocol is stateless by design. For a website to be anything more than a brochure, you need to maintain state (store data).


1 Answers

It's the query, or sometimes the query string.

To pinch a useful diagram from the URI RFC:

     foo://example.com:8042/over/there?name=ferret#nose      \_/   \______________/\_________/ \_________/ \__/       |           |            |            |        |    scheme     authority       path        query   fragment 
like image 185
Justin Avatar answered Sep 24 '22 00:09

Justin