How can I accept a hash mark in a URL via $_GET?
Posted
by bccarlso
on Stack Overflow
See other posts from Stack Overflow
or by bccarlso
Published on 2010-06-01T23:20:08Z
Indexed on
2010/06/01
23:23 UTC
Read the original article
Hit count: 320
From what I have been able to understand, hash marks (#) aren't sent to the server, so it doesn't seem likely that I will be able to use raw PHP to parse data like in the URL below:
index.php?name=Ben&address=101 S 10th St Suite #301
I'm looking to pre-populate form fields with this $_GET data. How would I do this with Javascript (or jQuery), and is there a fallback that wouldn't break my form for people not using Javascript? Currently if there is a hash (usually in the address field), everything after that is not parsed in or stored in $_GET.
© Stack Overflow or respective owner