I'm having problems to implement Zend Framework on a website. It's not a fancy application, just uses some validation classes of Zend and the Zend_File_Transfer_Adapter_Http to upload files to the server. None of them work. The question is this: I've read that I should write a htaccess file to dictate the folder structure of the site, and also that mod_rewrite should be enabled. I don't know how to check for mod_rewrite since the control panel of my provider is very uninformative.
Anyway, I thought it was enough to include the Zend library like this:
$libreria = $_SERVER['DOCUMENT_ROOT'];
$libreria.='Zend/ZendFramework/library';
set_include_path(get_include_path().PATH_SEPARATOR.$libreria);
require_once('Zend/Loader/Autoloader.php');
Zend_Loader_Autoloader::getInstance();
But evidently it isn't. So another question I have is: ¿Should I instantiate the Autoloader differently, and should I specify a namespace like $loader = Zend_Loader_Autoloader::getInstance(); $loader->registerNamespace(something);
I don't think so because as I said I'm simply trying to include the validation classes and the file upload classes into the web page.
Finally, I have set the class PHPMailer on some scripts to process user input, and whenever I seem to include the path to Zend Framework right, the page throws a 500 Internal Server error, while that doesn't happen if I write the path incorrectly (that's another issue, I think if I set the path relative to the document it doesn't work, like for example doing $libreria='Zend/ZendFramework/library';
will not work, since I see all the conditions that I set for validating the input fail no matter what I write.
Then the last question is: does PHPMailer have some incompatibility with Zend Framework? Excuse me for asking but I'm a newbie and although I've checked PHPMailer classes and do not find anything incompatible, I must ask.
Thanks in advance if anyone is willing to help
I should add also that I've tested this website on a local server and it works fine, the problem is in the remote server.
Also, I've read this article here and it's what I'm looking for, according to it I should be able to reference the standard classes of Zend using the new operator. But on the remote server I can't do this, only locally.
Searching a bit more I've read about the possible causes for the Zend Installation to fail here on this same site and that allows me to clarify my questions: first, I think none of those conditions may be failing, although as I said I haven't been able to check mod_rewrite on the remote server of my provider, second, my htaccess file is empty so there's no redirection rules (that should discard problems with Zend Framework interacting with an incorrect htaccess, correct me if I'm wrong), and third, I don't have access to php.ini file. So what can I do? Any suggestion is accepted as I've been struggling with this the whole morning and can't have a clue of what's going wrong.