Forums

Modify CURL parameters (Ver. 4.0 RC1.9)

Corvino 01 Jul, 2011
Hi,
how can i do to customize pamameters that curl send?
For example in "Params/Fields map" of the CURL action i would make something like this:

firstname="Sir".firstname

or

[Field Name]=([Field Name]*2)

to modify the parameter before it was sent to the destination page.

If it isn't possible, is there an action that can modify field value before CURL Action?
Could i use Custom Code? How can i refer to field value in my code?

Thanks
GreyHead 01 Jul, 2011
Hi Corvino,

As you say, you can edit data using Custom Code action. If you store the results in the $form->data array then you can use them in the same way as data submitted from the form e.g.
$form->data['firstname'] = "Sir".$form->data['firstname'];

$form->data['new_name'] = $form->data['form_name'] * 2;

Then use {firstname} or {new_name} in the cURL parameters.

Bob
Corvino 01 Jul, 2011
Thanks
Take a Guiness or if you like italian beer: Nastro Azzuro ;-)
This topic is locked and no more replies can be posted.