Let me preface this by saying I am working on a public facing site that is on SharePoint, we are trying to support multiple browser types with the content. So I've been asked by our Content Team to check on how SharePoint 2010 is dealing with Anchor Tags, now I did some checking around and there are some steps on how to generate them within the same page. Of course this was after discovering how they are basically unsupported and have been since MOSS 2007, this is for general content not wiki pages. On the MSDN forums this has come up a couple of times and I've followed those steps, and I have gotten them to work fine in the same page and wrote instructions for our team; although it would be nicer if these were not so convoluted. Although then the question came, can we do this for other pages? Answer was, not so fast. I did some checking and found the following behavior.
- IE 8 - goes to the Anchor Tag on the new page, then jumps to the top. From my understanding this is due to the ribbon bar or something on the page that overrides focus
- IE 7 - works great! This surprised me
- IE 6 - works great! This also surprised me, but I expect lots of errors whenever I access pages
- FireFox 3.5 - page loads and never generates a focus anywhere...not even the jump you get from IE 8
Has anyone done this, without adding code into the page, to get Anchor Tags to work across pages or am I stuck trying to code a solution or just telling the content team not to do this? Or my third alternative to them was to make a set of links at the top of the page, so Users will always see a set of anchor links in the top of the page no matter where they come from.
EDIT: One solution I have come up with, that seems to work most of the time, is using the DIV tage on certain sections of pages and using the ID to make an anchor tag so on one page I can enter
<div id="shortcut"> </div>
Then make a page link as - default.aspx#shortcut - and that seems to work much of time at least in IE9. enter code here