Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Formats > Workshop

Notices

Reply
 
Thread Tools Search this Thread
Old 01-27-2012, 01:54 PM   #1
BKh
Connoisseur
BKh can extract oil from cheeseBKh can extract oil from cheeseBKh can extract oil from cheeseBKh can extract oil from cheeseBKh can extract oil from cheeseBKh can extract oil from cheeseBKh can extract oil from cheeseBKh can extract oil from cheese
 
Posts: 50
Karma: 1000
Join Date: Mar 2011
Device: Kindle
Anchors look like links in ADE?

When I view an epub (that I created using Sigil) in ADE, anchor text appears blue with an underline and hovering over it gives a pointer as if it were a link. Of course clicking on it does nothing. Here is an example of the code:

Quote:
<h1><a id="a0.26BrahmanaVagga"><small>26.</small></a> Brāhmaṇa Vagga<br />
<span class="EngTitle">The Saint<a class="sdendnoteanc" href="../Text/Section0001_0032.xhtml#sdendnote153sym" id="sdendnote153anc"><sup>153</sup></a></span></h1>
It's the 26. in the <small> tags that is appearing like it is a link. Are you not allowed to use <a> tags like that in e-pubs? I realize it may be better to put the id inside of the h or p tags, but I didn't think that was required.
BKh is offline   Reply With Quote
Old 01-27-2012, 04:00 PM   #2
Toxaris
Wizard
Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.
 
Toxaris's Avatar
 
Posts: 3,182
Karma: 7180223
Join Date: Oct 2009
Location: Heemskerk, NL
Device: PRS-300, PRS-T1
Actually, why would you make the 26 an anchor? If you don't want to have it blue and underlined, switch it off in the CSS.
Toxaris is offline   Reply With Quote
Old 01-27-2012, 04:03 PM   #3
DSpider
Evangelist
DSpider ought to be getting tired of karma fortunes by now.DSpider ought to be getting tired of karma fortunes by now.DSpider ought to be getting tired of karma fortunes by now.DSpider ought to be getting tired of karma fortunes by now.DSpider ought to be getting tired of karma fortunes by now.DSpider ought to be getting tired of karma fortunes by now.DSpider ought to be getting tired of karma fortunes by now.DSpider ought to be getting tired of karma fortunes by now.DSpider ought to be getting tired of karma fortunes by now.DSpider ought to be getting tired of karma fortunes by now.DSpider ought to be getting tired of karma fortunes by now.
 
DSpider's Avatar
 
Posts: 427
Karma: 326969
Join Date: Nov 2009
Location: Romania
Device: PW2 2014
"<a href= ..." looks like a link to me...


Edit: Oh, just the "26." part.

Last edited by DSpider; 01-27-2012 at 04:07 PM.
DSpider is offline   Reply With Quote
Old 01-27-2012, 05:06 PM   #4
BKh
Connoisseur
BKh can extract oil from cheeseBKh can extract oil from cheeseBKh can extract oil from cheeseBKh can extract oil from cheeseBKh can extract oil from cheeseBKh can extract oil from cheeseBKh can extract oil from cheeseBKh can extract oil from cheese
 
Posts: 50
Karma: 1000
Join Date: Mar 2011
Device: Kindle
Quote:
Originally Posted by Toxaris View Post
Actually, why would you make the 26 an anchor? If you don't want to have it blue and underlined, switch it off in the CSS.
Well, it's just an example. There are other places where I have set up text as anchors using the a tag as well. It just seems odd that it would display an anchor like it was a link.

Would I do the css using psudo classes?
http://www.w3schools.com/css/css_pseudo_classes.asp

If so, I thought pseudo classes were not a good idea for e-books. Also, there doesn't seem to be a pseudo class for just the anchor (I'm assuming because usually there is no reason to style an anchor, which is why this whole thing is so puzzling to me)

BTW, I plan on using Calibre to generate a .mobi file. Having done this already, I never see any underlines when I view the anchors on the Kindle.
BKh is offline   Reply With Quote
Old 01-27-2012, 06:39 PM   #5
Toxaris
Wizard
Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.
 
Toxaris's Avatar
 
Posts: 3,182
Karma: 7180223
Join Date: Oct 2009
Location: Heemskerk, NL
Device: PRS-300, PRS-T1
Pseudo classes are not in the specs, so support is a hit and miss, so that is definitely not a good idea. Unfortunately that is your only option I think.

Anchors are links in essence, but in your case a link to nothing

That the anchor is without underlines on the Kindle does not mean anything. The format is totally different, so also the interpretation of links.
Toxaris is offline   Reply With Quote
Old 01-28-2012, 04:53 AM   #6
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: 6,309
Karma: 4898871
Join Date: Jan 2008
Location: Spaniard in Sweden
Device: Cybook Orizon, Kobo Aura
Using <a> for anchors is usually, unneeded. You can add the "id" anywhere, like this:

Code:
<h1><small id="a0.26BrahmanaVagga">26.</small> Brāhmaṇa Vagga<br />
or this:

Code:
<h1 id="a0.26BrahmanaVagga"><small>26.</small> Brāhmaṇa Vagga<br />
Jellby is online now   Reply With Quote
Old 01-28-2012, 04:00 PM   #7
BKh
Connoisseur
BKh can extract oil from cheeseBKh can extract oil from cheeseBKh can extract oil from cheeseBKh can extract oil from cheeseBKh can extract oil from cheeseBKh can extract oil from cheeseBKh can extract oil from cheeseBKh can extract oil from cheese
 
Posts: 50
Karma: 1000
Join Date: Mar 2011
Device: Kindle
Quote:
Originally Posted by Jellby View Post
Using <a> for anchors is usually, unneeded. You can add the "id" anywhere, like this...
Yes, I should have been clear that I don't want to use <a> tags, but have in fact already used them in several books. What I want to do is fix the problem without having to go back and change them all.

Thanks everyone for the information.
BKh is offline   Reply With Quote
Old 01-28-2012, 05:28 PM   #8
BKh
Connoisseur
BKh can extract oil from cheeseBKh can extract oil from cheeseBKh can extract oil from cheeseBKh can extract oil from cheeseBKh can extract oil from cheeseBKh can extract oil from cheeseBKh can extract oil from cheeseBKh can extract oil from cheese
 
Posts: 50
Karma: 1000
Join Date: Mar 2011
Device: Kindle
Actually, I do have another question. Could I replace the <a id="xxx"> with <span id="xx"> and not cause any problems? There would also be some cases of empty tags, like <span id="xxx"></span>

One book has over 1,000 of these <a> anchors.
BKh is offline   Reply With Quote
Old 01-29-2012, 04:19 PM   #9
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: 6,309
Karma: 4898871
Join Date: Jan 2008
Location: Spaniard in Sweden
Device: Cybook Orizon, Kobo Aura
Yes, it should be fine.

You could also try with:

a { text-decoration: none; color: inherit; }

and then, if you want actual links to be underlined:

a[href] { text-decoration: underline; }

I'm not sure the'll work as intended in ADE, though.
Jellby is online now   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Anchors in posts? unboggling Feedback 14 11-12-2014 03:44 PM
Indexing links in ADE soparch ePub 6 10-14-2011 12:25 PM
Help Please ADE Kiwimick Sony Reader 2 11-14-2010 07:24 PM
Links to URLs work, internal links don't? NewDay ePub 36 10-27-2010 05:09 AM
Kindle - html to Kindle format - do links to anchors work? Rasczak Kindle Formats 20 12-08-2008 04:20 PM


All times are GMT -4. The time now is 03:57 PM.


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