-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
10 changed files
with
101 additions
and
8 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
# Fantasy Premier League Bot | ||
|
||
A bot made for the Facebook messenger platform to track any fantasy team's status on the [fantasy.premierleague.com](https://fantasy.premierleague.com). | ||
|
||
To use the bot click [here](https://m.me/341862696190397). | ||
|
||
For information about using the bot visit the [website](https://fantasy-bot.herokuapp.com/). |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
/** | ||
* Created by jyot on 15/4/17. | ||
*/ | ||
'use strict'; | ||
|
||
exports.getHome = function (req, res, next) { | ||
res.render('home'); | ||
}; |
This file contains 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
This file contains 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
This file contains 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
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
h1, h3, p { | ||
font-family: Montserrat; | ||
} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,8 @@ | ||
const express = require('express'), | ||
appController = require('../lib/controllers/appController'), | ||
router = express.Router(); | ||
|
||
/* GET home page. */ | ||
router.get('/', function (req, res) { | ||
res.json({title: 'Express live bro!'}); | ||
}); | ||
router.get('/', appController.getHome); | ||
|
||
module.exports = router; |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
<!DOCTYPE HTML> | ||
|
||
<html> | ||
<head> | ||
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | ||
|
||
<link rel="stylesheet" href="/stylesheets/home.css" type="text/css"> | ||
<link href='https://fonts.googleapis.com/css?family=Montserrat' rel='stylesheet' type='text/css'> | ||
|
||
<script> | ||
window.fbAsyncInit = function () { | ||
FB.init({ | ||
appId: "1261757857215437", | ||
xfbml: true, | ||
version: "v2.8" | ||
}); | ||
}; | ||
(function (d, s, id) { | ||
let js, fjs = d.getElementsByTagName(s)[0]; | ||
if (d.getElementById(id)) | ||
return; | ||
js = d.createElement(s); | ||
js.id = id; | ||
js.src = "//connect.facebook.net/en_US/sdk.js"; | ||
fjs.parentNode.insertBefore(js, fjs); | ||
}(document, 'script', 'facebook-jssdk')); | ||
</script> | ||
|
||
<title>Fantasy Premier League Bot</title> | ||
</head> | ||
<body> | ||
<div style="margin-left: 5%; margin-right: 5%"> | ||
<h1 style="text-align: center">Fantasy Premier League Bot</h1> | ||
|
||
<p>A Facebook bot to get current team scores and your team ranking for all the leagues your are participating in | ||
with just a single command.</p> | ||
|
||
<p>You only need to submit your team's ID once and the bot will save it for you.</p> | ||
|
||
<p>To start using, obtain your fantasy team's ID by visiting | ||
<a href="https://fantasy.premierleague.com" target="_blank">fantasy.premierleague.com</a> and logging in. After | ||
that | ||
go to the <strong>Points</strong> tab and your team's ID will be visible in the URL in your browser's address | ||
bar. | ||
</p> | ||
|
||
<div style="text-align: center; margin-top: 5%; margin-bottom: 3%"><img style="max-width: 100%" src="/images/team-screenshot.png"></div> | ||
|
||
<p>This is your team's ID. Simply copy it and give it to the bot with the command - <strong>login <TEAM | ||
ID></strong>. In the above case it would be <strong>login 2959370</strong>.</p> | ||
|
||
<p>We do not ask for any personal or sensitive information like email or passwords. Your team's ID is a public ID. | ||
Anyone can view any team by simply putting a team's ID in the form of the URL given in the image. This is | ||
completely | ||
public data.</p> | ||
|
||
<h3 style="text-align: center; margin-top: 5%">Launch the bot - </h3> | ||
|
||
|
||
<div style="text-align: center"> | ||
<div class="fb-messengermessageus" messenger_app_id="1261757857215437" page_id="341862696190397" color="blue" | ||
size="xlarge"></div> | ||
</div> | ||
|
||
<h3 style="text-align: center; margin-top: 5%">Or scan this Messenger code - </h3> | ||
|
||
<div style="text-align: center"><img style="max-width: 100%; max-height: 300px" src="/images/messenger-code.png"> | ||
</div> | ||
|
||
</div> | ||
</body> | ||
</html> |