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 Best Answertring:

http://example.com?sent=yes

I just want to detect:

  1. Does sent exist?
  2. Is it equal to “yes”?

34 s
34

Leave a Comment