Re: Edit XHTML Files?
Christian Stocker <[email protected]> Fri, 04 Jun 2004 15:52:39 +0200
| Newsgroups | gmane.editors.bitflux.general |
|---|---|
| Message-ID | <[email protected]> |
On 4.6.2004 15:38 Uhr, Ulrich Fischer wrote:
>
> Thanks Cregu for that fast support.
>
> On .06.2004 14:31 Christian Stocker wrote:
>
>> where did you put that? It should be in the index.html (look in
>> examples/inlineXHTML for a sample), the same file, where you load the
>> whole thing with "bxe_start('config.xml');". As long as you don't have
>> a bxe_xhtmlfile defined, it should be ok.
>
>
> Oh - I feel so stupid.
>
> I thought:
>
> This Container in the index.html:::
> <!-- everything in the following div element will be replaced -->
> <div id="bxe_area">
> </div>
>
> would be replaced by the
>
> <input>
> <!-- The XML-document with the actual data -->
> <file name="BX_xmlfile">content.xml</file>
> <!-- The RelaxNG (XML Schema) -->
> <file name="BX_validationfile">schema/xhtml.rng.xml</file>
> </input>
>
> defined in the config.xml.
>
> Indeed: <file name="BX_xhtmlfile">content.xml</file>
> seems to be more correct.
> But it does not work without a BX_xmlfile?
Just Forget about BX_xhtmlfile and id="bxe_area" for the moment. It's a
special mode, which the university of zurich needed and it's not
important for your case. The basic idea behind this is, that the xhtml
defining the layout can be different from the file including all the
editor stuff. But as I said, not really important in your case.
>
> Alert: Eror loading config file ./config.xml could not be loaded
> You must supply an URL.
> [Only change in config.xml: <!-- <file
> name="BX_xmlfile">content.xml</file> -->
> <file name="BX_xhtmlfile">content.xml</file>]
>
>
>
> And than I wonder, why in the index.html (examples/inlineXHTML)
> there is the same content:
the content in index.html is just a placeholder and gets replaced as
soon as the editor loaded your xml file, therefore:
> <div id="main"
> bxe_xpath="/iba/page/Article/main">
everything in this div could be left out. It's just there for displaying
the data, before the editor is loaded. (it's usually dynamically created
on the server side from the same xml file as the editor loads later.
What you have to do basically is the following:
- put your XHTML content in a file, let's called it content.xml (it's
actually XML and BXE treats it as XML, it doesn't care, if it's XHTML or
not).
- make an index.html file with the following content (plus additional
headers...). This will be the file, which you load from the editor at first
<body onload="bxe_start('./config.xml')">
<div bxe_xpath="/xhtml:homepage/xhtml:body">
</div>
</body>
- in the config.xml <input> section you will need
<input>
<file name="BX_xmlfile">content.xml</file> // <- the path to your
content.xml file made earlier
<file name="BX_validationfile">relaxng.xml</file> // <- a relax ng
definition file
</input>
then it should work. hopefully
chregu
> <div id="id2641523"
> class="section">
> <a id="id2641523"
> name="id2641523"></a>
> <p>
> Bitflux Editor is a
> browser based Wysiwyg XML
> Editor – and that
> changes everything!
> [...]
>
> as in inline.xml
>
> <page>
> <Article ID="Article46">
> <ID>46</ID>
> <main xmlns:xhtml="http://www.w3.org/1999/xhtml">
>
> <xhtml:p>
> Bitflux Editor is a browser based Wysiwyg XML
> Editor – and that changes everything!
> [...]
>
>
>
> I have read the wiki, but I am afraid, I do not unterstand the system?
>
> http://svnweb.bitflux.ch/chora/co.php/trunk/scripts/loadsave.php?Horde=a6d343a0fca7ec99eec5cfdb4f1c86bd&rt=svneditor&r=726
>
>
> seems to point in that direction:
> index.html is something like a editor-frame
> in the: <div id="bxe_area"> </div> container
> the file-content is imported. We can change it here
> and than save it to the original file.
>
> But why do we have the same content twice like in the inlineXHTML?
>
> "irgendwie steh ich da auf dem Schlauch..."
>
>
> Ulrich
>
--
christian stocker | Bitflux GmbH | schoeneggstrasse 5 | ch-8004 zurich
phone +41 1 240 56 70 | mobile +41 76 561 88 60 | fax +41 1 240 56 71
http://www.bitflux.ch | [email protected] | gnupg-keyid 0x5CE1DECB
--
bx-editor-users mailing list
[email protected]
http://lists.bitflux.ch/cgi-bin/listinfo/bx-editor-users