Active
Project:
Simple Payments
Version:
6.x-1.0
Component:
Code
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
23 Jun 2010 at 05:20 UTC
Updated:
18 Aug 2010 at 12:04 UTC
I'm building a module that uses this module to link the payment process to paypal but the simple payment module only redirect to paypal login page without any purchased data posted in.
function paid_advert_payment_form($form_state, $data) {
$vars = array(
'module' => 'paid_advert',
'type' => 'paid_advert type',
'custom' => $data,
'item_name' => 'paid_advert payment',
'no_shipping' => TRUE,
'no_note' => TRUE,
'return' => url('', array('absolute' => TRUE)),
'amount' => 100,
);
$form = simple_payments_paypal_payment_form($vars);
$form['button'] = array(
'#type' => 'button',
'#value' => t('Continue to Paypal'),
);
return $form;
}
What could be the problem here? thanks
Comments
Comment #1
duckzland commentedI got the problem, The form is posting nothing, seems that $vars is not transformed into hidden input element
by modifying adding the line it worked.
Comment #2
jbrown commentedNormally this is handled by the line
It seems to be missing from your simple_payments_paypal_payment_form().
Comment #3
duckzland commentedIt would be helpful if this is added to the guide in the module page. because I build the form using the same method as the description in the module page.
Thanks for this great module btw :)
Comment #4
jbrown commentedI think the problem was just with copy of the module on your site. The line in #2 is already in the module.