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=ye
Try this working demo http://jsfiddle.net/xy7cX/
API:
inArray
This should help :)
:)
code
var url = "http://myurl.com?sent=yes" var pieces = url.split("?"); alert(pieces[1] + " ===== " + $.inArray("sent=yes", pieces));