I want connect cisco router over telnet connection
a need send char CTRL-Z for update change
from DB and save and exit.

I do not know how Scan code or CHR() have
combination from keyboard CTRL + Z.

Plese help me.

My code:
<PRE>
<%

$ctrlz=???;
$fp = fsockopen ($myIPadress, 23, $errno, $errstr, 30);
if (!$fp) {
echo "$errstr ($errno)<br>\n";
} else {
fputs ($fp, "ena\npassword\nusername tomas password 
pass\n".CHR($ctrlz)."write\nexit\n");
while (!feof($fp)) {
$text=fgets ($fp,128);
echo $text;
}
fclose ($fp);
}
%>
</PRE>



Tomas

Reply via email to