如何在WampServer 2.0(Windows XP)中安装FFMpeg [英] How to install FFMpeg in WampServer 2.0 (Windows XP)

查看:492
本文介绍了如何在WampServer 2.0(Windows XP)中安装FFMpeg的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我需要在本地主机上安装ffmpeg PHP扩展,所以我可以测试我的几个脚本,但是我有麻烦找出如何做到这一点。

I need to install the ffmpeg PHP extension on my localhost so I can test few of my scripts but I am having troubles figuring out how to do that.

拥有PHP 5.2.9-2的WampServer 2.0,我的操作系统是Windows XP。请有人给我一步一步的指示。

I have WampServer 2.0 with PHP 5.2.9-2, my OS is Windows XP. Please somebody give me step by step instructions.

我在这里找到了一些Windows构建: http://sourceforge.net/projects/ffmpeg-php/files/

I have found some Windows builds here: http://sourceforge.net/projects/ffmpeg-php/files/

但是我不知道下载哪一个以及如何处理文件。

But I don't know which one to download and what to do with files.

EDITED:



What I have done so far:


  1. 下载ffmpeg_new

  2. 将php_ffmpeg.dll从php5文件夹复制到C:\ wamp\bin\php\php5.2.9-2\ext

  3. 将文件从公用文件复制到windows / system32文件夹

  4. 添加extension = php_ffmpeg.dll到php.ini文件

  5. 重新启动所有服务(Apache,PHP ...)

  1. Download ffmpeg_new
  2. Copy php_ffmpeg.dll from the php5 folder to the C:\wamp\bin\php\php5.2.9-2\ext
  3. Copy files from common to the windows/system32 folder
  4. Add extension=php_ffmpeg.dll to php.ini file
  5. Restarted all services (Apache, PHP...)

使用这段代码后我收到错误:

I am gettings an error after using this code:

            $extension = 'ffmpeg';
            $extension_soname = 'php_ffmpeg.dll';
            $extension_fullname = PHP_EXTENSION_DIR . "/" . $extension_soname;

            // load extension
            if(false === extension_loaded($extension)) {
                if (false === dl($extension_soname))
                    throw new Exception("Can't load extension $extension_fullname\n");
            }

错误:

Warning: dl() [function.dl]: Not supported in multithreaded Web servers - use extension=ffmpeg.dll in your php.ini in C:\wamp\www\hunnyhive\application\modules\default\controllers\MyAccountController.php on line 314

另外我也从上面得到例外。

Plus I also get the exception from above.

推荐答案

将此行添加到您的php.ini文件

add this line to your php.ini file

[PHP_ffmpeg]
extension=php_ffmpeg.dll

这篇关于如何在WampServer 2.0(Windows XP)中安装FFMpeg的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆