Forums

Acajoom, post behind the scenes no redirect - SOLVED

datatonic 11 Nov, 2008
First off, great component. I was using Phil-A-Form happily, but as I am now migrating to 1.5, I have found that Joomla Forms lacks many of the essential elements that Phil-A-Form provided.

I have managed to get ChronoForms to display in a module, using the mambot in a content item and then using mod_placehere so that one is sorted.

My problem is as follows:-

I use Acajoom, and I've seen Greyhead's code for redirect, which is great, but I am looking to simply post to the URL but not redirect.

I would like ChronoForms to post the Name and Email to Acajoom and then redirect the user to a content item that thanks them for signing up and tells them to watch out for the authorization email and add us to their safe list etc.

I need this because I use Acajoom sign-up forms on different sites and want to keep them on site after signing up.

Any help much appreciated.

Cheers.
Max_admin 11 Nov, 2008
Hi datatonic,

First, we have a module for Chronoforms V3.0 stable, you can find it in the downloads!

if you need to post form data to more than one url then you may consider using CURL method, I think searching the forums for CURL will bring some useful data! let me know if you didn't manage to find this!

Regards
Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
datatonic 11 Nov, 2008
Many thanks for the quick response.

Shall check out the module thank you for the heads up.

CURL sounds like the way ahead.

I've installed the plugin.

I take it that curl will add the form fields to the URL and will add the & in between them am I right?

Problem now is that the url field for the url won't accept the rest of the url i.e.

/index.php?option=com_acajoom&act=subscribe&receive_html=1&listid=1&

It cuts me off at receive when I try and paste it.

Any pointers much appreciated.

Thanks
Max_admin 12 Nov, 2008
Hi datatonic,

sorry, tell me how are you trying to do the CURL way ? I can't understand what you did!

Regards
Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
datatonic 17 Nov, 2008
Hi there,

I installed the plugin, highlighted the appropriate form and clicked on curl.

I get presented with the name and email field, which obviously I have to match up with acajoom's.

I then tried to paste in the URL with the other "set" parameters into the target URL and it won't paste the whole thing.

Maybe a step by step idiot's guide would help me as I am unfamiliar with CURL.

Thanks

Rowan
GreyHead 17 Nov, 2008
Hi Datatonic,

I'm confused too - what CURL plugin have you installed? We need to be able to copy what you have done here.

Bob
Max_admin 17 Nov, 2008
Hi Bob, there was a CURL plugin for CF here in the forums I made sometime ago, its somewhere and I can't find it quickly, Rowan, can you post the link for the plugin post here please?

@Rowan, do you mean that the URL field in the plugin is not enough to take all the URL for acajoom ? whats the URL you are trying to use for acajoom ? can you show some screenshots too ?

Regards
Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
GreyHead 17 Nov, 2008
Hi Max,

Ah! I missed that - the post is here.

Bob
Max_admin 19 Nov, 2008
ok, attached another version with the target URL field extended!

let me know!

Regards
Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
datatonic 19 Nov, 2008
That did the trick perfectly.

For anyone else that would like to do it here's how.

Firstly download the plugin from the previous post.

Manually install it by putting it in the components/com_chronocontact/plugins/ folder.

Go to Chronoforms administration, forms management.

You will now see a new plugin CURL on the left hand side.



Select the form you wish to use and then click CURL.

In the first screen -



Map your fields.

In the second screen -



Add any additional code you may need - for Acajoom you need none.

In the third screen -



Put in your URL.

Now click on save.

Now go to your form and click on the plugins tab.



Tick the box and use the +/- to set this to 1.

Click on save and test, it should be all working, it is for me!

Many thanks again for your help.

Rowan.
Max_admin 19 Nov, 2008
Thanks Rowan!
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
markcrobinson 16 Apr, 2009
Trying to follow your instructions, based on the info from Salesforce.com.
Here's what I got from them.
Problems:

1 - URL is too long to fit in "Target URL"
https://www.salesforce.com/servlet/servlet.WebToLead?encoding=UTF-8
field truncates after:
https://www.salesforce.com/servlet/servlet.WebToLe

2 - What is considered Extra Code?

3 - where does this information go?
<input type=hidden name="oid" value="00D6000000077D0">
<input type=hidden name="retURL" value="http://www.trinitysolarsystems.com">


FROM SALESFORCE.COM
<!--  ----------------------------------------------------------------------  -->
<!--  NOTE: Please add the following <FORM> element to your page.             -->
<!--  ----------------------------------------------------------------------  -->

<form action="https://www.salesforce.com/servlet/servlet.WebToLead?encoding=UTF-8" method="POST">
<input type=hidden name="oid" value="00D6000000077D0">
<input type=hidden name="retURL" value="http://www.trinitysolarsystems.com">

<label for="salutation">Salutation</label><select  id="salutation" name="salutation"><option value="">--None--</option><option value="Mr.">Mr.</option>
<option value="Ms.">Ms.</option>
<option value="Mrs.">Mrs.</option>
<option value="Dr.">Dr.</option>
<option value="Prof.">Prof.</option>
</select><br>

<label for="first_name">First Name</label><input  id="first_name" maxlength="40" name="first_name" size="20" type="text" /><br>

<label for="last_name">Last Name</label><input  id="last_name" maxlength="80" name="last_name" size="20" type="text" /><br>

<label for="title">Title</label><input  id="title" maxlength="40" name="title" size="20" type="text" /><br>

<label for="company">Company</label><input  id="company" maxlength="40" name="company" size="20" type="text" /><br>

<label for="street">Address</label><textarea name="street"></textarea><br>

<label for="city">City</label><input  id="city" maxlength="40" name="city" size="20" type="text" /><br>

<label for="state">State/Province</label><input  id="state" maxlength="20" name="state" size="20" type="text" /><br>

<label for="zip">Zip</label><input  id="zip" maxlength="20" name="zip" size="20" type="text" /><br>

<label for="phone">Phone</label><input  id="phone" maxlength="40" name="phone" size="20" type="text" /><br>

<label for="mobile">Mobile</label><input  id="mobile" maxlength="40" name="mobile" size="20" type="text" /><br>

<label for="email">Email</label><input  id="email" maxlength="80" name="email" size="20" type="text" /><br>

Type:<select  id="00N60000001W4gA" name="00N60000001W4gA" title="Type"><option value="">--None--</option><option value="Solar-Commercial">Solar-Commercial</option>
<option value="Solar-Residential">Solar-Residential</option>
<option value="Solar-Non-Profit">Solar-Non-Profit</option>
<option value="Solar-Municipal">Solar-Municipal</option>
<option value="HVAC-Commercial">HVAC-Commercial</option>
<option value="HVAC-Residential">HVAC-Residential</option>
<option value="Other">Other</option>
</select><br>
<label for="description">Description</label><textarea name="description"></textarea><br>
<input type="submit" name="submit">
</form>

END SALESFORCE.COM
GreyHead 17 Apr, 2009
Hi Mark,

I don't understand the SalesForce errors but hopefully we can ignore them.

Here are the steps for SalesForce as I understand them (you have already done some of these steps):
[list=A]
  • Install the cf_CURL flugin by copying the cf_CURL.php file to the components/com_chronocontact/plugins folder.
  • Create a new form and paste the form html from SalesForce into the Form HTML box on the Form Code tab.
  • Important: remove the <form . . .> and </form> tag lines from the beginning and end of the code.
  • Save the form.
  • Select the checkbox by the form name in the Form Manager and click the CURL link in the PlugIns list.
  • In the General Tab enter the correct SalesForce field names in the boxes by each field name (in this case they are the same as the ChronoForms names but they don't have to be - we could perhaps add the CF names as a default, I've typed the first few in).
  • Ignore the Submit field and the Extra Fields data (which would let you add some field names for SalesForce that weren't in the CF Form I think).
  • Click the CURL params tab and enter the Target URL https://www.salesforce.com/servlet/servlet.WebToLead?encoding=UTF-8
  • Save the PlugIn parameters and re-open the form.
  • On the PlugIns tab check the CURL Plugin.
  • Save and publish the form and test it (enable debugging in the PlugIn parameters if you need to).
  • [/list:o]
    Bob
    markcrobinson 17 Apr, 2009
    Thank you.
    Your Item H, above, cannot be completed.
    The Target URL entry box in the CURL Params will not accept
    the URL
     https://www.salesforce.com/servlet/servlet.WebToLead?encoding=UTF-8

    It truncates in the middle of the URL.
    GreyHead 17 Apr, 2009
    Hi Mark,

    Open cf_CURL in an editor and look for this code around line 144 (I've edited my version so this won't be exact)
            echo $pane->startPanel( "CURL params", 'curl_params' );
    ?>
    <table border="0" cellpadding="3" cellspacing="0">
        <tr style="background-color: #c9c9c9">
            <td><?php echo JHTML::_('tooltip', "The target URL to post parameters to" ); ?></td>
            <td><strong><?php echo "Target URL"; ?>:</strong></td>
            <td></td>
            <td><input type="text" class="inputbox" size="50"
                name="params[target_url]"
                value="<?php echo $paramsvalues->target_url; ?>" /></td>
        </tr>
    In this line
    <td><input type="text" class="inputbox" size="50"
    change the size to 150

    Bob
    riga75 22 Apr, 2009

    In the second screen -



    Add any additional code you may need - for Acajoom you need none.

    Rowan.



    you could tell me what code you put in the extra code?
    I need the name and the email as well as to redirect the
    Max_admin 22 Apr, 2009
    Hi riga,

    I don't think you need any extra code, please show me a screenshot of the general tab of the plugin, it will have fields for your form fields, where you can add the fields names which Acajoom needs!

    if you can't do this then show me a screenshot of your general tab for the CURL plugin and show me your form code as well!

    Regards
    Max
    Max, ChronoForms developer
    ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
    ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
    markcrobinson 24 Apr, 2009
    Ya - BLAME IT ON THE BROWSER!
    ALready tried:
    Debug in Curl and General - Didn't seem to show debug info
    Remove Validation: no effect
    Remove Image Verification: No effect
    URL: https://www.salesforce.com/servlet and https://www.salesforce.com/servlet?encoding=UTF-8 (No Effect Either Way)
    Calling Bill Gates: No Answer

    Works PERFECTLY in Firefox - Nothing gets transmitted to sales force and no conf email in IE.
    When it works, you get a conf email generated from Salesforce from "Team Trinity"

    Clues?:
    1 - In the Submit URL (dont put anything here unless you know what you are doing) it says
    https://www.salesforce.com/servlet/servlet.WebToLead?encoding=UTF-8" <input type=hidden name="oid" value="00D6000000077D0"> <input type=hidden name="retURL" value="http://www.trinitysolarsystems.com">

    But I didn't put it there.

    2 - Top right of form is a mysterious "> that preceeds the text I have in the form code (begins with <br /><Br />)

    3FYI - flexiblepower.net is a temporary URL. The actual URL will be TrinitySolarSystems.com. If you try it, be careful that you're sending from flexiblepower.net net trinitysolarsystems.com (which it directs to after send)


    Form is at:
    http://flexiblepower.net/index.php?option=com_chronocontact&Itemid=24


    Thanks,
    Mark
    nml375 24 Apr, 2009
    The issue here is "garbage" in the submit url field. This should only contain a proper url (where the form data should be posted). In your case, there's additional html data, causing headaches for the browsers trying to parse the data.

    This is the generated <form>-tag:
    <form name="ChronoContact_contactus" id="ChronoContact_contactus" method="post" action="https://www.salesforce.com/servlet/servlet.WebToLead?encoding=UTF-8" <input type=hidden name="oid" value="00D6000000077D0"> <input type=hidden name="retURL" value="http://www.trinitysolarsystems.com">" >


    You do terminate the action property properly, but you add new html-tags within the form tag as new properties, not as separate elements. Please place those hidden input fields in the Form HTML box instead.

    That is:
    Submit URL:
    https://www.salesforce.com/servlet/servlet.WebToLead?encoding=UTF-8

    Form HTML:
    <input type=hidden name="oid" value="00D6000000077D0">
    <input type=hidden name="retURL" value="http://www.trinitysolarsystems.com">
    ...Rest of form here...


    /Fredrik
    markcrobinson 24 Apr, 2009
    Did the trick - Thanks!

    Recommend moving this to a thread "SalesForce.com Integration"
    riga75 29 Apr, 2009
    My problem is that I want to record in acajoom be made in the list 14 .... where the imposed this parameter?

    this is my screenshot:

    and
    GreyHead 29 Apr, 2009
    Hi riga75,

    Sorry, I don't understand the question?

    Bob
    Max_admin 30 Apr, 2009
    Hi riga,

    the Target URL must be the URL of the Acajoom, you can add to it the variables you need if you can specify a list id!

    Cheers
    Max
    Max, ChronoForms developer
    ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
    ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
    riga75 02 May, 2009
    Nothing to do, give me the usual blank page and does not record anything
    Max_admin 03 May, 2009
    Hi riga,

    ok, lets upgrade to RC5 and retry one more time please, if it didn't work then show me the acajoom post url

    Max
    Max, ChronoForms developer
    ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
    ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
    Max_admin 06 May, 2009
    Hi Stefano,

    I'm going through too many posts now but I think that the solution was posted here after Adrien from the Acajoom team created a new topic with the question and Bob posted the answer! let me know if you can't find this!

    Regards,
    Max
    Max, ChronoForms developer
    ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
    ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
    riga75 06 May, 2009

    Hi Stefano,

    I'm going through too many posts now but I think that the solution was posted here after Adrien from the Acajoom team created a new topic with the question and Bob posted the answer! let me know if you can't find this!

    Regards,
    Max



    Ok thanks 😀
    This topic is locked and no more replies can be posted.