Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Sigil

Notices

Reply
 
Thread Tools Search this Thread
Old 12-27-2010, 11:29 AM   #1
arreke
Junior Member
arreke began at the beginning.
 
Posts: 2
Karma: 10
Join Date: Dec 2010
Device: SONY PRS 650
HTML Anchor in XHTML

When I convert my HTML books into EPUB, HTML likns in the books do not work...

for example, if HTML file have the named fragment:
<a name="bottom" id="bottom">the bottom of the page</a>
and link to this:
<a href="#bottom">link to the bottom of the page</a>

how to make it in XHTML to show correctly in EPUB ?
arreke is offline   Reply With Quote
Old 12-27-2010, 11:54 AM   #2
cuthbert19
Enthusiast
cuthbert19 once ate a cherry pie in a record 7 seconds.cuthbert19 once ate a cherry pie in a record 7 seconds.cuthbert19 once ate a cherry pie in a record 7 seconds.cuthbert19 once ate a cherry pie in a record 7 seconds.cuthbert19 once ate a cherry pie in a record 7 seconds.cuthbert19 once ate a cherry pie in a record 7 seconds.cuthbert19 once ate a cherry pie in a record 7 seconds.cuthbert19 once ate a cherry pie in a record 7 seconds.cuthbert19 once ate a cherry pie in a record 7 seconds.cuthbert19 once ate a cherry pie in a record 7 seconds.cuthbert19 once ate a cherry pie in a record 7 seconds.
 
Posts: 48
Karma: 1916
Join Date: Sep 2010
Device: Cybook Opus
Try using the complete url while referencing, i.e. :

Quote:
<a href="../Text/thisfilename.xhtml#bottom">link to the bottom of the page</a>
cuthbert19 is offline   Reply With Quote
Old 12-27-2010, 12:54 PM   #3
Jellby
frumious Bandersnatch
Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.
 
Jellby's Avatar
 
Posts: 7,516
Karma: 18512745
Join Date: Jan 2008
Location: Spaniard in Sweden
Device: Cybook Orizon, Kobo Aura
You don't need an <a> element to use the "id" attribute (in XHTML "name" is not allowed), but you can add it to any other element. Like this:

Code:
<p>This is a <a href="#bottom">link to the bottom</a> of the page.</p>
...
<p id="bottom">And this is the bottom of the page.</p>
If both "id" and "href" end up in the same file after splitting (if necessary), you don't need the full URL; otherwise, as cuthbert19 says, you'd need to write the relative path from one file to the other.
Jellby is offline   Reply With Quote
Old 12-27-2010, 01:28 PM   #4
arreke
Junior Member
arreke began at the beginning.
 
Posts: 2
Karma: 10
Join Date: Dec 2010
Device: SONY PRS 650
2 Jellby & cuthbert19,

thank you, it works now...
arreke is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Variable position / anchor for images? jharker ePub 1 08-31-2010 04:40 AM
Several xhtml/html to a single epub file help. clowe1028 ePub 3 03-21-2010 03:47 AM
Jetbook HTML (XHTML) rogue_ronin Ectaco jetBook 19 02-12-2010 09:13 PM
xml or xhtml to basic html converter remjax Reading and Management 11 07-14-2009 09:04 AM
Kindle 1.2 update makes boat anchor scotty1024 Amazon Kindle 17 03-17-2009 11:34 PM


All times are GMT -4. The time now is 09:08 AM.


MobileRead.com is a privately owned, operated and funded community.