Page 1 of 1

Class 'Swift' not found : strange

Posted: Sun Mar 01, 2009 9:46 am
by kigoobe
I'm getting this, while trying the new 3.3.3 version of swift mailer

Class 'Swift' not found in /home/user/public_html/class/gen.php on line 319

Line 317,318 and 319 reads:

Code: Select all

require_once ROOT."Swift-3.3.3-php5/lib/Swift.php";
require_once ROOT."Swift-3.3.3-php5/lib/Swift/Connection/SMTP.php";
$swift =& new Swift(new Swift_Connection_SMTP("mysite.com",25));
Now this is strange, as class Swift IS present in Swift.php at the given path.

Any help from anywhere?
For php5 users, we also have a problem with allow_url_include which needs to be "On" for this to work (In my server it was set to "Off").

Re: Class 'Swift' not found : strange

Posted: Sun Mar 01, 2009 4:35 pm
by omniuni
In your code, what is ROOT? Are you referencing your PHP files correctly for inclusion?

Re: Class 'Swift' not found : strange

Posted: Sun Mar 01, 2009 9:42 pm
by Chris Corbyn
omniuni wrote:In your code, what is ROOT? Are you referencing your PHP files correctly for inclusion?
My question exactly. What allow_url_include has to do with this I'm not sure. If ROOT starts with "http://" then this ain't gonna work. The include must be a local file include.