In accajoom told me to follow these procedures:
http://www.ijoobi.com/index.php?option=com_content&view=article&id=7697&catid=29&Itemid=72/ # url
but I am a newbie and I can not understand what I do, can you help me?
I want one that when complete the form and sends it still loads the page where it says that the shipment of your (I created the page and I put the url of the Form-redirect URLs) and at the same time you register at newwsletter.
Thank you very much
this looks easy, you need this in the form onsubmit code:
$MyForm =& CFChronoForm::getInstance();
$MyForm->setFormData("redirecturl", "index.php?option=com_acajoom&act=subscribe&name=".JRequest::getVar('name_field_name')."&email=".JRequest::getVar('email_field_name')."&listid=2");
change the listid per your acajoom data!
Cheers
Max
Meanwhile thanks for the help but I have some problemino:
I tried to include both in On Submit code - before sending email: that in On Submit code - after sending email:
but I made the recording in the newsletter
I am recording in the newsletter only if I put this code:
http://www. mysite .it/index.php?option=com_acajoom&act=subscribe & name = (name) & email = (email) & listid = 14
redirect url in that I only want that after one has completed the form to be redirected to the confirmation page email delivery occurred
Thanks
Stefano
did my code above work ? did you replace the 2 fields names with real fields names from your form ? name_field_name and email_field_name
Max
Hi Stefano,
did my code above work ? did you replace the 2 fields names with real fields names from your form ? name_field_name and email_field_name
Max
Yes, I put the two values is a (name_field_name) name and the other(email_field_name) is email.
Below we carry forward the code of my form
<table width="470" border="0">
<tr>
<td width="159">Cognome e Nome</td>
<td width="224"><input type="text" name="nome" />*</td>
<td width="178"> </td>
</tr>
<tr>
<td>Indirizzo email</td>
<td><input type="text" name="email" />*</td>
<td> </td>
</tr>
<tr>
<td colspan="3" align="center">Inserisci il codice: {imageverification}</td>
</tr>
<tr>
<td colspan="3" align="center">(non c'è distinzione tra lettere maiuscole e minuscole)</td>
</tr> <tr align="center">
<td colspan="3"><input type="submit" name="Submit" value="Invia" />
* = Campi obbligatori </td>
</tr>
</table>
What you need to do is use a socket to launch 2 URLs at the same time.
So that you can launch one URL to subscribe to Acajoom and you can redirect to the page you desire.
How do I put two in the redirect url?
Thank you
You can't have two 'ReDirect URLs' simply because you can't send the browser to two places at once.
Acajoom also allow a Redirect url though so I suggest that you use a two-step process.
<?php
// Get the ChronoForms data
$MyForm =& CFChronoForm::getInstance();
// Get the base url
$uri_base =& JURI::base();
// Create a new url object
$uri =& JURI::getInstance( $uri_base );
// Set the parameters for the Acajoom subscription
$params = array(
'option' => 'com_acajoom',
'act' => 'subscribe',
'listid' => 14,
'name' => JRequest::getVar('name_field_name'),
'email' => JRequest::getVar('email_field_name'),
'receive_html' => 1,
'redirectlink' => $MyForm->formparams->redirecturl
);
$query = $uri->buildQuery( $params );
$uri->setQuery( $query );
// Set the new ChronoForms ReDirect URL
$MyForm->setFormData( "redirecturl", $uri->toString() );
?>
This all looks a bit more complicated than it is - basically, it sets up a new url with the Acajoom parameters including an instruction to redirect back to the original ChronoForms Redirect URL.
NB: this uses code from the latest ChronoForms releases
NB: not tested and may need de-bugging
Bob
Fatal error: Class 'CFChronoForm' not found in mysite.com/components/com_chronocontact/chronocontact.php(615) : eval()'d code on line 3
Hi riga75,
Which version of ChronoForms do you have installed?
Bob
components: 3.1 RC2
plugin: 0.9/V3.1 RC2
Fatal error: Class 'CFChronoForm' not found in /components/com_chronocontact/chronocontact.php(600) : eval()'d code on line 3
load the form if using the plugin I load the form but to me appears below this text:
. ', Eval ( "if (field.getProperty (' title ')) (fMessage_val_validate_email = field.getProperty (' title');}"); eval (" cfvalidate_ "+ field.getProperty ( 'name')+". add (Validate.Email, (failureMessage: fMessage_val_validate_email) );");) if (field.hasClass ( 'validate-url')) (var fMessage_val_validate_validate_url = 'Please enter a valid URL.'; eval ( "if (field. getProperty ( 'title')) (fMessage_val_validate_validate_url = field.getProperty ( 'title');}"); eval ( "cfvalidate_" + field.getProperty (' name')+". add (Validate.Format, (pattern: / ^ (http | https | ftp): \ / \ / (([A-Z0-9] [A-Z0-9_-] *) (\. [A-Z0-9] [A-Z0-9_-] *)+)(:( \ d +)) \ / • / i, failureMessage: fMessage_val_validate_validate_url) );");) if (field.hasClass ( 'validate-date-au')) (var fMessage_val_validate_date_au = 'Please use this date format: dd / mm / yyyy. For example 17/03/2006 for the 17th of March, 2006. '; Eval ( "if (field.getProperty (' title ')) (fMessage_val_validate_date_au = field.getProperty (' title');}"); eval (" cfvalidate_ "+ field.getProperty ( 'name')+". add (Validate.Format, (pattern: / (0 [1-9] | [12] [0-9] | 3 [01]) [- /. ] (0 [1-9] | 1 [012]) [- /.] (19 | 20) \ d \ d /, failureMessage: fMessage_val_validate_date_au) );");) if (field.hasClass ( 'validate-currency dollar-')) (var fMessage_val_validate_currency_dollar =' Please enter a valid $ amount. For example $ 100.00. ', Eval ( "if (field.getProperty (' title ')) (fMessage_val_validate_currency_dollar = field.getProperty (' title');}"); eval (" cfvalidate_ "+ field.getProperty ( 'name') + ". add (Validate.Format, (pattern: / ^ \ $? \ -? ([1-9] (1) [0-9] (0.2) (\, [0-9] (3) ) * (\. [0-9] (0.2 })?|[ 1-9] (1) \ d * (\. [0-9] (0.2)) | 0 (\. [ 0-9] (0.2 })?|( \. [0-9] (1,2 })?)$/, failureMessage: fMessage_val_validate_currency_dollar) );");) Validate.One_Required = function (elm, paramsObj ) (var paramsObj = paramsObj | | (); var message = paramsObj.failureMessage | | "Must Choose one"; var ready = false; var elm = paramsObj.elm; var p = elm.parentNode; var options = p.getElementsByTagName ( 'INPUT'); for (i = 0; 1) field.options [0]. selected = true; eval ( "if (field.getProperty ( 'title')) (fMessage_val_validate_one_required = field.getProperty ( 'title' );}") eval ( "var cfvalidate_" + field.getProperty ( 'name'). ('[]', replace'')+" = new LiveValidation (field, (validMessage: '', insertAfterWhatNode: field.parentNode });"); eval ( "cfvalidate_" + field.getProperty ( 'name'). ('[]', replace'')+". add (Validate.One_Required, (elm: field, failureMessage: fMessage_val_validate_one_required)) ");)))), $ ES ( 'select', $ ( 'ChronoContact_HomePage')). each (function (field) (eval (" var cfvalidate_ "+ field.getProperty ( 'name'). replace ( ' [] ','')+" = new LiveValidation (field, (validMessage:' '});"); if (field.hasClass (' validate-selection ')) (var fMessage_val_validate_selection =' Please make a selection '; if (field.size> 1) field.options [0]. selected = true; eval ( "if (field.getProperty ( 'title')) (fMessage_val_validate_selection = field.getProperty ( 'title');}"); eval ( "cfvalidate_" + field.getProperty ( 'name'). ('[]', replace'')+". add (Validate.Presence, (failureMessage: fMessage_val_validate_selection) );");))), $ ES ( 'textarea', $ ( 'ChronoContact_HomePage')). each (function (field) (eval ( "var cfvalidate_" + field.getProperty ( 'name'). ('[]', replace'')+" = new LiveValidation (field, (validMessage: '' });"); if (field.hasClass ( 'required')) (var fMessage_val_required = 'This field is required', eval ( "if (field.getProperty ( 'title')) fMessage_val_required = (field.getProperty ( 'title');}") eval ( "cfvalidate_" + field.getProperty (' name '). ('[]', replace'')+". add (Validate.Presence, ( failureMessage: fMessage_val_required) );");)));));
Have you updated the ChronoForms component to the latest RC 4.11 release?
Bob
Hi riga75,
Have you updated the ChronoForms component to the latest RC 4.11 release?
Bob
yes and the bot V3.1 RC4.11
other problem:
load the form if using the plugin I load the form but to me appears below this text:
. ', Eval ( "if (field.getProperty (' title ')) (fMessage_val_validate_email = field.getProperty (' title');}"); eval (" cfvalidate_ "+ field.getProperty ( 'name')+". add (Validate.Email, (failureMessage: fMessage_val_validate_email) );");) if (field.hasClass ( 'validate-url')) (var fMessage_val_validate_validate_url = 'Please enter a valid URL.'; eval ( "if (field. getProperty ( 'title')) (fMessage_val_validate_validate_url = field.getProperty ( 'title');}"); eval ( "cfvalidate_" + field.getProperty (' name')+". add (Validate.Format, (pattern: / ^ (http | https | ftp): \ / \ / (([A-Z0-9] [A-Z0-9_-] *) (\. [A-Z0-9] [A-Z0-9_-] *)+)(:( \ d +)) \ / • / i, failureMessage: fMessage_val_validate_validate_url) );");) if (field.hasClass ( 'validate-date-au')) (var fMessage_val_validate_date_au = 'Please use this date format: dd / mm / yyyy. For example 17/03/2006 for the 17th of March, 2006. '; Eval ( "if (field.getProperty (' title ')) (fMessage_val_validate_date_au = field.getProperty (' title');}"); eval (" cfvalidate_ "+ field.getProperty ( 'name')+". add (Validate.Format, (pattern: / (0 [1-9] | [12] [0-9] | 3 [01]) [- /. ] (0 [1-9] | 1 [012]) [- /.] (19 | 20) \ d \ d /, failureMessage: fMessage_val_validate_date_au) );");) if (field.hasClass ( 'validate-currency dollar-')) (var fMessage_val_validate_currency_dollar =' Please enter a valid $ amount. For example $ 100.00. ', Eval ( "if (field.getProperty (' title ')) (fMessage_val_validate_currency_dollar = field.getProperty (' title');}"); eval (" cfvalidate_ "+ field.getProperty ( 'name') + ". add (Validate.Format, (pattern: / ^ \ $? \ -? ([1-9] (1) [0-9] (0.2) (\, [0-9] (3) ) * (\. [0-9] (0.2 })?|[ 1-9] (1) \ d * (\. [0-9] (0.2)) | 0 (\. [ 0-9] (0.2 })?|( \. [0-9] (1,2 })?)$/, failureMessage: fMessage_val_validate_currency_dollar) );");) Validate.One_Required = function (elm, paramsObj ) (var paramsObj = paramsObj | | (); var message = paramsObj.failureMessage | | "Must Choose one"; var ready = false; var elm = paramsObj.elm; var p = elm.parentNode; var options = p.getElementsByTagName ( 'INPUT'); for (i = 0; 1) field.options [0]. selected = true; eval ( "if (field.getProperty ( 'title')) (fMessage_val_validate_one_required = field.getProperty ( 'title' );}") eval ( "var cfvalidate_" + field.getProperty ( 'name'). ('[]', replace'')+" = new LiveValidation (field, (validMessage: '', insertAfterWhatNode: field.parentNode });"); eval ( "cfvalidate_" + field.getProperty ( 'name'). ('[]', replace'')+". add (Validate.One_Required, (elm: field, failureMessage: fMessage_val_validate_one_required)) ");)))), $ ES ( 'select', $ ( 'ChronoContact_HomePage')). each (function (field) (eval (" var cfvalidate_ "+ field.getProperty ( 'name'). replace ( ' [] ','')+" = new LiveValidation (field, (validMessage:' '});"); if (field.hasClass (' validate-selection ')) (var fMessage_val_validate_selection =' Please make a selection '; if (field.size> 1) field.options [0]. selected = true; eval ( "if (field.getProperty ( 'title')) (fMessage_val_validate_selection = field.getProperty ( 'title');}"); eval ( "cfvalidate_" + field.getProperty ( 'name'). ('[]', replace'')+". add (Validate.Presence, (failureMessage: fMessage_val_validate_selection) );");))), $ ES ( 'textarea', $ ( 'ChronoContact_HomePage')). each (function (field) (eval ( "var cfvalidate_" + field.getProperty ( 'name'). ('[]', replace'')+" = new LiveValidation (field, (validMessage: '' });"); if (field.hasClass ( 'required')) (var fMessage_val_required = 'This field is required', eval ( "if (field.getProperty ( 'title')) fMessage_val_required = (field.getProperty ( 'title');}") eval ( "cfvalidate_" + field.getProperty (' name '). ('[]', replace'')+". add (Validate.Presence, ( failureMessage: fMessage_val_required) );");)));));
this problem you can see here:
http://www.tregima.it/
I suspect this may be because you have the Joomla email cloaking plugin turned on and it's trying to hide the example email in the validation warning message. Please try turning email cloaking off.
Bob
Hi riga75,
I suspect this may be because you have the Joomla email cloaking plugin turned on and it's trying to hide the example email in the validation warning message. Please try turning email cloaking off.
Bob
I disabled the plugin and the error message is gone .... sei un grande, grazie mille
For the other problem: I have rejected, but nothing has changed, give me a blank page (this one: http://www.tregima.it/index.php?option=com_chronocontact&task=send&chronoformname=Provapernewsletter) but not recording in the newsletter.
Aid recommendations?
Thank you again for the availability
Sorry but I can't understand where is the new problem right now, when do you get this blank page ?
Max
Hi riga75,
Sorry but I can't understand where is the new problem right now, when do you get this blank page ?
Max
when I send the form he gives me the blank page, if you want to test this is the form:
http://www.tregima.it/component/option,com_chronocontact/chronoformname,Provapernewsletter/lang,it/
That's completely normal.
If you want the page to show something add PHP+HTML in one of the OnSubmit Boxes.
Bob
On Submit code - before sending email:
the following code:
<?php
// Get the ChronoForms data
$MyForm =& CFChronoForm::getInstance();
// Get the base url
$uri_base =& JURI::base();
// Create a new url object
$uri =& JURI::getInstance( $uri_base );
// Set the parameters for the Acajoom subscription
$params = array(
'option' => 'com_acajoom',
'act' => 'subscribe',
'listid' => 14,
'name' => JRequest::getVar('nome'),
'email' => JRequest::getVar('email'),
'receive_html' => 1,
'redirectlink' => $MyForm->formparams->redirecturl
);
$query = $uri->buildQuery( $params );
$uri->setQuery( $query );
// Set the new ChronoForms ReDirect URL
$MyForm->setFormData( "http://www.mysite.com", $uri->toString() );
?>
where mistake?
Ah, you are using a redirect to AcaJoom, so presumably the blank page is showing up after you leave acajoom. I thought that you could set a redirect for acajoom to go to a 'Thank you for subscribing' page?
Bob
and more specifically this piece of code?
// Set the new ChronoForms ReDirect URL
$MyForm->setFormData( "http://www.mysite.com", $uri->toString() );
?>
I'm kind of lost about what the problem we are dealing with now is??
Bob
$MyForm->setFormData( "http://www.mysite.com", $uri->toString() );
should be:
$MyForm->setFormData( "redirecturl", $uri->toString() );
Cheers
Max
Hi riga,
$MyForm->setFormData( "http://www.mysite.com", $uri->toString() );
should be:
$MyForm->setFormData( "redirecturl", $uri->toString() );
Cheers
Max
Ops scusa and then where I put the url address where the redirect should do?
Why not insert the data in the newsletter?
using this code:
<?php
// Get the ChronoForms data
$MyForm =& CFChronoForm::getInstance();
// Get the base url
$uri_base =& JURI::base();
// Create a new url object
$uri =& JURI::getInstance( $uri_base );
// Set the parameters for the Acajoom subscription
$params = array(
'option' => 'com_acajoom',
'act' => 'subscribe',
'listid' => 14,
'name' => JRequest::getVar('nome'),
'email' => JRequest::getVar('email'),
'receive_html' => 1,
'redirectlink' => $MyForm->formparams->redirecturl
);
$query = $uri->buildQuery( $params );
$uri->setQuery( $query );
// Set the new ChronoForms ReDirect URL
$MyForm->setFormData( "http://www.mysite.com", $uri->toString() );
?>
and fixing the line I posted inside the onsubmit before or after box, will redirect the form to the correct newsletter link!!Max
http://www.tregima.it/component/option,com_chronocontact/chronoformname,provachrono/lang,it/
Sorry but I have been upgrading the site, please show me the code you have now to make sure everything is ok!
Cheers
Max
http://www.tregima.it/index.php?option=com_chronocontact&task=send&chronoformname=provachrono
and not recorded in the email newsletter
please search for acajoom, I have answered/or seen a post this morning in which a user got it working using the CURL plugin for chronoforms!
Regards
Max
This information is great. I've got a form that captures first name in {F_Name} and last name in {L_Name). Is there anyway to pass first and last name to Acajoom or to concatinate these two values?
Thank you,
Andy
Please search for posts has "acajoom" as the Author, the answer with how + images are there, its also at the Acajoom website somewhere, the link is in that post too!
Regards
Max