This repository has been archived by the owner on Sep 22, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 4
/
index.php
55 lines (50 loc) · 1.64 KB
/
index.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
<?php
// PHP SDK Demo App
// Copyright 2017 Optimizely. Licensed under the Apache License
// View the documentation: http://bit.ly/2rfsbxt
include ('process.php');
if(isset($_POST['user_id'])){
$user_id = $_POST['user_id'];
}
?>
<!doctype html>
<html lang="en" class="height--1-1">
<head>
<title>Attic & Button</title>
<!-- Latest compiled and minified OUI stylesheet -->
<link rel="stylesheet" href="https://d2uaiq63sgqwfs.cloudfront.net/8.0.0/oui.css">
<style>
table, th, td, div {
padding: 5px;
}
button {
padding: 8px 15px;
}
</style>
</head>
<body class="background--grey height--1-1">
<div class="flex flex-justified--center soft-quad--ends soft-double--bottom background--faint">
<div class="max-width--large text--center text-align--center align--center">
<img src="images/logo.png" class="width--200 text--center align--middle" align="middle" style="margin-bottom:35px">
<center><h2> Welcome to Attic & Button!</h2></center>
<div align="center">
<form action="index.php" method="post">
<b>Simulate a visitor:</b> <input placeholder="Joe" type="text" name="user_id" value="<?php $user_id ?>">
<input type="submit" value="Shop">
</form>
</div>
</br>
<table style="cellspacing: 10">
<tr>
<?php
$data = getItems($user_id);
$items = $data[0];
$variation = $data[1];
displayItems($items);
?>
<tr height='10'></tr>
</table>
</div>
</div>
</body>
</html>