• 1

Read this first!

We do not monitor these forums. The forum is provided to exchange information and experience with other users ONLY. Forum responses are not guaranteed.

However, please submit a ticket if you have an active subscription and wish to receive support. Our ticketing system is the only way of getting in touch with RSJoomla! and receiving the official RSJoomla! Customer Support.

For more information, the Support Policy is located here.

Thank you!

TOPIC: PHP email script problem

PHP email script problem 12 years 6 months ago #19573

Hello,

I'm having trouble getting the php mail script to work. ideally what i would like is for the information submitted in my form is duplicated in an email both to $admin and $user. however, the support page says that it writes a .txt file to the uploads folder then attaches it to the email, not ideal but a good start.

below is the script that i used intially without success, i get an email saying that there is a submission, so we know the email function is working and a record is working as the submssions appear in the "manage submission in the RS Pro Forms control panel.

later i changed test[/color]'] to the name of my form and still nothing.

i changed the permissions on the folder components/com_rsform/uploads to 777.

if(isset($_POSTtest[/color]'])){
$fp = fopen(JPATH_SITE.'/components/com_rsform/uploads/test.txt', 'w');
$str = '';
foreach($_POST as $component=>$value){
if(is_array($value)) $value = implode(',',$value);
$str.=$component.'='.$value."\r\n";
}
fwrite($fp, $str);
fclose($fp);
$adminEmail[] = JPATH_SITE.'/components/com_rsform/uploads/test.txt';
}

i would have thought that a form to email script was an integral part of internet forms, i'm surprised i am finding this basic function so difficult and that it is not available. having it submitted to the rs form control panel then exporting it to an excel file is not only time consuming but ineffective. Am i missing something?

can anyone see what it is i am doing wrong or shed some light onto this mystery?

cheers stella.
The administrator has disabled public write access.

Re: PHP email script problem 12 years 6 months ago #19588

  • gavindcht
  • gavindcht's Avatar
  • OFFLINE
  • Banned
  • Posts: 63
  • Thank you received: 1
Hi Secretary. Looks like you need to create a support ticket on this.
Deleted code is debugged code.
The administrator has disabled public write access.
  • 1

Read this first!

We do not monitor these forums. The forum is provided to exchange information and experience with other users ONLY. Forum responses are not guaranteed.

However, please submit a ticket if you have an active subscription and wish to receive support. Our ticketing system is the only way of getting in touch with RSJoomla! and receiving the official RSJoomla! Customer Support.

For more information, the Support Policy is located here.

Thank you!