Register for your free account! | Forgot your password?

Go Back   elitepvpers > MMORPGs > Flyff > Flyff Private Server
You last visited: Today at 10:40

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



Gtop100 VotePingBack not working.

Discussion on Gtop100 VotePingBack not working. within the Flyff Private Server forum part of the Flyff category.

Reply
 
Old   #1
 
FlyffDeveloper's Avatar
 
elite*gold: 0
Join Date: Aug 2017
Posts: 187
Received Thanks: 118
Gtop100 VotePingBack not working.

Hello everyone,

I have a problem with my gtop100 voting. And I am not sure where it is going wrong at the moment.

What I have:

The url the player clicks is defined like this:
Code:
<a href="http://www.gtop100.com/topsites/Flyff/sitedetails/mysitehere?vote=1&pingUsername=<?= $_SESSION['user'] ?>" title="Flyff Private Server" target="_blank"><img src="http://www.gtop100.com/images/votebutton.jpg" border="0" alt="Vote Now"></a>
I have tested this and the url properly adds the username in it when click on it.
On gtop100 I have defined this as my pingback url:



This leads to my votepingback url. Which has the following code:
Code:
<?php

 require_once($_SERVER['DOCUMENT_ROOT'].'/Source/Includes/Config.php');

	$voterIP = isset($_POST["VoterIP"]) ? $_POST['VoterIP'] : ''; // voter ip address
	$success = isset($_POST["Successful"]) ? abs($_POST["Successful"]) : 1; // 1 for error, 0 for successful
	$reason = isset($_POST['Reason']) ? $_POST["Reason"] : '';
	$pingUsername = isset($_POST["pingUsername"]) ? $_POST["pingUsername"] : '';
	$postback = isset($_GET['custom']) ? $_GET['custom'] : '';
	
	// GTop 100
	if (!empty($_POST['pingUsername']))
	{
        $controller = new Donate();
        $object = $controller->SetVoteCoins($pingUsername);
	}
	else
	{
        Alert("Not from Gtop100");
	}
?>
Then in the donate controller I have this:
Code:
	public function SetVoteCoins($pingUsername)
	{
		global $cfg;
		$vote = self::Select(array('vcoins', 'lastvote'), 'Website', 'WebAccount', array('username' => $pingUsername));
		$last = $vote['Result'][1]['lastvote'];
		$coins = (int)$vote['Result'][1]['vcoins'];
		
		
	    $nextvote = time()+1*20*60*60;
		$newcoins = $coins + 10;
		
		self::Update(array('vcoins' => $newcoins), array('username' => $pingUsername), 'Website', 'WebAccount');
		self::Update(array('lastvote' => $nextvote), array('username' => $pingUsername), 'Website', 'WebAccount');
		
		//if($last == NULL || $last <= time()){
		//	$nextvote = time()+1*20*60*60;
		//	$newcoins = $coins + 10;
		//	self::Update(array('vcoins' => $newcoins), array('username' => $_SESSION['user']), 'Website', 'WebAccount');
		//	self::Update(array('lastvote' => $nextvote), array('username' => $_SESSION['user']), 'Website', 'WebAccount');
		//	return 'Vote success. Please refresh your panel to see your vote coins.';
		//}else {
		//	return 'Can not vote now. New vote at: ' . date('d.m.Y h:i:s a');
		//}
	}
(The timer check is disabled for testing purposes at the moment).

However when I vote I do not get anything, I can see on my Gtop100 dashboard I have 4x IN but 0x OUT. So its not going out? I don't know exactly what this means or where the error is within the page.
I know that browsing to the url triggers the PHP code.

Any ideas?
FlyffDeveloper is offline  
Old 11/02/2017, 16:18   #2
 
elite*gold: 60
Join Date: Sep 2017
Posts: 424
Received Thanks: 138
What Website do you use ?
Dr. Peacock is offline  
Old 11/02/2017, 17:48   #3
 
FlyffDeveloper's Avatar
 
elite*gold: 0
Join Date: Aug 2017
Posts: 187
Received Thanks: 118
I'm using as my template and building on that or making some small changes where needed.
FlyffDeveloper is offline  
Old 11/06/2017, 07:07   #4
 
FlyffDeveloper's Avatar
 
elite*gold: 0
Join Date: Aug 2017
Posts: 187
Received Thanks: 118
Bumps, any suggestions?
FlyffDeveloper is offline  
Old 11/06/2017, 07:28   #5
 
elite*gold: 32
Join Date: Dec 2015
Posts: 2,275
Received Thanks: 1,113
What is not working? You dont get pingback data? Select query dont work? Update votepoints?

Add on "votepingback url" at the start var_dump($_REQUEST) and look what gtop is sending.

- Verify if its good (probably they do a GET request and u check POST?)

Log your querys for Select and Update and check in MSSQL Studio Managment Client if the Query Syntax are valid.
FlyffServices is offline  
Old 11/06/2017, 08:18   #6
 
FlyffDeveloper's Avatar
 
elite*gold: 0
Join Date: Aug 2017
Posts: 187
Received Thanks: 118
Quote:
Originally Posted by FlyffServices View Post
What is not working? You dont get pingback data? Select query dont work? Update votepoints?

Add on "votepingback url" at the start var_dump($_REQUEST) and look what gtop is sending.

- Verify if its good (probably they do a GET request and u check POST?)

Log your querys for Select and Update and check in MSSQL Studio Managment Client if the Query Syntax are valid.

I know the sql queries work since I tested those. From what I can notice atm is either gtop isn't sending a pingback or the pingback isn't received by my website correctly and im not sure how to check that.


Quote:
- Verify if its good (probably they do a GET request and u check POST?)
This could be plausible, will check.
FlyffDeveloper is offline  
Old 11/06/2017, 08:27   #7
 
xTwiLightx's Avatar
 
elite*gold: 0
Join Date: Jan 2009
Posts: 1,741
Received Thanks: 1,674
You should also check your webserver's access logs to verify that the pingbacks are at least being sent to you.
xTwiLightx is offline  
Old 11/06/2017, 08:42   #8
 
FlyffDeveloper's Avatar
 
elite*gold: 0
Join Date: Aug 2017
Posts: 187
Received Thanks: 118
Quote:
Originally Posted by xTwiLightx View Post
You should also check your webserver's access logs to verify that the pingbacks are at least being sent to you.
It looks like they aren't being sent. I added some code to log $_REQUEST to a file when the pingback page loads/is hit and voted afterwards. The log file wasn't updated.

That and on my Gtop100 Dashboard i have 0 under "OUT". But I have no clue why it wouldn't be sending things.
FlyffDeveloper is offline  
Old 11/06/2017, 08:59   #9
 
elite*gold: 32
Join Date: Dec 2015
Posts: 2,275
Received Thanks: 1,113
Quote:
Originally Posted by FlyffDeveloper View Post
It looks like they aren't being sent. I added some code to log $_REQUEST to a file when the pingback page loads/is hit and voted afterwards. The log file wasn't updated.

That and on my Gtop100 Dashboard i have 0 under "OUT". But I have no clue why it wouldn't be sending things.
You can send me your Teamviewer ID / PIN with a PN and i will take a look into your settings.
FlyffServices is offline  
Reply


Similar Threads Similar Threads
[WTS] Votes for xtremetop100 / wow-private-server.com /gtop100 and and others
11/01/2011 - Trading - 0 Replies
Hello Epvp community im here to offer you my service First of all , this is not a scam, if you are seriously interested in my service i can offer you a free preview of my service votes for xtremetop100.com ( around 300-400 votes per day )
[WTS] Votes for xtremetop100 / wow-private-server.com /gtop100 /gamesites200
11/01/2011 - WoW Private Server - 0 Replies
Hello Epvp community im here to offer you my service First of all , this is not a scam, if you are seriously interested in my service i can offer you a free preview of my service votes for xtremetop100.com ( around 400-600 votes per day )
ALERT = NOT WORKING EDITED Barny - Wallhack NOT Working
12/05/2009 - Soldier Front Hacks, Bots, Cheats & Exploits - 4 Replies
please closed the thread below of this thread... threading that edited barny is working hack,.... its an spam!!!!!



All times are GMT +1. The time now is 10:40.


Powered by vBulletin®
Copyright ©2000 - 2026, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2026 elitepvpers All Rights Reserved.