Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can not retrieve a url using curl

Tags:

curl

While trying to retrieve the URL http://www.kat.ph/search/snow-patrol-shut-your-eyes/?categories%5B%5D=music using curl I am getting an error which says

curl: (3) [globbing] illegal character in range specification at pos 65

Why is that so ? while [ seems to be a perfectly valid character in the browser address bar ,how can i retrieve the same url in curl ?

like image 303
Bunny Rabbit Avatar asked Dec 12 '22 12:12

Bunny Rabbit


1 Answers

You can use the -g option to stop curl from globbing itself. It will then pass the URL with [] to the server as-is.

like image 146
Dan Avatar answered Feb 04 '23 19:02

Dan