Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
  • 2 commits
  • 6 files changed
  • 0 comments
  • 1 contributor
8 README.md
Source Rendered
@@ -83,11 +83,9 @@ You can use any SMTP server for this, such as [Sendgrid](http://sengrid.com).
83 83 ### Note about Twilio
84 84
85 85 This project is tricky to test locally because Twilio must have a web-accessible
86   -URL for its incoming SMS callbacks. That's why there's an alternate way to vote
87   -by sending an HTTP `GET` to the `/vote/:code/:choiceIndex` route (note: only one
88   -vote per user is enforced). One possibility is to use a proxy service to forward
89   -requests at a remote service to your machine.
90   -
  86 +URL for its incoming SMS callbacks. However, to simulate voting behavior you
  87 +can send fake Twilio [post parameters](http://www.twilio.com/docs/api/rest/sms)
  88 +to the `/SmsResponse` route using `curl`.
91 89
92 90 Running the app
93 91 ---------------
24 public/css/style.css
@@ -54,6 +54,13 @@ p:last-child {
54 54 box-shadow: 0 1px 5px rgba(0,0,0,0.20);
55 55 clear: both;
56 56 }
  57 +footer {
  58 + margin-top: 1em;
  59 +}
  60 +footer,
  61 +footer a {
  62 + color: #666;
  63 +}
57 64 #chart {
58 65 width: 100%;
59 66 height: 400px;
@@ -142,9 +149,24 @@ input[type="submit"].danger {
142 149 input[type="submit"][disabled] {
143 150 background: #ccc;
144 151 }
  152 +#home #sampleGraph {
  153 + position: relative;
  154 + float: right;
  155 + top: -40px;
  156 +}
145 157 #newPoll {
146   - font-size: 1em;
  158 + display: block;
  159 + width: 300px;
  160 + margin: 0 auto;
  161 + margin-top: 20px;
147 162 text-align: center;
  163 + -webkit-box-shadow: 0 1px 5px rgba(0,0,0,0.20);
  164 + -moz-box-shadow: 0 1px 5px rgba(0,0,0,0.20);
  165 + box-shadow: 0 1px 5px rgba(0,0,0,0.20);
  166 +}
  167 +#newPoll h3 {
  168 + font-size: 1.5em;
  169 + margin-bottom: 0;
148 170 }
149 171 #headerNew {
150 172 -webkit-border-radius: 5px;
BIN  public/img/graph.png
24 views/css/style.styl
@@ -76,6 +76,12 @@ p:last-child
76 76 box-shadow 0 1px 5px rgba(0,0,0, .2)
77 77 clear both
78 78
  79 +footer
  80 + margin-top 1em
  81 +
  82 + &, a
  83 + color #666
  84 +
79 85 #chart
80 86 width 100%
81 87 height 400px
@@ -133,10 +139,26 @@ input[type="submit"]
133 139 .btn.inactive, input[type="submit"][disabled]
134 140 background #ccc
135 141
  142 +#home
  143 + #sampleGraph
  144 + position relative
  145 + float right
  146 + top -40px
  147 +
136 148 #newPoll
137   - font-size 1em
  149 + display block
  150 + width 300px
  151 + margin 0 auto
  152 + margin-top 20px
  153 +
138 154 text-align center
139 155
  156 + box-shadow 0 1px 5px rgba(0,0,0,.2)
  157 +
  158 + h3
  159 + font-size 1.5em
  160 + margin-bottom 0
  161 +
140 162 #headerNew
141 163 border-radius 5px
142 164 padding 5px
23 views/home.jade
... ... @@ -1,11 +1,16 @@
1   -h2 Real-time SMS polling
  1 +#home
  2 + h2 Real-time SMS polling
  3 +
  4 + img#sampleGraph(src='/img/graph.png')
  5 +
  6 + p
  7 + | Within 30 seconds, you'll have a new VoteSpry SMS poll created and
  8 + | ready to go.
  9 + p
  10 + | It's that easy.
2 11
3   -p
4   - | VoteSpry lets you put up a poll and start collecting
5   - | feedback instantly. No registration required.
  12 + br
6 13
7   -br
8   -
9   -a.btn#newPoll(href='/new')
10   - h3 Create a poll instantly
11   - p No signup required
  14 + a.btn#newPoll(href='/new')
  15 + h3 Create a poll instantly
  16 + p No signup required
16 views/layout.jade
... ... @@ -1,4 +1,3 @@
1   -!!!
2 1 html
3 2 head
4 3 block head
@@ -23,3 +22,18 @@ html
23 22
24 23 #content!= body
25 24
  25 + footer
  26 + a(href='http://wylieconlon.com') Made by Wylie
  27 + | •
  28 + a(href='https://github.com/wylieconlon/votespry') View source
  29 +
  30 + script(type="text/javascript")
  31 + var _gaq = _gaq || [];
  32 + _gaq.push(['_setAccount', 'UA-3815703-6']);
  33 + _gaq.push(['_trackPageview']);
  34 +
  35 + (function() {
  36 + var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
  37 + ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
  38 + var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
  39 + })();

No commit comments for this range

Something went wrong with that request. Please try again.