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);
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

CODE NOT WORKING
Code: [Select]<?php
//include shared codes

include '../lib/common.php';
include

image upload, resize THEN submit form
Ok so I have a form that requires the user to upload an image, and then do something with that image

Sending a hyperlink through mail
HI all,
I am sending a mail to outlook mailbox of a user using FM SO_NEW_DOCUMENT_ATT_S

Help With editting and deleting form
Hallo !!

So look at this image :

http://img194.imageshack.us/img194/8272/snapshot5f.pn

rename the file
File.txt

Code: ***DOCUMENT***
..DN:
000044255
..CB:
..SN:
..PY:
2009
..E

Load file in PHP
I have 2 files. The first is a PHP generated XML file that's dependent by 2 inputs. The second is a

Please help - should be a simple fix.. driving me nuts
Everything seemed to be working fine. I have a table, it alphabetically lists a bunch of cities and

Help building / using array
First - this is a cross-posting, if this is wrong I apologise! What started out as a MySQL query que

displaying email without attracting a ton of spam
Hello,

this is maybe the wrong place to ask.
How would you display an email address on a w

Form help: Syntax & Logic
Hello again all,

I'm working on a form and ran into a wall (again) and can't seem to think th

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