Ich versuche, in einem Solaris-Server mithilfe von PHP ssh. Ich habe ein ssh2.php Paket von this linkKann abstrakte Klasse nicht instanziieren Net_SSH2
heruntergeladen und es in meinen Code eingeschlossen. Mein Code folgt
<?php
include 'D:/MySoftwares/xampp/xampp/php/PEAR/Net_SSH2-master/Net/SSH2.php';
$ssh = new Net_SSH2('ip');
if (!$ssh->login('user', 'pass')) {
exit('Login Failed');
}
echo $ssh->exec('pwd');
echo $ssh->exec('ls -ltrh');
?>
Jetzt bin ich bekommen "Fatal error: Kann nicht abstrakte Klasse Net_SSH2 in D instanziiert: \ MySoftwares \ xampp \ xampp \ htdocs \ connectdas \ contodas.php in Zeile 4". Ich bin ein Linux-Mensch und weiß wenig über PHP-Klassen. Kann mir jemand helfen?