Training, Open Source computer languages
PerlPHPPythonMySQLApache / TomcatTclRubyJavaC and C++LinuxCSS 
Search for:
Home Accessibility Courses Diary The Mouth Forum Resources Site Map About Us Contact
 
For 2023 (and 2024 ...) - we are now fully retired from IT training.
We have made many, many friends over 25 years of teaching about Python, Tcl, Perl, PHP, Lua, Java, C and C++ - and MySQL, Linux and Solaris/SunOS too. Our training notes are now very much out of date, but due to upward compatability most of our examples remain operational and even relevant ad you are welcome to make us if them "as seen" and at your own risk.

Lisa and I (Graham) now live in what was our training centre in Melksham - happy to meet with former delegates here - but do check ahead before coming round. We are far from inactive - rather, enjoying the times that we are retired but still healthy enough in mind and body to be active!

I am also active in many other area and still look after a lot of web sites - you can find an index ((here))
PHP & SSH

Posted by liderbug (liderbug), 7 August 2005
I'm trying to get ssh working in PHP.  I've upgraded to the L&G PHP and openssh.  I get:
  Call to undefined function ssh2_connect()

I've searched the web - I can find all sorts of references but no download.   aaaaaaaaaaaaalp!!

Thanks

Posted by admin (Graham Ellis), 7 August 2005
Try http://sourceforge.net/projects/libssh2/ for Linux or Unix, (or the binaries referred to in http://docs.php.net/en/ref.ssh2.html for Windows).

Posted by liderbug (liderbug), 8 August 2005
I downloaded libssh2 - compiled - ssh2_connect is not part of the files - I still have call to undefined.....

Next?


Posted by admin (Graham Ellis), 8 August 2005
Quote:
Next?


That comes across as slightly rude to me - or perhaps I've just had a long day!

Quote:
I've searched the web - I can find all sorts of references but no download.


There are times when just searching the web won't lead you to the source code directly ... for example if what you're looking for is always packed into a .tgz file.  You need to follow clues. I looked around and downloaded http://pecl.php.net/get/ssh2-0.9.tgz, unpacked it using
tar xzf ssh2-0.9.tgz
cd ssh2-0.9
head -459 ssh2.c | tail -25

and saw the source I think you're looking for.

You may prefer to visit http://pecl.php.net/package/ssh2 and download from that page.

Side note for other readers.  If you want to run a third party library within your PHP, you'll need to download that library; that was my first answer to this poster.  If that library is callable from many different languages, you may also need to download the "glue" that links PHP to the library - and almost inevitably you'll find that at Pecl or Pear.

Posted by liderbug (liderbug), 9 August 2005
Thanks and the "next" was ?humor? - head at 45... next?

Posted by admin (Graham Ellis), 20 August 2005
The source code you want is at lines 434 to 459 of the file quoted; the head and tail commands should have given you that. It's probably worth your while reading a little further into the technology (books, web pages, courses) rather than concentrating on just the original issue you posted on; I'm quite happy to help if you get stuck here, but I'm not a great lover of answering question that you haven't bothered to look up on the standard sources.

I once read a post elsewhere that said "Please don't use this site as a read-the-manual-to-me service".  I don't go quite that far as it's sometimes difficult to find what you're looking for in a big manual ...

Posted by curtis (curtis), 8 October 2005
Well, I don't think people should say they've "searched the Web" just because they read over the first page results in google, and didn't bother read anything in any of the resources.

I'm not pointing the finger at you, liderbug. I'm just saying, it happens all the time in general, as I can attest to it because of being a moderator on a different Web dev forum.

Anyway, good luck liderbug.

Posted by admin (Graham Ellis), 8 October 2005
on 10/08/05 at 07:03:14, curtis wrote:
Well, I don't think people should say they've "searched the Web" just because they read over the first page results in google, and didn't bother read anything in any of the resources.


I can recall once, when I was moderating a different forum, that the moderators were talking amongst themselves about one particular poster who had a very poor command of English and seemed to need a lot of assistance.  Very similar comments to those I have just quoted.   Yes, "us moderators" were getting more than a little frustrated because she hadn't bothered ...

Then our poster let something slip in one of her posts; it turned out that she was accessing the web through special equipment since she had disabillities that stopped her doing things in the way that all of the rest of us do, and that this reduced her use, her ability to read a lot, and her ability to post in the style to whihc the rest of us had become accustomed. That was one hell of a brave lady who wasn't asking for any special favours and good on her for that and for her shere guts!

Quote:
I'm just saying, it happens all the time in general, as I can attest to it because of being a moderator on a different Web dev forum.


If it happens "all the time" ... then perhaps the fault lies in the systems that aren't well set up to graciously handle this sort of enquiry, rather than in the people making the enquiry.  And that's why I've set up Opentalk to be a little bit different.

Have a look at the FAQ.

Posters who have a question that they can't see a quick and straightforward answer to from a search that's within their realm / books they have to hand are welcome to post and will not be critisised for it.  And it's their judgement as to what's within their realm.  For me, seated here at a high speed permanent connection and with some 500 technical books on the library shelves just behind me, there's going to be a lot more within my realm that there would be for, say, someone researching from the Internet Cafe I used a couple of years ago in Mossel Bay, where the connection was s-l-o-w in the extreme by my standards, and concentration was tough due to the gaming users to my immediate keft and right.

We do, though, ask that users give us enough information to help us help them.  We also ask that they give us feedback to let us know when and how their issues have been resolved, and to post in English ... that latter simply because none of the board's principals are fluent in othee languages.

Posted by curtis (curtis), 8 October 2005
Ok, now I feel like a horrible person.

That was not my intent, as I was referring to different cases. For instance, I see a lot of questions like, "What is PHP?" on the other forum I go to (many others too). I think that question's been asked dozens of times, by capable English speakers as well. That question is so general, that you should be able to turn up something on google that narrows down your understanding a bit. However, I will admit that it's also common for people to accidentally start learning in the wrong order. Using the "What is PHP" example, I sometimes can tell that someone's eager to learn how to design Web sites, but tried starting with PHP rather than first learning about HTML and a little bit about how servers work.

On specific, and precise topics, I completely understand the need to ask for help, in fact, I'm all for it, as that's how I've learned so much myself (you wouldn't believe how many times I've wanted to destroy regular expressions before getting the hang of them).

I'm sorry if my previous post was misunderstood, I didn't mean to come off as haughty or superior, as I'm definitely not The PHP Master, or anything like that.

peace,
Curtis



This page is a thread posted to the opentalk forum at www.opentalk.org.uk and archived here for reference. To jump to the archive index please follow this link.

You can Add a comment or ranking to this page

© WELL HOUSE CONSULTANTS LTD., 2024: Well House Manor • 48 Spa Road • Melksham, Wiltshire • United Kingdom • SN12 7NY
PH: 01144 1225 708225 • FAX: 01144 1225 793803 • EMAIL: info@wellho.net • WEB: http://www.wellho.net • SKYPE: wellho