LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (http://www.linuxquestions.org/questions/linux-software-2/)
-   -   Firefox - launching telnet (http://www.linuxquestions.org/questions/linux-software-2/firefox-launching-telnet-493500/)

Mithrilhall 10-18-2006 09:40 AM

Firefox - launching telnet
 
I have some webpages with telnet links (telnet://10.10.10.10). I want to be able to click on the links and have a terminal window open and start the telnet session to the IP address in the link.

When I click the link from within Firefox I get "Firefox doesn't know how to open this address, because the protocol (telnet) isn't associated with any program".


Any suggestions?

matthewg42 10-18-2006 11:33 AM

This should be what you need to work it out:

http://blog.ryaneby.com/archives/fir...ocol-handlers/

Mithrilhall 10-18-2006 02:05 PM

Thanks Matthew.

I got it working...somewhat.

How can I pass variables?

This is what I have so far:

Code:

/usr/bin/konsole
I want to pass the "telnet://10.10.10.10" to konsole. Any ideas how I would go about that?

matthewg42 10-18-2006 04:36 PM

Hmm, I can't get it to work. With simply /usr/bin/konsole it launches konsole but of course not with enough information to launch telnet with the correct address.

Using additional parameters like "/usr/bin/konsole -e telnet %h %p" just leads to an error message :(

I think maybe these external protocol handlers are broken in the Linux version of firefox?

Mithrilhall 10-18-2006 04:40 PM

I guess I could write a script that launches it.

matthewg42 10-18-2006 05:01 PM

But where will you get the hostname from? I tried this, but the called script doesn't get the address of the host or the port number on the command line, on standard input or via the environment...

Not sure how it could work, unless you always telnet to the same host, which is hard coded in the script...


All times are GMT -5. The time now is 07:48 PM.