perlquestion
giricredwolf
First, please forgive a lack of technical terms. I'm very new to some of this.<p>
I'm trying to write a perl program on WindowsXP that opens Telnet (telnet.exe) in a write-to mode. It then passes the phrase "set localecho" and an "enter" to set localecho on. Then it passes "open discworld.atuin.net" to open my favorite MUD. THen I want the program to exit while Telnet continues to run in another command prompt window.<p>
<readmore>
Here's what I have so far:<br>
<code>
use strict; #use strict...
open(TELNET, "|telnet") or die "$!"; #open writable telnet or die
sleep 5; #wait 5 seconds
print TELNET "set localecho\n"; #Turn telnet "localecho" on
sleep 5; #wait 5 seconds
print TELNET "open discworld.atuin.net\n"; #Open DiscworldMUD
</code>
All I can find this does so far is that it opens Telnet. I'm not sure what I'm doing wrong or if I should use Win32::Process stuff. What I really want to do is change the default settings for TelNet, but I can't find a file that it pulls settings from. I'm just trying to find a way to get around typing in "set localecho" every time I run the thing.</readmore><p>
Any help?