Advertisement
Guest User

Untitled

a guest
Nov 19th, 2019
109
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.59 KB | None | 0 0
  1. const request = require('request')
  2. const cheerio = require('cheerio')
  3.  
  4. request('https://www.kickform.com/bundesliga-matchday-tips/', (error,response, html) => {
  5. if(!error && response.statusCode == 200) {
  6.  
  7. const $ = cheerio.load(html);
  8.  
  9. // Bundesliga
  10.  
  11. var Titel = $('div.container').children('h1').text();
  12. var Prozent1 = $('div.first').children('div.prozent').first().text();
  13. var Prozent2 = $('div.second').children('div.prozent').first().text();
  14. var Prozent3 = $('div.third').children('div.prozent').first().text();
  15. var Team1 = $('div.home').children('span.teamname').first().text();
  16. var Team2 = $('div.away').children('span.teamname').first().text(); This works fine
  17. ---------------------------------------------------------------
  18.  
  19.  
  20.  
  21.  
  22. var Team3 = $('div.home').children('span.teamname').siblings().text();
  23. var Team4 = $('div.away').children('span.teamname').siblings().text();
  24. var Team5 = $('div.home').children('span.teamname').siblings().text();
  25.  
  26. I only get a blank info from this vars
  27.  
  28. ;
  29.  
  30.  
  31.  
  32.  
  33.  
  34.  
  35.  
  36. This isnt important
  37. -------------------------------------------------
  38.  
  39. const Discord = require('discord.js')
  40. const client = new Discord.Client
  41. const token = '-----'
  42.  
  43. client.login(token)
  44.  
  45. client.on('ready', () => {
  46. console.log('Logged in as ' + client.user.tag)
  47. })
  48.  
  49. client.on('ready',() => {
  50. console.log('Servers:')
  51. client.guilds.forEach((guild) => {
  52. console.log(' - ' + guild.name )
  53. })
  54. })
  55.  
  56.  
  57.  
  58. client.on('ready', () => {
  59. -----
  60.  
  61.  
  62.  
  63.  
  64. const Bundesliga = new Discord.RichEmbed()
  65. -----
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement