You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@forrest.apache.org by Cameron McCormack <ca...@mcc.id.au> on 2006/11/27 00:42:41 UTC

Literal HTML content in a document-v20 file

Hi.

Is it possible to have some (X)HTML content in a document-v20 file that
won’t be modified upon generating the .html files?  I have an applet and
a form in one file, but my applet and input elements get mangled
(attributes go missing).  I tried putting those elements in the XHTML
namespace, but this makes no difference to the output.

Thanks,

Cameron

-- 
Cameron McCormack, http://mcc.id.au/
	xmpp:heycam@jabber.org  ▪  ICQ 26955922  ▪  MSN cam@mcc.id.au

Re: Literal HTML content in a document-v20 file

Posted by David Crossley <cr...@apache.org>.
Cameron McCormack wrote:
> Cameron McCormack wrote:
> > > Is it possible to have some (X)HTML content in a document-v20 file that
> > > won???t be modified upon generating the .html files?  I have an applet and
> > > a form in one file, but my applet and input elements get mangled
> > > (attributes go missing).  I tried putting those elements in the XHTML
> > > namespace, but this makes no difference to the output.
> 
> David Crossley:
> > Yes. I use that approach on the homepage of varietee.com.au
> 
> So the namespace trick should work?

I don't know. I didn't mean that part. I meant that adding
html content to a source file works for me. I didn't add any
xmlns attributes.

>  In my xml file I have:
> 
>   <table xmlns="http://www.w3.org/1999/xhtml" id="data">
>     ...
>         <applet id="chart" codebase="demo/" code="AppletDemo.class"
>                 width="400" height="300" mayscript="mayscript"
>                 archive="..."/>
>     ...
>         <input id="ShoeBar" type="text" value="10"/>
>     ...
>   </table>
> 
> which gets turned into:
> 
>   <table>
>     <a name="data"></a>
>     ...
>         <applet archive="..." code="AppletDemo.class" codebase="demo/"
>                 height="300"><a name="chart"></a></applet>
>     ...
>         <input><a name="ShoeBar"></a></input>
>     ...
>   </table>
> 
> Apart from some of the attributes disappearing, I need the ids to be
> kept on the elements so that some script in the page can modify them.
>
> > The relevant xml page needs to be excluded from validation
> > via forrest.properties file (or define your own schema).
> 
> I currently have validation turned off altogether.
> 
> > What version of Forrest are you using? From memory there were
> > some changes in 0.8-dev trunk (and maybe in forrest_07_branch)
> > that affect such attributes.
> 
> I???m using the 0.7 distribution.

Then that could well be your problem.

-David

Re: Literal HTML content in a document-v20 file

Posted by Cameron McCormack <ca...@mcc.id.au>.
Cameron McCormack wrote:
> > Is it possible to have some (X)HTML content in a document-v20 file that
> > won’t be modified upon generating the .html files?  I have an applet and
> > a form in one file, but my applet and input elements get mangled
> > (attributes go missing).  I tried putting those elements in the XHTML
> > namespace, but this makes no difference to the output.

David Crossley:
> Yes. I use that approach on the homepage of varietee.com.au

So the namespace trick should work?  In my xml file I have:

  <table xmlns="http://www.w3.org/1999/xhtml" id="data">
    ...
        <applet id="chart" codebase="demo/" code="AppletDemo.class"
                width="400" height="300" mayscript="mayscript"
                archive="..."/>
    ...
        <input id="ShoeBar" type="text" value="10"/>
    ...
  </table>

which gets turned into:

  <table>
    <a name="data"></a>
    ...
        <applet archive="..." code="AppletDemo.class" codebase="demo/"
                height="300"><a name="chart"></a></applet>
    ...
        <input><a name="ShoeBar"></a></input>
    ...
  </table>

Apart from some of the attributes disappearing, I need the ids to be
kept on the elements so that some script in the page can modify them.

> The relevant xml page needs to be excluded from validation
> via forrest.properties file (or define your own schema).

I currently have validation turned off altogether.

> What version of Forrest are you using? From memory there were
> some changes in 0.8-dev trunk (and maybe in forrest_07_branch)
> that affect such attributes.

I’m using the 0.7 distribution.

Thanks,

Cameron

-- 
Cameron McCormack, http://mcc.id.au/
	xmpp:heycam@jabber.org  ▪  ICQ 26955922  ▪  MSN cam@mcc.id.au

Re: Literal HTML content in a document-v20 file

Posted by David Crossley <cr...@apache.org>.
Cameron McCormack wrote:
> 
> Is it possible to have some (X)HTML content in a document-v20 file that
> won???t be modified upon generating the .html files?  I have an applet and
> a form in one file, but my applet and input elements get mangled
> (attributes go missing).  I tried putting those elements in the XHTML
> namespace, but this makes no difference to the output.

Yes. I use that approach on the homepage of varietee.com.au

The relevant xml page needs to be excluded from validation
via forrest.properties file (or define your own schema).

What version of Forrest are you using? From memory there were
some changes in 0.8-dev trunk (and maybe in forrest_07_branch)
that affect such attributes.

-David