[clug] Browsers executing commands
Jepri
jepri at webone.com.au
Sun Apr 4 16:58:11 GMT 2004
Francis James Whittle wrote:
> This is a tricky one.
>
> Basically, what it reads like you want to do is not part of any standard
> specified web protocol. It is, on the other hand, possible with
> gnomevfs (and probably kio for KDE people). A mini webserver won't help
Well, it'll help if the client is running both the browser and the
webserver, but it isn't what I'd call an elegant solution.
> you, because you're talking client-side stuff. It's certainly not
> possible to do this kind of thing from mozilla or any other mainstream
> web browser, excepting crappy ones like IE who can only do it by
> accident with embedded metadata and the suchlike.
Scarily enough, KDE will ask you in a dialogue to run an executable
linked to (with a href) on your local filesystem. That's 90% of what I
was looking for.
Now that you mention it, I could try using the Moz API, if I were ever
able to figure it out.
>
> If you can explain in more detail what you want to do and why, it might
> be possible to suggest a solution that matches our needs, or suggest an
> alternative solution (more likely).
Effectively, I would like to use HTML as a widget toolkit. Why HTML and
not native Gtk or Qt? Because HTML is very friendly to script-generated
content. There are lots of templating systems for HTML, and none at all
for Qt/Gtk.
The use I want to put this to is to have a script library, complete with
descriptions and categories. So I can browse my way through the
categories to the script I need, read the description and then if it is
what I want, click on the 'runme' link and have it run.
As I mention above, KDE will run a script, but without args, which means
I would have to write a "kick-off" script for every situation. Sigh.
Weren't computers meant to make life easier?
>
> Francis
>
> On Sun, 2004-04-04 at 22:46, Jepri wrote:
>
>>I've been wanting to put together a couple of HTML pages that embed
>>useful shell commands and other programs for me. Ideally, I'd like to
>>be able to activate them with a click. Effectively, I want URIs like
>>'<a href="shell://balsa">Mail client</a>'.
>>
>>And before anyone mentions it, I do appreciate the problem with someone
>>tricking me into clicking on '<a href="shell://rm -rf ~/">'.
>>
>>Is there a partway solution? I'm hoping to not have to embed GtkHTML or
>>Konqueror if I can avoid it.
>>
>>ATM I'm thinking of starting a mini-webserver and working it that way,
>>but it seems a bit of overkill.
>>
>>References to other similar projects would also be appreciated.
>>
>>Jepri
More information about the linux
mailing list