Print

Print


Aha.  Apparently it doesn't have to go before the DOCTYPE.  I just tested it and it works just fine if the PI follows the DOCTYPE.  (At least it works with my Android emulator.)  Yay!

Michele

-----Original Message-----
From: Michele R Combs 
Sent: Tuesday, September 06, 2011 10:00 AM
To: 'Encoded Archival Description List'
Subject: RE: output prior to DOCTYPE

Hey Mark --

Can't remember if I answered this, but what we wanted there was a php snippet to check browser type and redirect mobile users to the mobile version of our finding aids.  It looks like this:

<?php include($_SERVER['DOCUMENT_ROOT']."/lib/findingaid_mobile.php"); ?>

Now that I look at it, maybe it IS a processing instruction, contrary to my last post.  Have to go back and try it again...

Michele

-----Original Message-----
From: Encoded Archival Description List [mailto:[log in to unmask]] On Behalf Of Mark A. Matienzo
Sent: Friday, September 02, 2011 4:23 PM
To: [log in to unmask]
Subject: Re: output prior to DOCTYPE

What do you need to insert before the DOCTYPE declaration? In general, putting content before the declaration is bad practice as it tends to throw Internet Explorer into "quirks mode", leading to often unpredictable results (see [0] for more information).



[0] http://stackoverflow.com/questions/941100/can-html-comments-appear-before-the-doctype-declaration

Mark A. Matienzo
Digital Archivist, Manuscripts and Archives, Yale University Library Technical Architect, ArchivesSpace

On Fri, Sep 2, 2011 at 3:24 PM, Michele R Combs <[log in to unmask]> wrote:
> Anybody know a way to get something to output before the <!DOCTYPE when using an XSL style sheet to go from EAD to HTML?  That is:
>
> need some stuff here
> <!DOCTYPE html  PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" 
> "http://www.w3.org/TR/1998/REC-html40-19980424/loose.dtd">
> <html>
>   <body>
>   ...
>   </body>
> </html>
>
> Thanks --
>
> Michele
>
> +++++++++++++++
> Michele Combs.
> Librarian for Manuscripts and Archives Processing.
> Special Collections Research Center.
> Syracuse University.
> 315-443-2081.
> [log in to unmask]
>