3
votes

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

1 Answers

10
votes

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.