This repository has been archived by the owner on Feb 27, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.tpl
161 lines (138 loc) · 6.08 KB
/
index.tpl
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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
<html>
<head>
<title>Answery- a simple webapp for people who like answering questions</title>
<link rel="stylesheet" href="style.css" type="text/css">
<meta charset="UTF-8">
<meta property="og:site_name" content="Answery" />
<meta property="og:image" content="https://answery.herokuapp.com/answery-logo.jpg" />
<meta name="description" content="Answery is a simple webapp for people who like answering random questions but dont really care about the answers.">
<meta name="keywords" content="Answery, cats, dogs, cute, boredom, questions, buzzfeed, colors, countries, random">
<meta name="author" content="Adrian Edwards">
<link rel="apple-touch-icon" href="answery-logo.png">
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
{literal}
<!-- Matomo -->
<script type="text/javascript">
var _paq = _paq || [];
/* tracker methods like "setCustomDimension" should be called before "trackPageView" */
_paq.push(['trackPageView']);
_paq.push(['enableLinkTracking']);
(function() {
var u="//analytics.adriancedwards.com/";
_paq.push(['setTrackerUrl', u+'piwik.php']);
_paq.push(['setSiteId', '2']);
var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0];
g.type='text/javascript'; g.async=true; g.defer=true; g.src=u+'piwik.js'; s.parentNode.insertBefore(g,s);
})();
</script>
<noscript><p><img src="//analytics.adriancedwards.com/piwik.php?idsite=2&rec=1" style="border:0;" alt="" /></p></noscript>
<!-- End Matomo Code -->
{/literal}
</head>
<body>
<h1>Answery</h1>
<p id="subtitle">-a simple webapp for people who like answering random questions-</p>
<ul class="menu">
<li class="link"><a class="menu" href="http://github.com/DeveloperACE/Answery">Source Code</a></li> -
<li class="link"><a class="menu" href="https://github.com/DeveloperACE/Answery/issues/new">Submit Questions/Feedback</a></li>
</ul>
<div class="socialMediaButtons">
{nocache}
{if $reward}
<a class="twitter-share-button" href="https://twitter.com/intent/tweet?text=Answer%20questions%3A%20get%20cats!">Tweet</a>
{else}
<a class="twitter-share-button" href="https://twitter.com/intent/tweet?text={$socialMediaText}">Tweet</a>
{/if}
{/nocache}
<g:plusone></g:plusone>
</div>
<hr>
{nocache}
{if isset($rewardImgPath)}
<h2>Here's your cute reward photo!</h2>
<img id="rewardImg" src="{$rewardImgPath}" />
{else}
<form id="filter" action="." method="post">
Filter out non-unique questions?
<input type="radio" name="filterBoringQuestions" value="1" {if isset($filterBoringQuestions) and $filterBoringQuestions eq 1}checked{/if}>yes</input>
<input type="radio" name="filterBoringQuestions" value="0" {if isset($filterBoringQuestions) and $filterBoringQuestions eq 0}checked{/if}>no</input>
{if $prefsUpdated}
<input type="submit" value="Saved!" disabled>
{else}
<input type="submit" value="Save Preference">
{/if}
</form>
<h2>{$questionText}</h2>
{if $questionObject->getAnswerType() eq "shortanswer"}
<textarea form="continue" required></textarea>
{elseif $questionObject->getAnswerType() eq "multiplechoice"}
{if $choices[0]->getType() eq "image"}
<form class="multiplechoiceFlex">
{foreach from=$choices key=$key item=$value}
<label class="multiplechoiceIMG"><input type="radio" form="continue" name="multiplechoice" required><img class="multiplechoiceimage" src="{$value->getContent()}"></label><br>
{/foreach}
</form>
{elseif $choices[0]->getType() eq "text"}
<form class="multiplechoice">
{foreach from=$choices key=$key item=$value}
<label class="multiplechoice"><input type="radio" form="continue" name="multiplechoice" required> {$value->getContent()|capitalize}</label><br>
{/foreach}
</form>
{elseif $choices[0]->getType() eq "color"}
<form class="multiplechoiceFlex">
{foreach from=$choices key=$key item=$value}
<label class="multiplechoiceColor"><input type="radio" form="continue" name="multiplechoice" required> <div class="multiplechoiceColor" style="background-color: {$value->getContent()}"></div></label><br>
{/foreach}
</form>
{/if}
{elseif $questionObject->getAnswerType() eq "rating"}
<small>Click the red circles to rate</small>
{if $questionObject->hasSupplementaryImage()}
<img class="rating" src="{$ratingPhoto}" />
{/if}
<form class="rating">
<span class="starRating">
{for $point=1 to 10}
<input form="continue" id="rating{$point}" type="radio" name="rating" value="{$point}" required>
<label for="rating{$point}">{$point}</label>
{/for}
</span>
</form>
{/if}
{/if}
<footer>
<form id="continue" action="." method="post">
{if $reward eq 0}
<input type="hidden" name="reward" value="1">
{elseif reward eq 1}
<input type="hidden" name="reward" value="0">
{/if}
<input type="submit" value="Continue >">
</form>
{if $reward eq 0}
<form id="skip" action=".">
<input type="submit" value="Skip >">
</form>
{/if}
</footer>
{/nocache}
{literal}
<script>window.twttr = (function(d, s, id) {
var js, fjs = d.getElementsByTagName(s)[0],
t = window.twttr || {};
if (d.getElementById(id)) return t;
js = d.createElement(s);
js.id = id;
js.src = "https://platform.twitter.com/widgets.js";
fjs.parentNode.insertBefore(js, fjs);
t._e = [];
t.ready = function(f) {
t._e.push(f);
};
return t;
}(document, "script", "twitter-wjs"));</script>
<script src="https://apis.google.com/js/platform.js" async defer></script>
{/literal}
</body>
</html>