Forum Moderators: open

Message Too Old, No Replies

Jumps in email don't jump to anchor in IE7/8

Annoying bug in IE7/8... workaround?

         

dilettante

10:29 pm on Jan 8, 2010 (gmt 0)

10+ Year Member



Hello,

I have been battling a very annoying bug my employer discovered and is expecting a "fix" for.

We send out a newsletter via email, where the "click here for more" links direct to one large and complete newsletter with each story marked with an anchor.

Assuming that the original message and original newsletter were bloated/coded badly either through Dreamweaver/Outlook or both, I decided to conduct a test with a very basic page and a plain text message.

The URL is at:
http://www.example.org/test/jumptest.html

The URLs I sent to myself via email are:
http://www.example.org/test/jumptest.html#jump3
http://www.example.org/test/jumptest.html#jump4
http://www.example.org/test/jumptest.html#jump1
http://www.example.org/test/jumptest.html#jump2
http://www.example.org/test/jumptest.html#jump5

jump1 consistently works. The others work once in a while, but I can click on jump2 and it will work, click it again right away and it jumps to the bottom.

Apologies if this issue has been addressed before, and I'll appreciate any insight anyone can send my way!

Best regards,
Jay

[edited by: tedster at 10:34 pm (utc) on Jan. 8, 2010]
[edit reason] use example.org - no personal urls, please [/edit]

dilettante

10:34 pm on Jan 8, 2010 (gmt 0)

10+ Year Member



Oh, I should add that when I tested this behavior in IE8, I did get the correct jumps *more* consistently, but still had occasional misfires.

Thank you,
Jay

rocknbil

3:05 am on Jan 9, 2010 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Welcome aboard dilettante, every instance I've seen of anchors acting up usually leads to duplicate fragment identifiers on the same page. ID's are meant to be unique, often they are used repetitively. In any case, the problem is likely in the destination page, so what does a condensed version of the code look like?

Old school methods used "name" in conjunction with an empty anchor,

<a name="jump1"></a>

But it doesn't have to be an anchor, and name is deprecated (for non-form elements.) It can be any unique element.

<h1 id="jump1">Jump 1</h1>

There can only be one id="jump1" on any given page. Having two (or more) with the same ID on the same page is often seen "in the wild."