Hi
I using Joomla 1.0.12 and chronoforms 2.3.9
Im using the file upload and its all working except that the file is only been attached to the mail and its not showing the file
when I tried to do it with my joomla 1.5 site it worked....
in the forms HTML I used:
"<td height="26" align="left" valign="middle" class="style1"><input name="Video" type="file" style=" width:220px; height:20px; background:url(http://www.lifehappens.org/images/input_bg.jpg) no-repeat; line-height:19px;border:none 0;" /></td>"
and in the e-mail template I used:
"{Video}"
but nothing is not showing....
you can see the form in action here:
http://www.lifehappens.org/index.php?option=com_chronocontact&chronoformname=essay
how can I prevent from attaching the file and only creating a link to it (I need the form to show the files name)
thanx in advance...
shay
I using Joomla 1.0.12 and chronoforms 2.3.9
Im using the file upload and its all working except that the file is only been attached to the mail and its not showing the file
when I tried to do it with my joomla 1.5 site it worked....
in the forms HTML I used:
"<td height="26" align="left" valign="middle" class="style1"><input name="Video" type="file" style=" width:220px; height:20px; background:url(http://www.lifehappens.org/images/input_bg.jpg) no-repeat; line-height:19px;border:none 0;" /></td>"
and in the e-mail template I used:
"{Video}"
but nothing is not showing....
you can see the form in action here:
http://www.lifehappens.org/index.php?option=com_chronocontact&chronoformname=essay
how can I prevent from attaching the file and only creating a link to it (I need the form to show the files name)
thanx in advance...
shay
Hi shay,
I don't remember v 2.3.9 very well but I think that you have to get the file info from the $attachment array - you can't use the {field_name} syntax.
Bob
I don't remember v 2.3.9 very well but I think that you have to get the file info from the $attachment array - you can't use the {field_name} syntax.
Bob
Hi Bob
Thanx 4 the reply...
since Im new to PHP, could you please help me with the syntax ...
I guess it should be something like
<?php
$attachment = array();
echo(array_values($array));
?>
am I any where close ?!?!
Thanx 4 the reply...
since Im new to PHP, could you please help me with the syntax ...
I guess it should be something like
<?php
$attachment = array();
echo(array_values($array));
?>
am I any where close ?!?!
Hi Shay,
ChronoForms creates the $attachments array for you, if you create a new one you will over-write it.
The sequence here is quite messy.
You need a placeholder in your email template like ##@##, then in the OnSubmit before code create a link for the image and unset the $attachments array
Bob
ChronoForms creates the $attachments array for you, if you create a new one you will over-write it.
The sequence here is quite messy.
You need a placeholder in your email template like ##@##, then in the OnSubmit before code create a link for the image and unset the $attachments array
<?php
$link_1 = "<a href='".$attachments['video']."'>link to video</a>";
str_replace('##@##', $link_1, $html_message;
// repeat for second field
$attachments = array(); // unset the attachment array
?>
Note: done from memory and probably very buggy as 2.3.9 was a while agoBob
WOW now Im really dizzy ?!?!
( or maybe its just the hang over...)
I guess just placing the code you gave me in the "On Submit code - before sending email" is not enough...
I replaced the ##@## with the words "videolink" but its not working (showing me the "videolink" word instead of the video name)
maybe I should ask what to do in the placeholder??
as I said - Im new to PHP
( or maybe its just the hang over...)
I guess just placing the code you gave me in the "On Submit code - before sending email" is not enough...
I replaced the ##@## with the words "videolink" but its not working (showing me the "videolink" word instead of the video name)
maybe I should ask what to do in the placeholder??
as I said - Im new to PHP
(showing me the "videolink" word instead of the video name)
Please show your test results including the file name you tried to upload and the form field name ?
MAx
This topic is locked and no more replies can be posted.