Re: URLs for BXE for multiple users

Christian Stocker <[email protected]> Thu, 19 May 2005 15:00:30 +0200
Newsgroups gmane.editors.bitflux.general
Message-ID <[email protected]>
Hi

On 19.5.2005 12:40 Uhr, F Baube wrote:
> Hi all,
> 
> I'm tinkering with BXE 1.0, trying to set it up so that
> multiple users can use it at the same time, each editing 
> their own stuff.
> 
> So.. I guess I want to set up config.xml so that it uses 
> the "URL-Parameter" method to load the file it will edit.
> 
> In the examples, file "config.xml" has this long passage
> (I've reformatted it): 
> 
>         If you want to provide the location via an URL-Parameter:
>         <file name="BX_xmlfile" isParam="true">xml-url</file>
> 
>         and the request "index.html?xml-url=xml/article.xml" 
> 	leads to the same as the above example.
> 
>         If you want to pdrovide the location via an URL-Parameter:
>         <file name="BX_xmlfile" isConfigParam="true">
> 	      keyNameOfArrayElement</file>
> 
>         and the request 
> 	bxe_start("config.xml", true/false, 
> 	array("keyNameOfArrayElement"=>"xml/article.xml")) 
> 	leads to the same as the above example. (note: the example 
> 	doesn't work, you have to create your array in another way...
> 
>         Furthermore you have the option "prefix", which just prefixes 
> 	the url with this value. The following example would do the 
> 	same as above again (postfix is currently missing) 
>         <file name="BX_xmlfile" prefix="xml/">article.xml</file>
> 
> So, if I understand this correctly, I cannot use 
> the "isParam" and "prefix" attributes _together_.

Mmmh, yes you can, no matter if you use isConfigParam or isParam or the
default cause, prefix is always prefixed to the resulting URL. But you
have to put the prefix value in config.xml. You can't define that
differntly currently

> 
> In that case ...
> 
> Because I need to be able to specify the base 
> file name, I should use the "isParam" attribute.  
> So I wonder.. can I use an absolute path, rather 
> than a relative path as in the example. 
> 
> For example:
> 
> 	(config.xml)
> 	<file name="BX_xmlfile" isParam="true">theFilepath</file>
> 
> 	(URL)
> 	"[etc]/index.html?theFilepath=/pathto/myarticles/myarticle1357.xml" 

That's also possible.

> Does this seem correct ?  And, will this URL also work 
> when I attempt to PUT the file back to the server ? 

Yes, it takes the same URL for load and save (resp. GET and PUT)

chregu
> 
> 
> thanks much ! 
> 
> fred
> 

-- 
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