Is there a method or recommended way of grabbing URL hash parameters with Twig?
For example, if my URL is http://mysite.com/my-page#hash, is there a way to grab the hash?
This isn't possible because the #hash-part isn't even send to the server. See this question on StackOverflow: Can PHP read the hash portion of the URL?
But if you use ?hash=something instead, these functions will help you: getParam() and getQuery()
Sign up using Google
Sign up using Facebook
Sign up using Stack Exchange
10 months ago
Get the weekly newsletter!
see an example newsletter