Note that there are some explanatory texts on larger screens.

plurals
  1. POintegration of paypal on drupal site
    text
    copied!<p>hi every on I have created paypal integration while registering i.e. paid registration. my code is following in module</p> <pre><code>function paidregistration_user($op, &amp;$edit, &amp;$account, $category = NULL){ switch ($op) { case 'validate': { $paypal = array(); $paypal['cmd'] = '_xclick'; $paypal['business'] = 'sachin.acetechpvtltd@gmail.com'; // doing this here prevents email harvesting $paypal['page_style'] = 'Primary'; $paypal['bn'] = 'PP-DonationsBF'; $paypal['item_name'] = 'Donation'; $paypal['amount'] = '200'; $paypal['currency_code'] = 'USD'; $paypal['no_shipping'] = '1'; $paypal['tax'] = '0'; $paypal['lc'] = 'US'; $paypal['rm'] = '1'; $paypal['return'] = 'http://localhost/drupaldemo/pay'; $paypal['cancel_return'] = 'http://localhost/drupaldemo/user/register'; // Append the Paypal data to the $form_values['submitted_tree'] $data = array_merge($edit, $paypal); // Put the data in a query string $query = http_build_query($data, '', '&amp;'); // Set the URL to Paypal's processing site and append the query string $url = 'https://www.sandbox.paypal.com/cgi-bin/webscr?' .$query; drupal_goto($url); print_r($_REQUEST); // Set the webform's confirmation page to Paypal //$node-&gt;webform['confirmation'] = $url; //drupal_goto();exit; } case 'insert' :{ print_r($_REQUEST); } } } </code></pre> <p>and for success return page </p> <pre><code>function imagemenu_menu() { $items['imagemenu'] = array( 'title' =&gt; 'Add Image', 'type' =&gt; MENU_NORMAL_ITEM, ); $items['pay'] = array( 'title' =&gt; 'Add Image', 'access arguments' =&gt; array('all'), 'page callback' =&gt; 'pay', 'type' =&gt; MENU_NORMAL_ITEM, ); return $items; } function imagemenu_perm() { return array('all'); } function pay() { print_r($_REQUEST); } </code></pre> <p>here every thing is working fine but does not display data returned from paypal.</p> <p>any help will be appriciated Thanks</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload