Not Logged In Log In   Sign Up   Points Leaders
Follow Us    2:29 AM

Message Forum - Read Message

Category: Suggest a GasBuddy improvement > Topics Add to favorite topics   Post new topicPost New Topic
Author Topic: Put a 'Named Anchor' on all Map Gas Prices pages Back to Topics
movrshakr

Champion Author
Florida

Posts:1,424
Points:1,956,870
Joined:Jan 2008
Message Posted: Feb 3, 2011 1:58:50 PM

Suggest you put a named anchor on all MGP pages at the top of the map graphic.

This will allow us to create a url (say for a bookmark) that will open the map page and jump it down to display the map graphic with its top border at the top of the browser window.

Example: http://....url.../#maptop
[or]
http://....url.../#c1

or whatever name you choose for the named anchor.
REPLIES (newest first) Topic is locked
Profile Pic
CampKohler
Champion Author Sacramento

Posts:12,767
Points:2,031,345
Joined:May 2007
Message Posted: Aug 20, 2014 3:06:35 AM

A dear old friend has risen from the dead. Hallelujah!
Profile Pic
Gas_Buddy
Champion Author Maryland

Posts:29,672
Points:3,609,100
Joined:Aug 2004
Message Posted: Aug 19, 2014 11:30:14 PM

The first and second response to the original post was nearly two years after the topic was started. The third post, the most recent one, reactivated the topic after almost a year and a half. Better a new topic was started than resurrecting the dead, per the site's guidance about bumping old topics.
Profile Pic
LarryMarg
Champion Author New York

Posts:2,392
Points:564,600
Joined:Feb 2012
Message Posted: Aug 19, 2014 6:09:07 PM

After a month and a half of extensive research (which is pretty impressive, considering that we haven't had the new maps that long), I've determined that appending #map_canvas to the URL is how to do the equivalent with the new Google-driven Map Gas Prices page.
Profile Pic
movrshakr
Champion Author Florida

Posts:1,424
Points:1,956,870
Joined:Jan 2008
Message Posted: Dec 16, 2012 6:56:41 PM

.
To make that completely clear, adding

#ctl00_Content_MGP_pnlUSA

to the END of any url you are using to access an MGP page will put the map at the top of the loaded screen.

Major thanks to CampKohler for analyzing how to do this.

[Edited by: movrshakr at 12/16/2012 6:59:30 PM EST]
Profile Pic
CampKohler
Champion Author Sacramento

Posts:12,767
Points:2,031,345
Joined:May 2007
Message Posted: Dec 15, 2012 11:44:54 PM

After a year and a half of extensive research (or maybe a little less), there is a solution to displaying the map at the top of the viewport. There is a div tag just above the map on the page and it has an id parameter of "ctl00_Content_MGP_pnlUSA". This can be used as a fragment link in the same manner as an anchor tag.

For example, let's say you just got out and need to drain that 20-year-old premium from your tank and replace it with fresh stock from a nearby station. http://sactogasprices.com/Map_Gas_Prices.aspx?z=9&lat=38.686981&long=-121.167542&ft=C&tl=All#ctl00_Content_MGP_pnlUSA will do the trick.
Topic is locked Back to Topics