Tahia wrote:
> 
> > > About convert element:
> > >
> > > We can select a text and converted to <b> for exemple.
> > > <b> is an element without parameter.
> > > I realised that we can not convert text to an element within attributes.
> > >
> > > See the exemple of xhtml:
> > >
> > > --<command name="xhtml.convertToLink">
> > >     <macro>
> > >       <sequence>
> > >         <command name="convert" parameter="a" />
> > >         <command name="putAttribute" parameter="%*" />
> > >       </sequence>
> > >     </macro>
> > > ---</command>
> > >
> > > it uses a method "xhtml.convertToLink". It works well.
> > >
> > > How could I convert a text to an element within attributes ?
> > > I tried:
> > >
> > > --<command name="myConvertToLink">
> > >     <macro>
> > >       <sequence>
> > >         <command name="convert" parameter="a" />
> > >         <command name="putAttribute" parameter="%*" />
> > >       </sequence>
> > >     </macro>
> > > ---</command>
> > >
> > > --- <button toolTip="Convert to link" icon="../icons2/link_menu.gif">
> > >       <menu>
> > >         <item label="a[externe link]" command="myConvertToLink"
> > >               parameter="href http://XXX.YYY"; />
> > >         <item label="a[interne link]" command="myConvertToLink"
> > >               parameter="href urn:XXX:YYY" />
> > >       </menu>
> > > ---</button>
> > >
> > > my element <a> is not the same as the one declared with XHTML!!
> > >
> > > It does not work :O)
> > > First : can I do it, is it possible ?
> > > If not, is there a way ?

You forgot to add entry for your DTD in config/catalog.xml:

--------------------------------------
  <public publicId="-//INRIA//DTD specification 20020115//EN"
          uri="interstices/dtd/interstices.dtd"/>
--------------------------------------

Due to this omission and because all your templates begin with:

-----------------------------------------
<?xml version="1.0" encoding="iso-8859-1" ?>
<!DOCTYPE document PUBLIC "-//INRIA//DTD specification 20020115//EN"
"http://www.inria.fr/xml/dtd/stic/document.dtd"; [

]>
-----------------------------------------

The DTD was download from http://www.inria.fr/xml/dtd/stic/document.dtd
(very quick, not noticeable)

and this version of the DTD does not define a <a> element at all!

PS 1: After adding an entry to catalog.xml, do not forget to clear the
DTD cache using Options|Options, Schema Tab, Clear cache. If you are in
the process of developing your dtd, it is a good idea to temporarily
disable this cache.

PS 2: Your localize elements are taken from an old version of a
configuration file.

PS 3: The <detect> and <dtd> element as written are not useful because
you have added a <!DOCTYPE> to all your document templates.

PS 4: Some element templates are still missing xmlns="" (ex.
<elementTemplate name="simpleObject">)

PS 5: I think you load useless things from the docbook configuration
(ex. docbook_help.jar)

Reply via email to