Jump to content
Sign in to follow this  
Irin

?Order IP Recorder? with ?PayPal IPN Shopping Cart"

Recommended Posts

Hello,

 

I?ve installed ?Order IP Recorder? contribution. It shows fine when customers paying by Check/Money Order, but it doesn't support ?PayPal IPN Shopping Cart v3.1.5?. Every time somebody orders through PayPal, IP Address and ISP are just blank in admin/orders. Have anybody figured out how to implement this contrib with PayPal IPN Shopping Cart? Any help would be greatly appreciated.

 

Thanks in advance,

Irina.

Share this post


Link to post
Share on other sites

I have the same problem. I think it has to do with the checkout_process.php, but I don't know how to fix it.

 

Please help

Share this post


Link to post
Share on other sites

Well I figured it out thanks for your help *sarcasm* lol

 

Anyway, In PayPal shopping Cart IPN:

 

/includes/modules/payment/paypal/catalog/checkout_process.inc.php

 

ADD:

 

$ip = $_SERVER['REMOTE_ADDR'];

$client = gethostbyaddr($ip);

$str = preg_split("/\./", $client);

$i = count($str);

$x = $i - 1;

$n = $i - 2;

$isp = $str[$n] . "." . $str[$x];

 

BEFORE:

 

$sql_data_array = array('customers_id' => $customer_id,

 

REPLACE: 'currency_value' => $order->info['currency_value'],

 

WITH THIS:

 

'currency_value' => $order->info['currency_value'],

'ipaddy' => $ip,

'ipisp' => $isp);

 

Well this works for me, hope it helps you.

Share this post


Link to post
Share on other sites
Well I figured it out thanks for your help *sarcasm* lol

 

Anyway, In PayPal shopping Cart IPN:

 

/includes/modules/payment/paypal/catalog/checkout_process.inc.php

 

ADD:

 

$ip = $_SERVER['REMOTE_ADDR'];

$client = gethostbyaddr($ip);

$str = preg_split("/\./", $client);

$i = count($str);

$x = $i - 1;

$n = $i - 2;

$isp = $str[$n] . "." . $str[$x];

 

BEFORE:

 

$sql_data_array = array('customers_id' => $customer_id,

 

REPLACE: 'currency_value' => $order->info['currency_value'],

 

WITH THIS:

 

'currency_value' => $order->info['currency_value'],

'ipaddy' => $ip,

'ipisp' => $isp);

 

Well this works for me, hope it helps you.

 

Perfect! Thank you! :thumbsup:

Share this post


Link to post
Share on other sites
Perfect! Thank you! :thumbsup:

I don't know how you got it to work guys, mine doesn't work this way. I'm just getting a tiny black dot in place of IP, that's all. And, no ISP at all. I did exactly like Mike suggested and still not able to get the Order IP info. Any ideas why?

 

Thanks.

Edited by Irin

Share this post


Link to post
Share on other sites
Well I figured it out thanks for your help *sarcasm* lol

 

Anyway, In PayPal shopping Cart IPN:

 

/includes/modules/payment/paypal/catalog/checkout_process.inc.php

 

ADD:

 

$ip = $_SERVER['REMOTE_ADDR'];

$client = gethostbyaddr($ip);

$str = preg_split("/\./", $client);

$i = count($str);

$x = $i - 1;

$n = $i - 2;

$isp = $str[$n] . "." . $str[$x];

 

BEFORE:

 

$sql_data_array = array('customers_id' => $customer_id,

 

REPLACE: 'currency_value' => $order->info['currency_value'],

 

WITH THIS:

 

'currency_value' => $order->info['currency_value'],

'ipaddy' => $ip,

'ipisp' => $isp);

 

Well this works for me, hope it helps you.

 

Hallelujah, finally I found the answer here after spent almost the whole day.

 

Thanks GOD and thanks to you MIKE.

 

(Almost three years since your post, but anyway there is someone still want to say thanks to you)

Share this post


Link to post
Share on other sites

Guys, need your help. After installing this great contribution, I received a Parse error: syntax error, unexpected '<' in my checkout confirmation as below

  echo tep_image_submit('button_confirm_order.gif', IMAGE_BUTTON_CONFIRM_ORDER) . '</form>' . "\n";
<tr>

<td class="main">
<?php echo 
	HEADING_IPRECORDED_1;
	$ip_iprecorded = YOUR_IP_IPRECORDED;
	$isp_iprecorded = YOUR_ISP_IPRECORDED;
		$ip = $HTTP_SERVER_VARS["REMOTE_ADDR"];
	$client = gethostbyaddr($HTTP_SERVER_VARS["REMOTE_ADDR"]);
	$str = preg_split("/\./", $client);
	$i = count($str);
	$x = $i - 1;
	$n = $i - 2;
	$isp = $str[$n] . "." . $str[$x];
?>

 

I think something is missing or wrong closing in between

 

<tr>

<td class="main">

 

I hope any PHP master here can help me solve this as my customer can't check out when this error occur.

 

Your great help is truly appreciated.

Share this post


Link to post
Share on other sites

This code:

 

<tr>

<td class="main">
<?php echo

Probably needs to be:

 

 echo '<tr><td class="main">';

Hard to tell exactly 'cuz you haven't posted enough code to be certain.

:blush:


If I suggest you edit any file(s) make a backup first - I'm not perfect and neither are you.

 

"Given enough impetus a parallelogramatically shaped projectile can egress a circular orifice."

- Me -

 

"Headers already sent" - The definitive help

 

"Cannot redeclare ..." - How to find/fix it

 

SSL Implementation Help

 

Like this post? "Like" it again over there >

Share this post


Link to post
Share on other sites
This code:

 

<tr>

<td class="main">
<?php echo

Probably needs to be:

 

 echo '<tr><td class="main">';

Hard to tell exactly 'cuz you haven't posted enough code to be certain.

:blush:

 

Germ, thank you for the help.. here is the rest of the script

 

<?php

 if (isset($$payment->form_action_url)) {

$form_action_url = $$payment->form_action_url;

 } else {

$form_action_url = tep_href_link(FILENAME_CHECKOUT_PROCESS, '', 'SSL');

 }



 echo tep_draw_form('checkout_confirmation', $form_action_url, 'post');



 if (is_array($payment_modules->modules)) {

echo $payment_modules->process_button();

 }



 echo tep_image_submit('button_confirm_order.gif', IMAGE_BUTTON_CONFIRM_ORDER) . '</form>' . "\n";

<tr>

<td class="main">
<?php echo 
	HEADING_IPRECORDED_1;
	$ip_iprecorded = YOUR_IP_IPRECORDED;
	$isp_iprecorded = YOUR_ISP_IPRECORDED;
		$ip = $HTTP_SERVER_VARS["REMOTE_ADDR"];
	$client = gethostbyaddr($HTTP_SERVER_VARS["REMOTE_ADDR"]);
	$str = preg_split("/\./", $client);
	$i = count($str);
	$x = $i - 1;
	$n = $i - 2;
	$isp = $str[$n] . "." . $str[$x];
?>

Edited by Ariffshah

Share this post


Link to post
Share on other sites

The code I posted should do the trick.

;)


If I suggest you edit any file(s) make a backup first - I'm not perfect and neither are you.

 

"Given enough impetus a parallelogramatically shaped projectile can egress a circular orifice."

- Me -

 

"Headers already sent" - The definitive help

 

"Cannot redeclare ..." - How to find/fix it

 

SSL Implementation Help

 

Like this post? "Like" it again over there >

Share this post


Link to post
Share on other sites

Yes... thanks again Germ... that is the required code.

 

Appreciate your great help

Share this post


Link to post
Share on other sites

Hey guys,

 

i installed the last version, during ordering i can see the ip address, but it is not regestered in de database, i see its just empty.

 

can somone please help?

 

Thank you!

Share this post


Link to post
Share on other sites
Hey guys,

 

i installed the last version, during ordering i can see the ip address, but it is not regestered in de database, i see its just empty.

 

can somone please help?

 

Thank you!

 

 

it only works with an older shopping cart version 3.15..ive also tried the newer paypal ipn carts..didnt work, only got it to work with 3.15

Share this post


Link to post
Share on other sites
it only works with an older shopping cart version 3.15..ive also tried the newer paypal ipn carts..didnt work, only got it to work with 3.15

 

my bad, it works fine with 2.2rc2. just make sure to apply the fix mentioned by dalice

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×