Powiel możliwe:
How can I get query string values?jquery get ciągu kwerendy z URL
Mam następujący adres URL:
http://www.mysite.co.uk/?location=mylocation1
Co potrzebne jest, aby uzyskać wartość location
z adres URL do zmiennej, a następnie użyj go w kodzie jQuery:
var thequerystring = "getthequerystringhere"
$('html,body').animate({scrollTop: $("div#" + thequerystring).offset().top}, 500);
Czy ktoś wie, jak pobrać tę wartość za pomocą JavaScript lub jQuery?
Może pomóc some1. https://gist.github.com/helpse/4d4842c69782b9f94a72 – helpse