Welcome Guest, Not a member yet? Register   Sign In
open_basedir
#1

[eluser]nirbhab[/eluser]
Guys please follow the urls:
I am stuck to a typical problem, can't get the solution

1. Error Page
http://jpopenstudios.com/testmail.php

2. phpinfo

http://jpopenstudios.com/phpinfo.php

3. Help url

some forum

but could not understand much,
i am using phpmailer,
Code:
ini_set("display_errors", true);
ini_set("open_base_dir", '/var/www/vhosts/jpopenstudios.com/httpdocs/');

error_reporting(E_ALL);

require("include/Mail/class.phpmailer.php");

$mail = new PHPMailer();
$mail->IsSMTP(); // telling the class to use SMTP
$mail->IsHTML(true);
$mail->Host = "***"; // SMTP server
$mail->From = "***";
$mail->Username = '***';
$mail->Password = '***';
$mail->AddAddress("***");

$mail->Subject = "First PHPMailer Message";
$mail->Body = "Hi! \n\n This is my first e-mail sent through PHPMailer.";
$mail->WordWrap = 50;

if(!$mail->Send())
{
   echo 'Message was not sent.';
   echo 'Mailer error: ' . $mail->ErrorInfo;
}
else
{
   echo 'Message has been sent.';
}

Please help
#2

[eluser]mrtopher[/eluser]
Are you trying to include/require any PHP files that are outside of httpdocs? I have experienced this error before (on servers running Plesk specifically) but it has only been because I was trying to include/require files that were outside of httpdocs or whatever the open_basedir directive is set to and Plesk happens to be rather strict about this.

Also, just out of curiosity, is there a reason why your trying to reset open_basedir? It's already set to what your trying to set it to.
#3

[eluser]nirbhab[/eluser]
Yeah i am trying to include file, as you can see the code, but it is in the httpddocs, hosting is on plesk, and one more incorrect thing i tried to accive is that the to set the open_basedir, it can only be set from php.ini.

this should not happen , any more soulutions, which i should do?
#4

[eluser]mrtopher[/eluser]
I'm not sure what to tell ya... nothing really looks out of the ordinary.

There is one other thing you could try... but I'm not sure it's going to work. There is an article in the Plesk knowledge base on how to change the open_basedir directive without modifying the php.ini file but you will need certain permissions on the server in order to implement it. If this is a shared hosting account you will most likely not be able to do it. But, anythings worth a shot.

http://kb.parallels.com/en/432




Theme © iAndrew 2016 - Forum software by © MyBB