[Archivesspace_Users_Group] 2 Bug fixes for as-ead-pdf.xsl - Staff interface PDF generation

Neal Fitzgerald nfitzgerald at slv.vic.gov.au
Tue Jun 15 21:02:57 EDT 2021


One of our large collections has an archival object with an Index and items in the note section. This was causing the PDF generation to fail with a fatal error in the log:

ValidationException: Missing attribute on fo:basic-link: Either external-destination or internal-destination must be specified.

as the EAD XML contains <ref> elements which do not have an @target attribute

I changed line 1106 in the linking section:
   <!-- Linking elmenets -->
    <xsl:template match="ead:ref">
to
   <xsl:template match="ead:ref[@target]">

to match only those ref tags with and @target attribute and this solved the problem.

This same collection had a number of digital objects with unpublished File URIs that had whitespace before and after the URI, probably from a copy and paste error or perhaps as an artifact of an import process.

When the staff PDF generation was run with the 'include unpublished' box ticked the process failed with an "illegal character" message listing the first offending URI

I solved this by adding a normalize-space function to the XSLT wherever I found:
<fo:basic-link external-destination="url('{@*:href}')"
ie to
<fo:basic-link external-destination="url('{normalize-space(@*:href)}')"

Cheers





Neal Fitzgerald | Senior Specialist, Library Systems & Digital Preservation | Collection Development & Description
State Library Victoria | 328 Swanston Street | Melbourne VIC 3000
T +61 3 8664 7103 | nfitzgerald at slv.vic.gov.au
slv.vic.gov.au<http://slv.vic.gov.au>

  [slv]

[https://www.slv.vic.gov.au/sites/default/files/email_signature/signature.jpg?9]<https://www.slv.vic.gov.au/email_campaign>
[follow us]
[SLV facebook]<http://www.facebook.com/pages/Melbourne-Australia/State-Library-of-Victoria/32256104331> [SLV twitter] <http://twitter.com/Library_Vic>  [SLV youtube] <http://www.youtube.com/user/statelibraryvictoria>        [SLV instagram] <http://instagram.com/library_vic>      [Gold Winner 2018 RACV Victorian Tourism Awards]                [MEA Awards 2018 National Winner]




This message and any attachment is intended only for the use of the Addressee and may contain information that is PRIVILEGED and CONFIDENTIAL. If you are not the intended recipient, you are hereby notified that any dissemination of this communication is strictly prohibited. If you have received this communication in error, please delete all copies of the message and its attachments and notify the sender immediately. Thank you.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lyralists.lyrasis.org/pipermail/archivesspace_users_group/attachments/20210616/7225a96c/attachment.html>


More information about the Archivesspace_Users_Group mailing list