0

There are an option -d to append data as parameters at URL of GET, so I'm imagining that exists also an option to add the URL fragment (# "URL hash").

PS: no clues by curl --help | grep -i frag.

1 Answer 1

3

Nope. Fragments are ignored by the server - they are for the browser only.

When you look for "http://somesite.com/1?myvar=4#myresource" - the server can see the somesite.com, the "1" (path variable), the myvar (query string), any posted data but sadly not the fragment. When the client (browser) gets the server result back, it applies the fragment then client side to "flick" to the bookmark or for javascript to make a request.

Getting hash parameters from request url

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.