You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@forrest.apache.org by Victor Okunev <ve...@gmail.com> on 2006/04/05 11:12:38 UTC

local copy of document-v20.mod

Is it possible to have a modified version of document-v20.mod for a
particular project? Where would I place it? I tried placing it in
<PROJECT-HOME>\src\documentation\resources\schema\dtd but it did not
work.

Basically all I need is to add the "onclick" attribute to hyperlinks:

<!-- ==================================================== -->
<!-- Hypertextual Links -->
<!-- ==================================================== -->
<!-- hyperlink (equivalent of <a ...>) -->
<!-- http://www.w3.org/TR/xhtml2/mod-hypertext.html#s_hypertextmodule -->
<!ELEMENT a (%link-content.mix;)*>
<!ATTLIST a
 onclick CDATA #IMPLIED
 %common.att;
 %link.att;
>

Re: local copy of document-v20.mod

Posted by David Crossley <cr...@apache.org>.
Victor Okunev wrote:
> Is it possible to have a modified version of document-v20.mod for a
> particular project? Where would I place it? I tried placing it in
> <PROJECT-HOME>\src\documentation\resources\schema\dtd but it did not
> work.

You can hack the main one at
$FORREST_HOME/main/webapp/resources/schema/dtd

Alternatively make a copy and give it your own
PublicIdentifier (see below).

You probably need a driver file as well
(document-v20-victor.dtd) which references
document-v20-victor.mod using its PublicIdentifier. 

The copied document-v20-victor.* would go in your
project at <PROJECT-HOME>\src\documentation\resources\schema
and make a catalog.xcat file to declare your new resources.

There is an example catalog.xcat in a 'forrest seed' site.

The entries in your project catalog.xcat would be
like this:
...
<public publicId="-//Victor Okunev//DTD Documentation V2.0//EN"
        uri="document-v20-victor.dtd"/>
<public publicId="-//Victor Okunev//ENTITIES Documentation V2.0//EN"
        uri="document-v20-victor.mod"/>
...

Use that DTD PublicIdentifier at the top of your
XML instances.

Good luck, it is a minefield. The main thing to
bear in mind is that with Forrest's Catalog Entity
Resolver it is the PublicIdentifiers that drive
everything.

-David

> Basically all I need is to add the "onclick" attribute to hyperlinks:
> 
> <!-- ==================================================== -->
> <!-- Hypertextual Links -->
> <!-- ==================================================== -->
> <!-- hyperlink (equivalent of <a ...>) -->
> <!-- http://www.w3.org/TR/xhtml2/mod-hypertext.html#s_hypertextmodule -->
> <!ELEMENT a (%link-content.mix;)*>
> <!ATTLIST a
>  onclick CDATA #IMPLIED
>  %common.att;
>  %link.att;
> >