Using cURL to repost to Eloqua data

I'm trying to repost the form data to form Eloqua using PHP cURL.  Based on other examples, I think that I have all the required fields in my string of data, including:

elqFormName

elqSiteID

elqCustomerGUID

elqCookieWrite

CURL PHP code that I use:

$ch = curl_init ("http://now.eloqua.com/e/f2.aspx");

curl_setopt ($ch, CURLOPT_HEADER, 0);

curl_setopt ($ch, CURLOPT_POST, 1);

curl_setopt($ch,CURLOPT_POSTFIELDS,$fields_string);

curl_setopt ($ch, CURLOPT_FAILONERROR, 1);

curl_setopt ($ch, CURLOPT_FOLLOWLOCATION, 0);

curl_setopt ($ch, CURLOPT_REFERER, "http://www.mysite.com");

curl_setopt ($ch, CURLOPT_RETURNTRANSFER, 1);

The call returns this error:

An error occurred during the processing of this form. The information necessary to submit this form was incomplete.

If you submit this form from an e-mail, please open the email in a browser and submit the form again.

What Miss me?  Your help is greatly appreciated.

Jan

Here is an example:

Assume that you have a form on a Web page that submits to your page via PHP form processing POST.

 isset($_POST['firstname']) ? urlencode(trim($_POST['firstname'])) : '',
    'c_lastname' => isset($_POST['lastname']) ? urlencode((trim($_POST['lastname'])) : '',
    'elqFormName' => urlencode("myFormName"),
    'elqSiteID' => urlencode("1234"),
    'elqCustomerGUID' => isset($_POST['elqCustomerGUID']) ? urlencode((trim($_POST['elqCustomerGUID'])) : '',
    'elqCookieWrite' => isset($_POST['elqCookieWrite']) ? urlencode((trim($_POST['elqCookieWrite'])) : ''
);
// stringify the data for the POST
$fields_string = '';
foreach ($fields as $key=>$value)
    $fields_string .= $key.'='.$value.'&';
rtrim($fields_string, '&');
// set curl options and send
$referer = (isset($_SERVER['HTTP_REFERER']) && $_SERVER['HTTP_REFERER'] !== '') ? trim($_SERVER['HTTP_REFERER']) : '';
$ch = curl_init();
if ($referer) {
    $header[] = 'Referer: '.$referer;
    curl_setopt($ch, CURLOPT_HTTPHEADER, $header);
}
curl_setopt($ch, CURLOPT_URL, 'http://now.eloqua.com/e/f2.aspx');
curl_setopt($ch, CURLOPT_POST, count($fields));
curl_setopt($ch, CURLOPT_POSTFIELDS, $fields_string);
curl_setopt($ch, CURLOPT_FAILONERROR, TRUE);
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, FALSE);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE);
curl_exec($ch);
curl_close($ch);

Tags: Marketers

Similar Questions

  • How to use a 2nd partition to store data?

    The 40 GB HDD on my satellite L10 comes with two 20 GB partitions (C and D drive). I understood (by reading this forum) that it is better to use a partition to store the data.

    So far, there was no need to use the D drive. But now I need more space.

    How can I use the folder structure in windows XP home (My Documents, etc.) and the data on the D drive.
    We are working on this computer with multiple accounts.
    I tried to move a folder of My Documents to the D drive, but then is accessed by other users. Use shortcuts to the D drive? I hope there is a simple solution.
    Thanks in advance.
    (I tried my best to write in English...)

    Hello

    Your English is fine :)
    I agree to use the shortcuts to the D drive.
    But if you create a shortcut on the D drive - you must set the appropriate permissions to all users. In the properties of the shortcut, you can find the Security tab. You will find the settings.

    Good bye

  • I used the migration assistant to transfer data from my pc windows for my macbook pro, and it erased all my data. Is he here to retrieve these data

    I used the migration assistant to transfer data from my laptop to windows xp for my macbook pro OS X Yosemite 10.10.5 version and she erased all the data on my mac iTunes i.e., photos, documents, games, etc. Is it possible to recover these data or take it back to a State of pre migration? If not can I erase it and reload the software from scratch?

    Thank you

    Dave has

    You have a backup of Mac before moving the data from the PC?

  • Write to the file of measurement with a loop For using the value of the dynamic data attributes

    I looked and looked, but couldn't find a solution for this.

    I currently have 15 points of different data that I try to write in an Excel file.  I have all combined in a table and lie with the function "write into a file position.  However, the column names are always "Untitled", "Untitled 1" etc.  I then used the function 'Set the Dynamic Data attributes'; but for this I have to do 15 different functions "set data dynamic attributes.  It was suggested to use a loop with the function 'Set the Dynamic Data attributes' inside of her, but I can't find how do.

    I have several arrays consisting of 15 different values for 'Signal Index' 'Name of Signal' and 'Unit', but also a unique 'get Date/Time In Seconds' related to 'Timestamp '.  The problem is that the error I get when I try to connect the output with Scripture at the entrance to measure file:

    The source type is dynamic data table 1 d.  The type of sink is Dynamic Data.

    How can I fix it?  I have attached a picture of my installation; Sorry if this is gross (I'm new on this!).  Thank you!

    It will get rid of the error, but it is not quite correct. What you need to do after that is to click on the output or the tunnel entry and select 'replace with the shift register. In addition, the array of values that you have wired to the Signal Index is wrong. Arrays are 0 based. Just wire the iteration Terminal here. And, finally, take the size of the table and this connection to the N terminal are stupid. Don't wire nothing to this.

  • When purchasing a subscription, if I know that I used to use the product until a certain date in the future, am I able to set up a future subscription start date as a way to not lose all day in the duration of my subscription?

    When purchasing a subscription, if I know that I used to use the product until a certain date in the future, am I able to set up a future subscription start date as a way to not lose all day in the duration of my subscription?

    Not according to the terms and conditions

    Adobe - General conditions of subscription

    Service starts as soon as your first payment is processed.

    Subscribe when you are ready to use it.

  • ColdFusion 11 allows the use of MS Access 32-bit data sources?

    ColdFusion 11 allows the use of MS Access 32-bit data sources?

    Well well, my first rhetorical question: is 2014, why MS Access? MS SQL has free versions that are much faster and more stable than any version of MS Access, I have no problem of migration.

    Now to your question, 32 bit "should not be a factor." 64-bit applications can talk to most 32-bit applications through an API without too much difficulty. The only exception that I know are 32-bit applications that rely exclusively on the DLLs for their API - I don't "think" MS Access has this limitation. It was probably at least 15 years since I touched what whatsoever in dealing with MS Access so my hesitation to be clearer in my response. Good luck.

  • It is advisable to use HTMLDB_COLLECTION for large volume of data pump?

    Hello

    It is advisable to use HTMLDB_COLLECTION for large volume of data pump?
    I need to store records of morethan 1,00,000 on the fly to display in the report.

    Concerning
    Mohan

    Hello

    When you change internal APEX your database object is not supported?
    This means that you can not contact Oracle support.

    Kind regards
    Jari

    http://dbswh.webhop.NET/dbswh/f?p=blog:Home:0

  • Eloqua data extraction for use in the analytical software

    Topliners,

    I use Eloqua 9 and I would like to extract customer information on send individual email so that I can perform trend analyses & regression in analysis tools of data to third parties such as table & SPSS.

    My hope is that I can extract the data from the customer (State / Zip Code / custom fields) and perform only basic e-mail statistics data (sent / open / click / etc...) using the email address as primary key.

    Anyone who has tried to make such a report from Eloqua or used the API to send log extract / rewrite table / customer profile data for using third-party tools?

    Any advice would be greatly appreciated.

    Thank you

    Corey Bauer

    Hi Corey,.

    You can watch export report planned for report admin and those to be transferred by ftp to your server. This will give you the Contact, Email and campaign reports reports.

    Thank you

    Amit

  • Get an Association of Eloqua data profiles in a cloud connector

    Hi Topliner!

    First question and first post so apologies if the wording is a little weak. Anyway,.

    I am developing a new connector of Cloud and Cloud component for Eloqua for my business.

    I want to data of my company in the Eloqua system database. the issue is that im not sure how I would map the data of a Contact. The proof of identity, I can draw from my database is the eloqua of the visitor cookie, but how would approach I mapping to the Eloqua contact in a cloud connector?

    Thanks for the time!

    You have the e-mail address of the contact in your system?  It is the way I see used most often.

    Another way would be to have your cloud component ask the contact ID of the frame.  When your component is rendered, you can use the substitution of parameters, as described here http://topliners.eloqua.com/community/do_it/blog/2012/02/28/building-cloud-components-the-endpoints--renderinstance.  The framework will pass the ID of the Contact (if known) to the person accessing the page.  You'll then have something to put a link on your update of the data.

    Make sense?

  • use of the iPhone's cellular data

    New iPhone for 10 days; discovered that I used almost half my monthly data plan. But in the verification of the system services to see what to use, 751 on 777 MB used are grouped into 'general '. What is general?

    Passed Galaxy, where I did use essentially no data for years. I use just fanatically wireless. How can I better control this? Assist of WiFi was interrupted.

    So, what is "general"?

    Something is really strange about your phone. My 'general' is 70K, 1/3 through my billing cycle. It is usually small to be meaningful.

  • Time Capsule used as EHD: how to encrypt data?

    I have a TC of spare... is no longer used as peripheral regular backup... but I gave stored on it - actually I use it as a DHM.

    (I should sell the TC and get a DHM, perhaps!)

    Access to the TC requires a password of course.

    However. I don't think that my data on the TC is encrypted. While I do not use it as a time Machine (TC is off)... Anyway, I don't see how to encrypt the data.

    Is it possible to encrypt these data? Otherwise, the content of the data is not really secure?

    Any clarification welcome.

    As you probably know, you can encrypt the backups Time Machine, but to encrypt internal hard drive on a Time Capsule, you have essentially two choices:

    1. Remove the hard drive; Install it in a disk enclosure or a caddy and then plug it directly into your Mac. Then use OS X to encrypt the drive.
    2. Without having to remove the disc, create a disc image encrypted on the internal drive of the time Capsule, and then move any content in this image.
  • Use thunderbird on several computers with data on server

    I want to use Thunderbird on my network home/office computers with data on a central computer. For the moment, I need to use mozbackup to transfer data from my desktop computer to laptop, which is a pain.

    Graeme

    As already mentioned, IMAP is the best method, but you can move the profile on the central computer folder and then have TB on each computer pointed to this location using the Profile Manager.

    http://KB.mozillazine.org/Moving_your_profile_folder_-_Thunderbird#Use_the_Profile_Manager_to_move_your_profile

    Another method is to copy a profile on a network share and start TB with command line arguments that specify the profile.

    3rd point: http://kb.mozillazine.org/Synchronizing_mail_on_two_computers

    There is a method of moving just the records of e-mail to another location:

    http://KB.mozillazine.org/Moving_your_mail_storage_location_%28Thunderbird%29

  • Can I repair the BONES using recovery without loss of important data CD?

    I have a problem with my laptop Satellite 1100. The windows OS is somewhat damaged and now won't start. I tried the usual 'use last good config' and boot into "safe mode" but none of these work.

    Is there a way using the product recovery CD to fix this without losing the photos and important documents?

    Any help appreciated.

    Hello

    Restore CD provided you can install new OS. There is no option for any type of repair of the BONE. I don't know how your disk is configured, but if you have 2 partitions, and all your important data is backed up to the second, you can install the OS on the first partition using Expert mode.

    Right now, you can try to get the facilities of Microsoft CD and try to repair the operating system preinstalled.

  • I used windows easy Transfer to transfer data to the new laptop, but the Favorites do not show up. How do I get my old favorites?

    I used Windows easy transfer to move the data from the old to the new laptop. Bookmarks of Firefox has not been transferred. How can I get my old favorites for the new machine? Thank you

    http://support.Mozilla.com/en-us/KB/recovering+important+data+from+an+old+profile

    Your old profile is located here in Windows Vista and Win7:

    drive: \Users\Windows login user name\AppData\Roaming\Mozilla\Firefox\Profiles\profile_name

  • Which driver to use for Satellite A300 - last, by date or version?

    For my laptop (A300-1HV) I'm looking for drivers downloads.

    There are a lot of drivers that have a date LATER change of date, but the LOWER version number.
    Or if you wish, an EARLIER date change date and SUPERIOR version number.

    How do I decide which is the updated driver?

    Thank you.

    How long you use your laptop?
    You have problems with it?
    Is there a reason for update or you do not have the best thing to do?

    Maybe that sounds stupid but I'd like to know why you need it.

Maybe you are looking for

  • Firefox does not work after all, uninstall them and reinstall.

    Very few of the buttons are used in the firefox menu. Add ons will not open the Manager. None of the buttons on the open Help menu, open only a few menu options. Does not work in safe mode. I completely uninstalled, went into effect the deleted data

  • HP Support Assistant v7.7.34.34 problem

    I've recently updated the HP Support Assistant software on my HP ENVY 700-230qe PC (Windows 8.1) of the 7.4.45.4 version to the new version of 7.7.34.34 (such as published on the site of downloads of software and driver for my machine). To enable the

  • Satellite P10-804 - recover to out of box (Windows XP Home Edition)

    Hi friends, this computer has been pre-installed with Windows XP Home Edition. Several years ago, I installed Windows XP Professional. Well I just did a complete installation, return to the publishing house. One of the first things I download WinZip,

  • Going from 8.2 Vision Vision 2011 questions

    Hello I was update a VI wrote with Vision8.2 for the 2011 version.  My main questions were so far a number of broken VI due to different types of connected data set-use the 'cluster from IMAQ image to the image data type' & under 'IMAQ image to the c

  • Comparison table

    Hi all I have 2 tables... I just need to check if the two are same... If even give me a real and not a fake... by using the function "=", I get a table of true/false... what I need is simple just one true if they are equal and not a fake any suggesti