Search…

X3 Photo Gallery Support Forums

Search…
 
margouillat
Experienced
Topic Author
Posts: 34
Joined: 31 Jul 2011, 09:20

Contac and Red Cross

23 Nov 2014, 10:55

Hi,

everything works but is it normal that once the message is sent there is a red cross suggests that the message is not sent ?

regards
Margouillat
loeildumargouillat.fr
 
User avatar
mjau-mjau
X3 Wizard
Posts: 13998
Joined: 30 Sep 2006, 03:37

Re: Contac and Red Cross

23 Nov 2014, 11:30

No, that would indicate that the script is not working. Are you saying the emails are getting sent?

How did you add the form? Right now, it has to be identical as in the /example/other/contact/ with the two hidden placeholder fields at the top, which are there to protect from spam ...
 
margouillat
Experienced
Topic Author
Posts: 34
Joined: 31 Jul 2011, 09:20

Re: Contac and Red Cross

24 Nov 2014, 01:58

mjau-mjau wrote:No, that would indicate that the script is not working. Are you saying the emails are getting sent?
Yes, they are
mjau-mjau wrote:How did you add the form? Right now, it has to be identical as in the /example/other/contact/ with the two hidden placeholder fields at the top, which are there to protect from spam ...
I've just filled the page setting, widget contact and the folder 5.contact, nothing else.
if you want to take a look i send you loggin and pswd by PM
Margouillat
loeildumargouillat.fr
 
User avatar
mjau-mjau
X3 Wizard
Posts: 13998
Joined: 30 Sep 2006, 03:37

Re: Contac and Red Cross

24 Nov 2014, 04:11

I checked the contact page, and in the response I see this:
Code
<br />
<b>Warning</b>:  unlink() [<a href='function.unlink'>function.unlink</a>]: open_basedir restriction in effect. File() is not within the allowed path(s): (/home/www/69d592bebf60581561c0be294d6008a0:/tmp:/opt/php/lib/php) in <b>/home/www/69d592bebf60581561c0be294d6008a0/web/app/cache.inc.php</b> on line <b>37</b><br />
true
The "true" part at the bottom is the important part, so it is working fine, and the top is just a "warning" which does not really affect anything. However, it seems your server has open_basedir restriction active, and I am surprised you don't get the same error on other pages.

Can you check one thing for me? From FTP, navigate into the app/_cache/ folder and check that there are files- and folders inside both app/_cache/templates/ and app/_cache/pages ... Just want to make sure at least that it can create cache files!

I believe the issue may be that your server's open_basedir restriction is blocking the X3 script from deleting files in the cache, which is necessary to purge and refresh data ... else it will fill up over time with old junk.
 
margouillat
Experienced
Topic Author
Posts: 34
Joined: 31 Jul 2011, 09:20

Re: Contac and Red Cross

24 Nov 2014, 07:00

mjau-mjau wrote:Can you check one thing for me? From FTP, navigate into the app/_cache/ folder and check that there are files- and folders inside both app/_cache/templates/ and app/_cache/pages ... Just want to make sure at least that it can create cache files!.
app/_cache/templates/, contain folders and files
app/_cache/pages, contain files
mjau-mjau wrote:I believe the issue may be that your server's open_basedir restriction is blocking the X3 script from deleting files in the cache, which is necessary to purge and refresh data ... else it will fill up over time with old junk.
I think you're right, What can I do to resolve this "problem"?
Margouillat
loeildumargouillat.fr
 
User avatar
mjau-mjau
X3 Wizard
Posts: 13998
Joined: 30 Sep 2006, 03:37

Re: Contac and Red Cross

24 Nov 2014, 09:13

margouillat wrote:I think you're right, What can I do to resolve this "problem"?
At least the script is able to write files, and that is the important part. Until you see that notice in your pages, I would not be too concerned ... I might fix X3 so that it ignores the "notice" and just see's the "true" message.

Basically your server has open_basedir setup so that the X3 PHP script is now allowed to delete some file types (in the x3 cache folder), unless they are in some specific temporary folder /tmp:/opt/php/lib/php ... Even if the files are within the base of the file that is trying to delete them!

app/cache.inc.php wants to delete files in a subfolder:
app/_cache/

I would contact your host and ask them to turn off open_basedir, or ask them why it is like this ...
 
localhost
Experienced
Posts: 158
Joined: 20 Sep 2011, 07:09

Re: Contac and Red Cross

25 Nov 2014, 01:13

Hi Karl,

I'm also seeing the red cross (X) when trying to send an email. The message does not send though... I have put my email address on the config.php and settigs on the Panel.
 
User avatar
mjau-mjau
X3 Wizard
Posts: 13998
Joined: 30 Sep 2006, 03:37

Re: Contac and Red Cross

25 Nov 2014, 10:38

localhost wrote:I'm also seeing the red cross (X) when trying to send an email. The message does not send though... I have put my email address on the config.php and settigs on the Panel.
To be honest, the current email implementation is pretty basic for now, and there are dozen things that can go wrong depending on your server. If you have a link, at least I can see what the error is and if it is sending or not ... in the original post here, the mailer actually works, but because of some "notice" in the success message, it thinks it didn't send ...
 
User avatar
Artur
Imagevue PowerPack
Posts: 510
Joined: 20 May 2011, 03:17

Re: Contac and Red Cross

25 Nov 2014, 11:12

I've just checked and the same issue here, except the fact that the message is not sent out.

Mail function is working fine on my server (at least in form like PHPMailer class)

The contact form response:
Code
cannot send from server
 
User avatar
mjau-mjau
X3 Wizard
Posts: 13998
Joined: 30 Sep 2006, 03:37

Re: Contac and Red Cross

26 Nov 2014, 04:53

Artur wrote:Mail function is working fine on my server (at least in form like PHPMailer class
May I ask from what application you are using PHPMailer, and what settings you may have applied (smtp etc)? The reason I ask, is because essentially, PHPmailer just uses the standard php mail() function unless you have set it to use SMTP or another specific option.

On your server, the PHP mail() function simply fails. I assume it might have been turned off for security/spam reasons, and they rely on SMTP only. This is why we added this option to Imagevue X2. Here is the basic code in X3 PHP:
Code
if(mail($to, $subject, $message, 'From: ' . $email)) {
    return 'true'; // success!
  } else {
    return 'cannot send from server'; // server mail() fail
}
 
localhost
Experienced
Posts: 158
Joined: 20 Sep 2011, 07:09

Re: Contac and Red Cross

27 Nov 2014, 16:00

mjau-mjau wrote:
localhost wrote:I'm also seeing the red cross (X) when trying to send an email. The message does not send though... I have put my email address on the config.php and settigs on the Panel.
If you have a link, at least I can see what the error is and if it is sending or not ... in the original post here, the mailer actually works, but because of some "notice" in the success message, it thinks it didn't send ...

Here's the link to my contact page Karl

http://larryanda.com/x3/contact/
 
User avatar
mjau-mjau
X3 Wizard
Posts: 13998
Joined: 30 Sep 2006, 03:37

Re: Contac and Red Cross

28 Nov 2014, 10:03

localhost wrote:Here's the link to my contact page Karl
http://larryanda.com/x3/contact/
Basically your server just doesn't send mail with the mail() function.
Image

May I ask who is your host? I am curious to know what they write about this in their support ... Chance is they have disabled the default localhost mailer, and require SMTP to be used for security and as a precaution to spam. I know it's not working because basically your server outputs the error on the basic mail() function below ...
Code
if(mail($to, $subject, $message, 'From: ' . $email)) {
  return 'true'; // success!
} else {
  return 'cannot send from server'; // server mail() fail
}
 
localhost
Experienced
Posts: 158
Joined: 20 Sep 2011, 07:09

Re: Contac and Red Cross

28 Nov 2014, 15:37

mjau-mjau wrote:
May I ask who is your host?
I'm using Bluehost...
 
User avatar
mjau-mjau
X3 Wizard
Posts: 13998
Joined: 30 Sep 2006, 03:37

Re: Contac and Red Cross

29 Nov 2014, 01:42

It seems Bluehost requires some additional header as I found out in these links [1][2][3]. Do I still have FTP access to your website if I wanted to check for a fix?
 
localhost
Experienced
Posts: 158
Joined: 20 Sep 2011, 07:09

Re: Contac and Red Cross

29 Nov 2014, 02:31

Yes Karl, the FTP access is still on.