Why doesn't this work? (SSH2)


Posted on 16th Feb 2014 07:03 pm by admin

This is my script:

Code: <?php
$connection = ssh2_connect('213.251.167.109', 22);
Did you know?Explore Trending and Topic pages for more stories like this.
ssh2_auth_password($connection, 'root', 'MGdgfskc');

$stream = ssh2_exec($connection, 'useradd -d /home/users/test -m testftp');
$stream = ssh2_exec($connection, 'passwd testftp');
$stream = ssh2_exec($connection, 'password');
$stream = ssh2_exec($connection, 'password');
?>
This is my errors:
Code: Fatal error: Call to undefined function ssh2_connect() in /home/chaosnz/public_html/fotosnap.net/test.php on line 2
No comments posted yet

Your Answer:

Login to answer
285 Like 11 Dislike
Previous forums Next forums
Other forums

function not returning the correct value
I have a program that needs to return a value from a function. I have an output statement inside the

PHP Form to Variable.
Hi! I have written a HTML-form code in DreamWeaver CS3 (in a PHP doc) and I really need it to work s

Code error with Index.php
Error: Parse error: syntax error, unexpected T_STRING, expecting ',' or ';' in /home/runevid/public_

Ball movement
I want to move a ball from one point to another and it should hit a group of balls at the other end

Query failed issue with php script but works fine in mssql manager!
hi i have the script below which copies data from one table to another but will only insert new data

Line break?
Hi, I'm new to the forum and new to php. I'm not sure if I'm using the correct terminology so here i

GIS appliction help
I found some tutorials in the internet to develop a map application I don't want to use google maps

Edit MySQL Row Using PHP and HTML Form
Hello,

Here's what I'm trying to do. Build a page where a user enters a MySQL row number in.

PHP switch function help
Hi, I am trying to create a search function for a directory website. On the search function on html

Am I setting up my sites oldschool?
Ok,

When I create a site I open a basic template that I have created that consists of a css f

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash