ZendGdata framework path set error

筅森魡賤 提交于 2019-12-04 04:11:20

问题


Hello I am using ZendGdata-1.12.5 framework to upload a video on youtube

I used the following in my php code

$path = './ZendGdata-1.12.5/library/';
set_include_path(get_include_path() . PATH_SEPARATOR . $path);

require_once('Zend/Loader.php');  

Zend_Loader::loadClass('Zend_Gdata');  
Zend_Loader::loadClass('Zend_Gdata_YouTube');  
Zend_Loader::loadClass('Zend_Gdata_AuthSub');  
Zend_Loader::loadClass('Zend_Gdata_ClientLogin');  

but nothing seems to be working ! help ?

PHP Warning: require_once(Zend/Xml/Security.php): failed to open stream: No such file or directory in /var/www/youtube_upload_video/ZendGdata-1.12.5/library/Zend/Gdata/App/Base.php on line 30

PHP Fatal error: require_once(): Failed opening required 'Zend/Xml/Security.php' (include_path='.:/usr/share/php:/usr/share/pear:./ZendGdata-1.12.5/library/') in /var/www/youtube_upload_video/ZendGdata-1.12.5/library/Zend/Gdata/App/Base.php on line 30


回答1:


The path is correct, the problem is that Zend Gdata library does not have the Zend/xml folder. It's a small folder with 2 files. All you need to do is following:

1) Go to: http://framework.zend.com/downloads/latest

2) Download 1.12 (or whatever your version is) MINIMAL package.

3) Extract it on your hard disk.

4) Upload /library/Zend/Xml folder to your server's /ZendGdata-1.12.5/library/ folder so that in your /ZendGdata-1.12.5/library/Zend folder you have the Xml folder.

5) That's it. Enjoy.



来源:https://stackoverflow.com/questions/23079465/zendgdata-framework-path-set-error

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!