View Single Post
Old 01-05-2012, 09:06 AM   #4
Snorkledorf
Blue. Not sad...just blue
Snorkledorf ought to be getting tired of karma fortunes by now.Snorkledorf ought to be getting tired of karma fortunes by now.Snorkledorf ought to be getting tired of karma fortunes by now.Snorkledorf ought to be getting tired of karma fortunes by now.Snorkledorf ought to be getting tired of karma fortunes by now.Snorkledorf ought to be getting tired of karma fortunes by now.Snorkledorf ought to be getting tired of karma fortunes by now.Snorkledorf ought to be getting tired of karma fortunes by now.Snorkledorf ought to be getting tired of karma fortunes by now.Snorkledorf ought to be getting tired of karma fortunes by now.Snorkledorf ought to be getting tired of karma fortunes by now.
 
Snorkledorf's Avatar
 
Posts: 218
Karma: 1267018
Join Date: Oct 2009
Location: Japan
Device: Ridibooks Paper Pro
Okay it looks like embedding the anchor into the header is the way to go for cross-platform compatibility. Putting the link before the header makes the Sony display the previous section. Putting the link after the header makes the Kindle fail to display the header text.

I think I've got it now. Thanks for the help!


Here's my test Markdown code, for anybody who wants to see it for themselves:

Spoiler:
# Anchor-placement tests for Kindle & Sony Reader

 

### Anchor precedes target header
> [Type 1](#type1) (Sony FAIL) (Kindle WIN)

 

### Anchor follows target header
> [Type 2](#type2) (Sony WIN) (Kindle FAIL)

 

### Anchor embedded in target header
> [Type 3](#type3) (Sony WIN) (Kindle WIN)

 

### HTML ID embedded in target header
> [Type 4](#type4) (Sony WIN) (Kindle WIN)


# Type 1 Fail!

You shouldn't see this...

<a name="type1"></a>

# Type 1 Success!

This is the correct text...can you see the header too?






# Type 2 Fail!

You shouldn't see this...

# Type 2 Success!

<a name="type2"></a>

This is the correct text...can you see the header too?






# Type 3 Fail!

You shouldn't see this...

# <a name="type3"></a>Type 3 Success!

This is the correct text...can you see the header too?




# Type 4 Fail!

You shouldn't see this...

<h1 id="type4">Type 4 Success!</h1>

This is the correct text...can you see the header too?
Snorkledorf is offline   Reply With Quote