Advanced search  

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Pages: 1 [2]   Go Down

Author Topic: Photoshop plugin, IPN, PayPal issue  (Read 27515 times)

0 Members and 1 Guest are viewing this topic.

webhostingelite

  • Coppermine newbie
  • Offline Offline
  • Posts: 19
Re: Photoshop plugin, IPN, PayPal issue
« Reply #20 on: January 20, 2010, 09:44:25 pm »

Thanks Gene, I appreciate your help very much.

That fixed the malformed header when returning from PayPal and I don't get the Internal 500 Server Error anymore.
I don't see the return message and I don't get the 8 second refresh, mine is just going instantly to the regular startup page, the index.php page.

***I made some other changes, so I will put them back and give it another test.

***Any thoughts for other changes I might have to make? I might have to offer you something to fix it for my client!
Logged

Gene-2008

  • Contributor
  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Posts: 188
Re: Photoshop plugin, IPN, PayPal issue
« Reply #21 on: January 20, 2010, 10:21:49 pm »

Note this code checks to see if your server is one on the first list.  If so it uses the 'Refresh: 8; URL=' and appends the url to go to.
If your server is NOT on the list then it picks the 'Location: ' and goes there....

$header_location = (@preg_match('/Microsoft|WebSTAR|Xitami|Unix/', getenv('SERVER_SOFTWARE'))) ? 'Refresh: 8; URL=' : 'Location: ';

The following code determines what happen after receiving the "return" from IPN.

      $redirect = "index.php";
      header($header_location . $redirect);


BTW I do contract work...
Gene
Logged

Stramm

  • Dev Team member
  • Coppermine addict
  • ****
  • Country: 00
  • Offline Offline
  • Gender: Male
  • Posts: 6006
    • Bettis Wollwelt
Re: Photoshop plugin, IPN, PayPal issue
« Reply #22 on: January 22, 2010, 08:42:23 pm »

Good work, thanks for contributing your findings.

BillyWardrop

  • Coppermine newbie
  • Offline Offline
  • Posts: 10
Re: Photoshop plugin, IPN, PayPal issue
« Reply #23 on: March 02, 2010, 04:34:17 pm »

Hi

I've tried adding the $header_location code to my photo_shop_paypal_ipn.php file but it just takes me back to the home page of my gallery. When I click my orders, my image is set to unpaid even though I paid for it.

My Gallery address is http://www.petehumephotography.co.uk/photogallery/


My code is as follows:


   case 'return':

      $header_location = (@preg_match('/Microsoft|WebSTAR|Xitami|Unix/', getenv('SERVER_SOFTWARE'))) ? 'Refresh: 8; URL=' : 'Location: ';
      $redirect = "index.php";
      header($header_location . $redirect);
      pageheader($lang_info, "<META http-equiv=\"refresh\" content=\"15;url=$redirect\">");
      msg_box($lang_photoshop_ipn['success'], $lang_photoshop_ipn['thank_you'], $lang_continue, $redirect);
      pagefooter();
      //foreach ($_POST as $key => $value) { echo "$key: $value<br>"; }

      break;

My website is hosted on Linux shared hosting.

Thanks


Billy
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: Photoshop plugin, IPN, PayPal issue
« Reply #24 on: March 02, 2010, 04:36:48 pm »

Locking. Start a thread of your own please.
Logged
Pages: 1 [2]   Go Up
 

Page created in 0.024 seconds with 20 queries.