Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre > Editor

Notices

Reply
 
Thread Tools Search this Thread
Old 10-13-2022, 02:12 AM   #1
trosoft
Junior Member
trosoft began at the beginning.
 
Posts: 1
Karma: 10
Join Date: Oct 2022
Device: None
EPUB Validation errors: Improper placement of link and vlink attributes: EPUB Checker

EPUB version 3
Calibre version 6

How can I correct errors relating to improper placement of link and vlink attributes in EPUB’s CSS?

Calibre automatically generated the CSS for each of the linked sections of the EPUB file, i.e., xxx_split_xxx.htm. (These related to the H1 and H2 elements for the table of contents.)

The Pagina EPUB Checker shows two errors for each of the xxx_split_xxx.htm files relating to the headings and subheadings for the EPUB file’s headings and subheadings.

The results is 70 errors, i.e., two for each of the 35 HTM files.

Each error states that either the “link” or the “vlink” attribute is not allowed at its location in the CSS.

^^^^^^^^^^^^^^^^^^^^^^

"**Error while parsing the attribute "link" not allowed here**", …
"**Error while parsing the attribute "vlink"not allowed here**", …


(But, the links for the table of contents function properly)
__________________________________

Below is copy of a section of the CSS, wherein the offending line contains two errors, re: improper placement of 'link' and 'vlink' attributes.
Once again, this same section is repeated in each of the HTM files relating to the EPUB file’s headings and subheadings See the attachment, which is a partial screenshot of the results from Pagina's EPUB Checker, re: validation errors.

^^^^^^^^^^^^^^^^^^^^^^

At the beginning of 'body' section it reads, lang="EN-US" link="blue" vlink="purple" class="calibre"

[This ERROR concerns the incorrect placement of 'link' and 'vlink' attributes that the EPUB validation tool complains about; these two errors are repeated in each HTM file.]

^^^^^^^^^^^^^^^^^^^^^^

Above, the style in the last line appears in each of the 35 HTM files relating to the headings and subheadings of the table of contents.

There is a separate error for each of the “link” and “vlink” settings.

(The table of contents links work properly.)
Attached Thumbnails
Click image for larger version

Name:	Calibre __CSS Errors.png
Views:	98
Size:	106.3 KB
ID:	197127  
trosoft is offline   Reply With Quote
Old 10-13-2022, 09:58 AM   #2
enuddleyarbl
Guru
enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.
 
enuddleyarbl's Avatar
 
Posts: 734
Karma: 1077122
Join Date: Sep 2013
Device: Kobo Forma
I've set up a Saved Search in the Calibre Editor to clear out my <body> tag:

Search:
Code:
<body.+?>
Replace:
Code:
<body>
That's one of the first things I do when I start editing a book. I don't know if that's the kind of thing you want to do, though.
enuddleyarbl is offline   Reply With Quote
Advert
Old 10-13-2022, 11:10 AM   #3
theducks
Well trained by Cats
theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.
 
theducks's Avatar
 
Posts: 29,809
Karma: 54830978
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
because this is another case where the checker complains falsely and the idjuts that solely rely on that to filter submissions are even wronger

As you noticed, the links work. besides AFAIK all vlink, link do is COLOR the text based upon status of usage
theducks is offline   Reply With Quote
Old 10-13-2022, 01:53 PM   #4
enuddleyarbl
Guru
enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.
 
enuddleyarbl's Avatar
 
Posts: 734
Karma: 1077122
Join Date: Sep 2013
Device: Kobo Forma
Quote:
Originally Posted by theducks View Post
because this is another case where the checker complains falsely and the idjuts that solely rely on that to filter submissions are even wronger

As you noticed, the links work. besides AFAIK all vlink, link do is COLOR the text based upon status of usage
I don't know why, but according to:
https://developer.mozilla.org/en-US/...L/Element/body
the text entries for link and vlink say:
Quote:
Do not use this attribute! Use the CSS color property in conjunction with the :link (or :visited (my note)) pseudo-class instead.
I've combined those.

So, assuming that page knows what it's talking about, it looks like the checker is correct (or maybe correct-ish).
enuddleyarbl is offline   Reply With Quote
Old 10-13-2022, 05:47 PM   #5
enuddleyarbl
Guru
enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.
 
enuddleyarbl's Avatar
 
Posts: 734
Karma: 1077122
Join Date: Sep 2013
Device: Kobo Forma
Looking a bit more at all the "do not use this attribute" messages on that mozilla page, it looks like they're basically saying if it can be done in css, do it there instead of in the <body> tag. And that's pretty much why I clear the <body> tag on all the books I mess with. Of course, all I usually see there is an id= tag (I don't really understand the point of that) and a calibre tag of some sort (where, I think, it's trying to reproduce what the publisher was trying to do globally).
enuddleyarbl is offline   Reply With Quote
Advert
Reply

Tags
calibre, css, epub, html, validation


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
'Attribute (v)link' errors after EPUB validation Marjelle Sigil 21 05-22-2015 12:35 PM
Epub Validation Errors adrienna ePub 7 11-22-2013 10:11 PM
Validation Error from ePub Checker sgirsberger ePub 6 01-17-2012 05:20 PM
epub validation checker bobcdy ePub 0 06-03-2011 05:31 PM


All times are GMT -4. The time now is 01:43 AM.


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