This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* {@inheritdoc} | |
*/ | |
public function start(Request $request, AuthenticationException $authException = null) | |
{ | |
if ($this->options->get('server_url') & $this->options->get('app_url')){ | |
$redirect_uri = str_replace($this->options->get('server_url'), $this->options->get('app_url'), $request->getUriForPath($this->options->get('check_path', ''))); | |
} else { | |
$redirect_uri = $request->getUriForPath($this->options->get('check_path', '')); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!doctype html> | |
<head> | |
<meta charset="utf-8"> | |
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script> | |
... | |
<script src="http://flexpi.com/api/beta/flexpi.min.js"></script> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<body> | |
<script type="text/javascript"> | |
flex.connect({ | |
app_id : 00000 | |
}, function(){ | |
// run code when connection is ready | |
}); | |
</script> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
... | |
}, function(){ | |
// run code when connection is ready | |
$('body button.login').click(function(){ | |
flex.social.facebook.login(function(res){ | |
flex.social.facebook.getUser(function(userData){ | |
console.log(userData); | |
}); | |
}); | |
}) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
... | |
}, function(){ | |
// run code when connection is ready | |
flex.social.browserid.init(); | |
$('.loginPage #browserid').click(function(){ | |
flex.social.browserid.login(function(result, data, assertion) { | |
if(result === true) { | |
// result == { | |
// "status": "okay", | |
// "email": "[email protected]", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
... | |
}, function(){ | |
// run code when connection is ready | |
flex.social.gg.init(function(){ | |
$('.loginPage #loginWithGG').click(function(){ | |
flex.social.gg.login(function(res){ | |
console.log('res'); | |
// do something after login | |
}, function(res){ | |
// do something with res after failed login |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
... | |
flex.social.gg.login(function(res){ | |
console.log('res'); | |
// do something after login | |
flex.social.gg.getUser(function(userData){ | |
// do something with userData | |
console.log('Hello' + userData.users[0].label) | |
}); | |
... |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
... | |
flex.badges.badge.get('badge_id', function(badgeData){ | |
// do something with badge data in res | |
// console.log(badgeData) | |
}); | |
... |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
... | |
flex.badges.user.set('user_id', 'badge_id', function(res){ | |
// do something with res | |
// console.log(res); | |
}); | |
... |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// newscoop/extensions/test-widget/TestWidget.php | |
<?php | |
class TestWidget extends Widget // implements IWidget class with only render method | |
{ | |
public function render() | |
{ | |
echo 'Test Widget!'; | |
} | |
} |
OlderNewer