I have been stuck on this for way longer than I care to admit.
What I am trying to accomplish:
I would like to capture the current users location as soon as the open any page on my drupal website (the only way I have found on how to do this uses a Javascript function). Once I have the users location saved as a variable in my .js file, I would like to send the location variable to the server side of my application and set it as a session variable or something so that I have access to it globally.