Paypal issue on new version 4.1

sukhman21

Member
YetiShare User
YetiShare Supporter
Jan 26, 2015
508
3
18
I am testing out the script and i see when i am at upgrade / premium page and click on paypal icon to try making the payment for premium account, it shows me a blank page and there is nothing in the error logs, i see access log shows 200 success but no error and i just see a white page.
Is there supposed to be a update for paypal that we need ??
I have tried updating my old version 4.0.1 on a test server and also did a fresh install and both times, it happened, showed me a blank page...

this is the URL i see on the blank page
http://test.websiteaddress.com/plugins/paypal/site/_pay.php

Can you guys check??
 

sukhman21

Member
YetiShare User
YetiShare Supporter
Jan 26, 2015
508
3
18
okay i got an update on this. Paypal works fine if someone is already logged into their website account but if someone is not logged in, clicking on paypal icon shows a blank page. If it shows a registration page and then once user logs in, if it redirects them back to upgrade page automatically, that would be great...
 

ysmods

New Member
Jan 29, 2013
860
1
0
UK
www.ysmods.com
It already does a check for logged in users

Code:
if (!isset($_REQUEST['user_level_pricing_id']))
{
    coreFunctions::redirect(WEB_ROOT . '/index.html'); 
}

// require login
if (!isset($_REQUEST['i']))
{
    $Auth->requireUser(WEB_ROOT.'/login.'.SITE_CONFIG_PAGE_EXTENSION); //  The check
    $userId    = $Auth->id;
    $username  = $Auth->username;
    $userEmail = $Auth->email;
}
 

adam

Administrator
Staff member
Dec 5, 2009
2,043
108
63
Hi sukhman21,

This is working fine for me when I test it locally. If you're still seeing the problem can you send me access via the support system and I'll take a look directly?

Thanks,
Adam.
 

sukhman21

Member
YetiShare User
YetiShare Supporter
Jan 26, 2015
508
3
18
Thanks for your reply ysmods but i am not sure where this code lives so not sure where to look for this......?

Thanks adam, sent a support request. Please take a look.
 

sukhman21

Member
YetiShare User
YetiShare Supporter
Jan 26, 2015
508
3
18
ysmods, I was trying to look at your website but this is what i get... Not sure why would your website would ban me, this was the first time i visited your website... lolz

Sorry, there is a problem
You are banned from this site.
Error code: 2S160/4
Contact Us
 

ysmods

New Member
Jan 29, 2013
860
1
0
UK
www.ysmods.com
The code shown above is from the top of _pay.php file.

Send me your IP address and I'll remove it from the list of banned IPs, was a different IP that you joined with and one that was caught about 9 months ago by the stop forums spam plugin I have installed.

Never mind I found and removed your IP from the blacklist.

You also have an account on my site :)

sukhman21 Joined: 07/06/2015
 

sukhman21

Member
YetiShare User
YetiShare Supporter
Jan 26, 2015
508
3
18
thanks for the info, i will check the code in that file to see if i can find anything..

I created that account from my test machine however my home IP was the one that was banned. Thanks for removing the ban.
 

sukhman21

Member
YetiShare User
YetiShare Supporter
Jan 26, 2015
508
3
18
okay i have some info

edited that file and changed some info just to make sure the code in it was running

Code:
// require login
if (!isset($_REQUEST['i']))
{
    $Auth->requireUser(WEB_ROOT.'/login.'.SITE_CONFIG_PAGE_EXTENSION);
    $userId    = $Auth->id;
    $username  = $Auth->username;
    $userEmail = $Auth->email;
}
i removed the above lines and changed it to

Code:
// require login
if (!isset($_REQUEST['i']))
{
header("Location: /login.html");
}
else
so now it redirect me to login.html page but ufcourse the variabled are not set ($userid, username and useremail) so it wont actually take me to paypal which is what i was expecting.

Anyways hopefully this will help, just looks like that piece of code isnt working for my site.