many thanks for the suggestions

one of of the reasons I didnt want to define a seperate protocol because I
wanted to be able to locate and download local server pages from anywhere
using existing mechanisms

file://x/y/z.lsp?filename=flower&filetype=gif
ftp://x/y/z.lsp?filename=flower&filetype=gif
http://x/y/z.lsp?filename=flower&filetype=gif
https://x/y/z.lsp?filename=flower&filetype=gif


otherwise I suppose a css style sheet might accept  this form??

lsp:file://x/y/z.lsp?filename=flower&filetype=gif
lsp:ftp://x/y/z.lsp?filename=flower&filetype=gif
lsp:http://x/y/z.lsp?filename=flower&filetype=gif
lsp:https://x/y/z.lsp?filename=flower&filetype=gif


any way thanks for the pointers - it'll take me a while to digest !!!


"Darin Fisher" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> rvj wrote:
> > Not sure if this is the correct newsgroup - apologies if not appropriate
> >
> > I want to have the functionality of a local http server to execute local
> > scripts and return a valid document
> >
> > Has anyone looked at this ...
> >
> > .... or is there already such functionality available?
> >
> > I dont want a local http service just the server page functionality
> >
> > I guess the simplest approach would be to extend the chrome protocol to
> > recognise  a specific file type for this purpose. for example lsp might
> > imply a
> > local server page
> >
> > lsp would be simply be a form of xul file capable of invoking the
relevant
> > XPCOM
> > components
> >
> >         chrome://x//y/z.lsp?param11=a?&param2=b
> >
> > I would like to be able to use such references in CSS style sheets
> >
> >     {
> >              list-style-image:
> > url("chrome://x//y/z.lsp?param11=a?&param2=b")
> >     }
> >
> >  I just want to be able to service a (http) request locally as it would
be
> > remotely.
> >
> > Ideally I would like to be able to use other protocols such as  file:
> >
> >      file://x/y/z.lsp?filename=flower&filetype=gif
> >
> > Any ideas if this might be possible?
> >
> >
> >
>
>
> you could do something like this as an add-on to mozilla if you defined
> your own URL scheme.  for example, you could introduce a URL of the form:
>
> lsp://x/y/z.lsp?filename=flower&filetype=gif
>
> you'd have to develop your own nsIProtocolHandler implementation for the
> "lsp" protocol scheme.  there is some documentation on
> nsIProtocolHandler here:
>
> http://mozilla.org/projects/embedding/embedapiref/embedapi57.html#1072910
>
> but, if you are going to write your own, then i suggest using one of the
> existing protocol handlers as a starting point.  the simple protocols
> like finger or datetime are good examples:
>
> http://lxr.mozilla.org/seamonkey/source/extensions/finger
> http://lxr.mozilla.org/seamonkey/source/extensions/datetime
>
> you could either develop your protocol handler inside the mozilla source
> tree as an extension along side finger and datetime, or you could
> develop it outside the mozilla source tree using the Gecko SDK.  for
> more info about writing mozilla components, you might find this an
> invaluable read:
>
> http://mozilla.org/projects/xpcom/book/cxc/
>
> of course if you have any questions, don't hesistate to ask =)
> darin
>



Reply via email to