1+ <?php
2+ include 'functions.php ' ;
3+
4+ $ challenges = getChalleges ();
5+
6+ // echo '<pre>';
7+ // print_r( $challenges );
8+ // die();
9+ ?>
10+ <!DOCTYPE html>
11+ <html>
12+ <head>
13+ <title>Fortnite Current Active Challenges</title>
14+ <meta charset="utf-8" />
15+ <meta name="viewport" content="initial-scale=1.0, user-scalable=no" />
16+ <style>
17+ @font-face {
18+ font-family: 'Fortnite';
19+ src: url( 'BurbankBigCondensed-Bold.otf' );
20+ }
21+
22+ body {
23+ font-family: 'Fortnite';
24+ background: #1e1e1e;
25+ color: #fff;
26+ padding: 10px;
27+ }
28+ </style>
29+ </head>
30+ <body>
31+ <div style="margin-bottom:20px;font-size:48px">
32+ <div style="text-transform: uppercase">Fortnite Current Active Challenges</div>
33+ </div>
34+ <div style="width:100%;color:#000;background:#f1ed62;font-size:26px;display:inline-block">
35+ <div style="padding:5px">
36+ <div style="float:left">CHALLEGES</div>
37+ </div>
38+ </div>
39+ <ul style="list-style: none;padding:0px;margin:0px;margin:0px;margin-bottom:20px">
40+ <?php foreach ( $ challenges ['items ' ] as $ challenge ) : ?>
41+ <li style="border:3px solid #363636;padding:10px;margin-top:20px">
42+ <div style="display:inline-block;width:100%;">
43+ <?php foreach ( $ challenge ['metadata ' ] as $ data ) : ?>
44+ <?php if ( 'rewardPictureUrl ' == $ data ['key ' ] ) : ?>
45+ <div style="display:inline-block;float:left">
46+ <img style="display:block;width:50px" src="<?php echo $ data ['value ' ]; ?> " />
47+ </div>
48+ <?php elseif ( 'name ' == $ data ['key ' ] ) : ?>
49+ <div style="font-size:30px;display:inline-block;margin-left:20px;width:calc(100%-100px)">
50+ <?php echo $ data ['value ' ]; ?>
51+ </div>
52+ <?php endif ; ?>
53+ <?php endforeach ; ?>
54+ </div>
55+ </li>
56+ <?php endforeach ; ?>
57+ </ul>
58+ </body>
59+ </html>
0 commit comments