Forums

Attachments Not Sent With Email

ehab 05 Dec, 2010
Hello,

I have been using a chrono forms to email me results upon submission of my form and has been working great so far. I have an upload field which regularly emailed me the uploads as an attachment and I cant seem to figure out what could have changed for this to happen.

File Upload Settings:

Enable uploads: Yes
Field names/allowed Extensions/sizes(KB): file_22:doc|docx|pdf{2000-1}
Full upload Path: /home/medcheck/public_html/components/com_chronocontact/uploads/EDIP/ - " Not Writable "
FileName format: $filename = date('YmdHis').'_'.$chronofile['name'];
Default Path:/home/medcheck/public_html/components/com_chronocontact/uploads/EDIP/

Please find deugging results below:
Form passed first SPAM check OK
Form passed the submissions limit (if enabled) OK
Form passed the Image verification (if enabled) OK
Form passed the server side validation (if enabled) OK
$_POST Array: Array ( [text_1] => tewtge [radio0] => Male [text_3] => wrg [text_4] => eg [text_6] => e [text_5] => [text_7] => [text_9] => 454 [text_10] => [email]g@gg.com[/email] [text_11] => gw [radio1] => Yes [text_14] => ff [select_24] => Manufacturing [text_13] => dh [radio2] => Yes [radio3] => Yes [text_20] => defed [text_21] => dfbgd [check4] => Array ( [0] => Yes ) [chrono_verification] => grjPL [button_21] => Submit [3a21e8fe9ef6a533a13af45d578b79d3] => 1 [1cf1] => 0cf31c564bfe008bfa39438e865c1131 [chronoformname] => EDIP )
$_FILES Array: Array ( [file_22] => Array ( [name] => Private Dinner_Mr.pdf [type] => application/pdf [tmp_name] => /tmp/phpDEaYuA [error] => 0 [size] => 67970 ) )
Upload routine started for file upload by : file_22
/home/arceit/public_html/content/components/com_chronocontact/uploads/EDIP/ has NOT been uploaded!!
Form passed the plugins step (if enabled) OK
An email has been SENT successfully from (ARCEIT)ehab@arceit.org to [email]ehab.esam@gmail.com[/email], [email]arceit.edip@gmail.com[/email]
Debug End

Any assistance will be much appreciated!
GreyHead 05 Dec, 2010
Hi ehab,

It looks as if the file is being uploaded to the temporary folder Ok but isn't then being moved to the uploads/EDP folder. Please check the folder permissions as the entry says

/home/medcheck/public_html/components/com_chronocontact/uploads/EDIP/ - " Not Writable "


Bob
ehab 05 Dec, 2010
I suspected that may be the source of the problem but as I am new to joomla could you please give me instructions on how to check the folder permissions and change them to 777 if required?

Thanks!
GreyHead 05 Dec, 2010
Hi ehab,

This isn't particularly a Joomla! question but one about configuring files on youer server. Your ISP's help files should tell you how you can do that. Usually you'd use yout FTP file explorer to access the file and change the permissions - there's an example here.

There's also a good (but quite detailed) Joomla! doc on file permissions here.

Bob
ehab 08 Dec, 2010
Hello again,

Your previous post was very useful as my full upload path is now "Writable" after setting permissions to 777.

Unfortunatley chronoforms is still emailing forms without attachments?? Heres another debug report:
Form passed first SPAM check OK
Form passed the submissions limit (if enabled) OK
Form passed the Image verification (if enabled) OK
Form passed the server side validation (if enabled) OK
$_POST Array: Array ( [text_1] => test attachment [radio0] => Male [text_3] => hrsd [text_4] => rst [text_6] => rths [text_5] => 435 [text_7] => 3453 [text_9] => 7655 [text_10] => [email]ehab@ehab.com[/email] [text_11] => rh [radio1] => Yes [text_14] => rth [select_24] => Manufacturing [text_13] => hr [radio2] => No [radio3] => Yes [text_20] => sr [text_21] => rnds [check4] => Array ( [0] => Yes ) [chrono_verification] => a72rQ [button_21] => Submit [0ea8eb6547bdef852e4d621d27d30935] => 1 [1cf1] => befd172a7c85b38881aca256fe32b91f [chronoformname] => EDIP )
$_FILES Array: Array ( [file_22] => Array ( [name] => Private Dinner_Mr.pdf [type] => application/pdf [tmp_name] => /tmp/phpPBDgiT [error] => 0 [size] => 67970 ) )
Upload routine started for file upload by : file_22
/home/arceit/public_html/content/components/com_chronocontact/uploads/EDIP/ has NOT been uploaded!!
Form passed the plugins step (if enabled) OK
An email has been SENT successfully from (ARCEIT)ehab@arceit.org to [email]ehab.esam@gmail.com[/email], [email]arceit.edip@gmail.com[/email]
Debug End

Please help!
GreyHead 08 Dec, 2010
Hi ehab,

Hmmm . . . the file isn't being uploaded - or more correctly ChronoForms can't move it from the temporary upload folder to the uploads/EDIP folder
/home/arceit/public_html/content/components/com_chronocontact/uploads/EDIP/ has NOT been uploaded!!


I'm not sure why this should be. Please try setting your site Global Configuration | Error Reporting to Maximum temporarily and see if you then get any sueful error messages.

Bob
ehab 08 Dec, 2010
I realize that the problem lies in moving the uploads to my default path. However, I have triple checked all related joomla and chronoforms configurations and even tried using a different upload path but encountered the same problem which begins with:

JFTP::store: Bad response
Warning! - Failed to move file.
Followed by the same debug report.

I also followed your suggestions and turned on system debugging and changed error reporting to maximum but could not find anything useful or related to this problem. Here is the output you may have better luck:
SELECT * 
  FROM jos_session 
  WHERE session_id = '52fccca7d92d0c409f62a66c10f8dc8d'
DELETE 
  FROM jos_session 
  WHERE ( time < '1291802322' )
SELECT * 
  FROM jos_session 
  WHERE session_id = '52fccca7d92d0c409f62a66c10f8dc8d'
UPDATE `jos_session` 
  SET `time`='1291805922',`userid`='0',`usertype`='',`username`='',`gid`='0',`guest`='1',`client_id`='0',`data`='__default|a:8:{s:15:\"session.counter\";i:7;s:19:\"session.timer.start\";i:1291805803;s:18:\"session.timer.last\";i:1291805890;s:17:\"session.timer.now\";i:1291805892;s:22:\"session.client.browser\";s:119:\"Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.10 (KHTML, like Gecko) Chrome/8.0.552.215 Safari/534.10\";s:8:\"registry\";O:9:\"JRegistry\":3:{s:17:\"_defaultNameSpace\";s:7:\"session\";s:9:\"_registry\";a:1:{s:7:\"session\";a:1:{s:4:\"data\";O:8:\"stdClass\":0:{}}}s:7:\"_errors\";a:0:{}}s:4:\"user\";O:5:\"JUser\":19:{s:2:\"id\";i:0;s:4:\"name\";N;s:8:\"username\";N;s:5:\"email\";N;s:8:\"password\";N;s:14:\"password_clear\";s:0:\"\";s:8:\"usertype\";N;s:5:\"block\";N;s:9:\"sendEmail\";i:0;s:3:\"gid\";i:0;s:12:\"registerDate\";N;s:13:\"lastvisitDate\";N;s:10:\"activation\";N;s:6:\"params\";N;s:3:\"aid\";i:0;s:5:\"guest\";i:1;s:7:\"_params\";O:10:\"JParameter\":7:{s:4:\"_raw\";s:0:\"\";s:4:\"_xml\";N;s:9:\"_elements\";a:0:{}s:12:\"_elementPath\";a:1:{i:0;s:72:\"/home/arceit/public_html/content/libraries/joomla/html/parameter/element\";}s:17:\"_defaultNameSpace\";s:8:\"_default\";s:9:\"_registry\";a:1:{s:8:\"_default\";a:1:{s:4:\"data\";O:8:\"stdClass\":0:{}}}s:7:\"_errors\";a:0:{}}s:9:\"_errorMsg\";N;s:7:\"_errors\";a:0:{}}s:13:\"session.token\";s:32:\"fbcb64609feec72ef6b94d0d64738dbe\";}__eb81adcc4edfeccb1ba0f16dfe1a737f|a:1:{s:19:\"chrono_verification\";s:32:\"5ea0fafcb35c40acff859811c16be00e\";}' 
  WHERE session_id='52fccca7d92d0c409f62a66c10f8dc8d'
SELECT * 
  FROM jos_components 
  WHERE parent = 0
SELECT folder AS type, element AS name, params 
  FROM jos_plugins 
  WHERE published >= 1 
  AND access <= 0 
  ORDER BY ordering
SELECT m.*, c.`option` AS component 
  FROM jos_menu AS m 
  LEFT JOIN jos_components AS c 
  ON m.componentid = c.id 
  WHERE m.published = 1 
  ORDER BY m.sublevel, m.parent, m.ordering
SELECT template 
  FROM jos_templates_menu 
  WHERE client_id = 0 
  AND (menuid = 0 OR menuid = 8) 
  ORDER BY menuid DESC 
  LIMIT 0, 1
SELECT * 
  FROM `jos_chrono_contact` 
  WHERE `name` = 'EDIP'
SELECT * 
  FROM `jos_chrono_contact` 
  WHERE `name` = 'EDIP'
SELECT * 
  FROM `jos_chrono_contact_emails` 
  WHERE `formid` = '2' 
  ORDER BY emailid
SELECT * 
  FROM `jos_chrono_contact` 
  WHERE `id` = '2'
SELECT * 
  FROM `jos_chrono_contact` 
  WHERE `id` = '2'
SELECT * 
  FROM `jos_chrono_contact_plugins` 
  WHERE `form_id` = '2' 
  AND event IN ('ONSUBMIT','ONLOADONSUBMIT') 
  AND `name` = ''
SELECT * 
  FROM `jos_chrono_contact` 
  WHERE `id` = '2'
SELECT * 
  FROM `jos_chrono_contact` 
  WHERE `id` = '2'
SELECT * 
  FROM `jos_chrono_contact` 
  WHERE `id` = '2'
SELECT * 
  FROM `jos_chrono_contact_plugins` 
  WHERE `form_id` = '2' 
  AND event IN ('ONSUBMIT','ONLOADONSUBMIT') 
  AND `name` = ''
SELECT * 
  FROM `jos_chrono_contact` 
  WHERE `id` = '2'
SELECT * 
  FROM `jos_chrono_contact` 
  WHERE `id` = '2'
INSERT INTO `jos_chronoforms_EDIP` ( `uid`,`recordtime`,`ipaddress`,`cf_user_id`,`text_1`,`radio0`,`text_4`,`text_6`,`text_5`,`text_7`,`text_9`,`text_10`,`text_11`,`radio1`,`text_14`,`radio2`,`radio3`,`file_22`,`check4`,`text_3`,`text_13`,`text_20`,`text_21`,`select_24` ) 
  VALUES ( 'IOWQzMWU4ZWM2OGYy11df84dbdc9f0d5177607ed2d751260d','2010-12-08 - 13:58:57','193.188.105.20','0','erhae','Male','geer','','','','34','ed@erg.com','','Yes','','Yes','Yes','','Yes','reg','',' r','r','Manufacturing' )
SELECT id, title, module, position, content, showtitle, control, params 
  FROM jos_modules AS m 
  LEFT JOIN jos_modules_menu AS mm 
  ON mm.moduleid = m.id 
  WHERE m.published = 1 
  AND m.access <= 0 
  AND m.client_id = 0 
  AND ( mm.menuid = 8 OR mm.menuid = 0 ) 
  ORDER BY position, ordering
SELECT * 
  FROM jos_swmenu_config 
  WHERE id = 85
SELECT jos_menu.* , jos_swmenu_extended.*
                
  FROM jos_menu 
  LEFT JOIN jos_swmenu_extended 
  ON jos_menu.id = jos_swmenu_extended.menu_id
                
  AND (jos_swmenu_extended.moduleID = '85' OR jos_swmenu_extended.moduleID IS NULL)
                
  WHERE jos_menu.menutype = 'mainmenu' 
  AND published = '1'
           
                
  ORDER BY parent, ordering
SELECT s.*  
  FROM jos_sections AS s 
  WHERE s.scope = "content" 
  AND s.access <= 0 
  AND (s.id=2 OR s.id=1) 
  AND s.published = 1 
  ORDER BY s.title ASC
SELECT a.*,  CASE WHEN CHAR_LENGTH(a.alias) THEN CONCAT_WS(":", a.id, a.alias) ELSE a.id END AS slug, CASE WHEN CHAR_LENGTH(cc.alias) THEN CONCAT_WS(":", cc.id, cc.alias) ELSE cc.id END AS catslug 
  FROM jos_content AS a 
  INNER JOIN jos_categories AS cc 
  ON cc.id = a.catid 
  INNER JOIN jos_sections AS s 
  ON s.id = a.sectionid 
  WHERE a.state = 1 
  AND ( a.publish_up = '0000-00-00 00:00:00' OR a.publish_up <= '2010-12-08 10:58:58' ) 
  AND ( a.publish_down = '0000-00-00 00:00:00' OR a.publish_down >= '2010-12-08 10:58:58' ) 
  AND s.id > 0 
  AND a.access <= 0 
  AND s.published = 1 
  AND a.sectionid = 2 
  AND (a.catid=15 OR a.catid=13) 
  ORDER BY a.created DESC 
  LIMIT 0, 20
SELECT a.*,  CASE WHEN CHAR_LENGTH(a.alias) THEN CONCAT_WS(":", a.id, a.alias) ELSE a.id END AS slug, CASE WHEN CHAR_LENGTH(cc.alias) THEN CONCAT_WS(":", cc.id, cc.alias) ELSE cc.id END AS catslug 
  FROM jos_content AS a 
  INNER JOIN jos_categories AS cc 
  ON cc.id = a.catid 
  INNER JOIN jos_sections AS s 
  ON s.id = a.sectionid 
  WHERE a.state = 1 
  AND ( a.publish_up = '0000-00-00 00:00:00' OR a.publish_up <= '2010-12-08 10:58:58' ) 
  AND ( a.publish_down = '0000-00-00 00:00:00' OR a.publish_down >= '2010-12-08 10:58:58' ) 
  AND s.id > 0 
  AND a.access <= 0 
  AND s.published = 1 
  AND a.sectionid = 1 
  AND (a.catid=15 OR a.catid=13) 
  ORDER BY a.created DESC 
  LIMIT 0, 20


Thanks again for your time and assistance!
GreyHead 09 Dec, 2010
Hi ehab ,

As a test please try turning FTP off in the Site Global Configuration.

I suspect that FTP is being used to make the move and the FTP user doesn't have the necessary permissions.

Bob
ehab 09 Dec, 2010
Just disabled the ftp from the configuration.php and im glad to report no more jftp errors and my attachments are being sent again!!

Thanks it did the trickπŸ™‚
Vollover 30 Mar, 2012
Hi EveryOne!
I have a similar problem, but I think my URL cause it.
See the debug report:

[list]Form passed first SPAM check OK
Form passed the submissions limit (if enabled) OK
Form passed the Image verification (if enabled) OK
Form passed the server side validation (if enabled) OK
$_POST Array: Array ( [text_name] => Teszt Name [text_telefon1] => 000000 [text_telefon2] => 000000 [text_emailcim] => [email]teszt@skindrome.hu[/email] [text_ville] => City [radio0] => 12-14 heures [text_egyebkerdes] => tes aatached comment [button_13] => soumettre [8cc3c672b620470efa9308d320271405] => 1 [1cf1] => e68b803a30df58a7f0447d1e73b45718 [chronoformname] => enregistrement_p_fileupload )
$_FILES Array: Array ( [file_upload] => Array ( [name] => teszt.jpg [type] => image/jpeg [tmp_name] => /tmp/phpMKJoqO [error] => 0 [size] => 67666 ) )
Upload routine started for file upload by : file_upload
/home/madenta_fr/www/images/stories/pacinesek_kepei/20120330092305_teszt.jpg has NOT been uploaded!!
Form passed the plugins step (if enabled) OK
An email has been SENT successfully from (Madenta France)erika.orban@madenta.fr to [email]teszt@skindrome.hu[/email]
An email has been SENT successfully from (Madenta.fr)teszt@skindrome.hu to [email]tamas.vecsey@skindrome.hu[/email]
Debug End[/list]

More than one Joomla site works on this web hosting in different folder so I guess The upload directory souldn't contain "www". How can I change this URL?
Vollover 30 Mar, 2012
Hi There,

I am sorry, 😢 I found this settings under the File Upload (of course) tab at "Full upload Path:" and I changed the directory but it still doesn't work. Now I see the directory is Not Writable.
How can I set it writable? I change it at cPanel/File Manager,(as GreyHead mentioned above) but nothing happened.
GreyHead 30 Mar, 2012
Hi Vollover,

This is a server setting so changing it at CPanel should do what you neeed. You may need to check with your webhost if they have particular requirements. I think mine needs chmod 755 rather than 777.

Sometimes there can also be problems if you have FTP enabled in the Site Global Configuration as then Joomla! will try to use FTP for the file moves and the FTP user doesn't always have the same server permissions :-(

Bob
Vollover 30 Mar, 2012
Thank you GreyHead I got it!! πŸ˜€

I know it is little Offline but it might help to someone esle too.
So at least I put the right Path:
/home/WebhostingUsername/public_html/FolderName/FolderName/etc/
If you put the right Path, "Writable" will show up! πŸ™‚

FTP is off, permissions OK.
One beer...πŸ™‚
This topic is locked and no more replies can be posted.