windows php_ssh2.dll 用于 WinXP Pro sp3 上的 PHP 5.3.1

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/2066912/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-15 13:45:32  来源:igfitidea点击:

php_ssh2.dll for PHP 5.3.1 on WinXP Pro sp3

phpwindows

提问by NotoriousWebmaster

I had PHP 5.2.2 installed on a previous box (also WinXP Pro sp3) and had gotten the SSH2 extension from http://pecl4win.php.net/ext.php/php_ssh2.dll.

我在以前的机器上安装了 PHP 5.2.2(也是 WinXP Pro sp3),并从http://pecl4win.php.net/ext.php/php_ssh2.dll获得了 SSH2 扩展。

Sadly that server seems to be out of commission for now ("The pecl4win build box is temporarily out of service. We're preparing a new build system."). The old DLL doesn't work with the new PHP and I do not have MS Visual Studio 6 to compile it.

遗憾的是,该服务器目前似乎无法使用(“pecl4win 构建框暂时停止服务。我们正在准备新的构建系统。”)。旧的 DLL 不适用于新的 PHP,而且我没有 MS Visual Studio 6 来编译它。

Anyone have any idea where I can get this file for PHP 5.3.1? Or perhaps I should just roll back to PHP 5.2.2?

任何人都知道我可以从哪里获得 PHP 5.3.1 的这个文件?或者我应该回滚到 PHP 5.2.2?

I should mention that I'm using XAMPP 1.7.3 which has Apache 2.2. So I need DLL's compiled with VC6.

我应该提到我使用的是带有 Apache 2.2 的 XAMPP 1.7.3。所以我需要用 VC6 编译的 DLL。

回答by Suriyan Suresh

You can download vc6 version of php_ssh2 from here http://www.webvamp.co.uk/uploads/2011/02/php_ssh2-5.3.X-VC6-apache.zip

您可以从这里下载 php_ssh2 的 vc6 版本http://www.webvamp.co.uk/uploads/2011/02/php_ssh2-5.3.X-VC6-apache.zip

回答by Pascal MARTIN

There are two versions of lib_ssh2on http://downloads.php.net/pierre/:

http://downloads.php.net/pierre/lib_ssh2上有两个版本:

  • php_ssh2-svn20091128-5.3-nts-vc9-x86.zip
  • php_ssh2-svn20091128-5.3-vc9-x86.zip
  • php_ssh2-svn20091128-5.3-nts-vc9-x86.zip
  • php_ssh2-svn20091128-5.3-vc9-x86.zip

Those are VC9 versions, which means they should not be used with binaries from Apache.org (I suppose they are for IIS ? see the left column of http://windows.php.net/about VC6 vs VC9 ); you didn't say which web-server you were using, so maybe...

这些是 VC9 版本,这意味着它们不应与来自 Apache.org 的二进制文件一起使用(我想它们是用于 IIS 的?请参阅http://windows.php.net/关于 VC6 与 VC9 的左栏);你没有说你使用的是哪个网络服务器,所以也许......


(I didn't provide the direct links on purpose : those might get outdated quickly, and I didn't want that for an answer on SO)


(我没有故意提供直接链接:这些链接可能很快就会过时,我不想用它来回答 SO)

回答by Manoharan

Well after searching a lot i found the php_ssh2.dll for my Php 5.2.X VC6

经过大量搜索,我找到了我的 PHP 5.2.X VC6 的 php_ssh2.dll

Try this URL http://www.dll-file-download.com/P/php_ssh2.dll.html

试试这个网址 http://www.dll-file-download.com/P/php_ssh2.dll.html

回答by Manoharan

Here's the official PECL releases, with builds for 5.3, 5.4, and 5.5:

这是官方 PECL 版本,包含 5.3、5.4 和 5.5 版本:

http://windows.php.net/downloads/pecl/releases/ssh2/0.12/

http://windows.php.net/downloads/pecl/releases/ssh2/0.12/

回答by Rudi

I had a similar problem but no time to compile all that stuff. However I found an other solution, to execute linux-bash scripts on a remote ssh server: Putty + Plink+ PHP's exec()

我有一个类似的问题,但没有时间编译所有这些东西。但是我找到了另一个解决方案,在远程 ssh 服务器上执行 linux-bash 脚本:Putty + Plink+ PHP's exec()

With this tools, it is possible to open ssh connections with putty via command line, executed through PHP's exec, system or passthroughfunctions.

使用此工具,可以通过命令行打开与 putty 的 ssh 连接,通过 PHP 的exec、system 或 passthrough函数执行。

Of course this is not as that elegant as ssh-functions for PHP, but maybe this helps someone for it's problem.

当然,这不像 PHP 的 ssh 函数那么优雅,但也许这有助于解决问题。

回答by Vishwas D

Follow these steps:

按着这些次序:

  1. extract php_ssh2.dll file and paste in /ext folder
  2. make following entry in php.ini

     extension=php_ssh2.dll;
    
  3. restart apache
  4. check php.ini for changes
  1. 提取 php_ssh2.dll 文件并粘贴到 /ext 文件夹中
  2. 在 php.ini 中输入以下条目

     extension=php_ssh2.dll;
    
  3. 重启阿帕奇
  4. 检查 php.ini 是否有变化