commit | author | age
|
2b49a0
|
1 |
<?php |
812087
|
2 |
ini_set('display_errors',E_ALL); |
FÁ |
3 |
|
2b49a0
|
4 |
include "vendor/autoload.php"; |
FÁ |
5 |
|
812087
|
6 |
define('IS_DEV', (!isset($_SERVER['HTTP_HOST']))); |
2b49a0
|
7 |
define('SITE_ROOT', __DIR__); |
812087
|
8 |
|
FÁ |
9 |
if (IS_DEV) |
|
10 |
{ |
|
11 |
define('OVERLAY_DIR', dirname(__DIR__) . '/esl-overlay/'); |
|
12 |
} |
|
13 |
else |
|
14 |
{ |
|
15 |
define('OVERLAY_DIR', dirname(__DIR__).'/overlays/'); |
|
16 |
} |
2b49a0
|
17 |
|
FÁ |
18 |
$twig = \EOG\Utils\TwigFactory::getEnvironment(SITE_ROOT); |
888906
|
19 |
$s = new \EOG\Models\Stripe(); |
2b49a0
|
20 |
|
812087
|
21 |
$html_content = $twig->render('templates/overlay-base.twig', ['stripe' => $s]); |
2b49a0
|
22 |
|
812087
|
23 |
file_put_contents(OVERLAY_DIR . 'generated.html', $html_content); |
FÁ |
24 |
|
|
25 |
echo OVERLAY_DIR . 'generated.html'; |