public/engine_files
.DS_Store
vendor/plugins/sitealizer/lib/last_update
+public/pictures
end
end
- # add filter to verify that the person working on or looking at
+ # TODO add filter to verify that the person working on or looking at
# something is the owner
- def edit
+ def edit_general_information
@election = Election.find(params[:id])
end
-
- def show
- @sidebar_content = render_to_string :partial => 'progress',
- :locals => { :page => 'review' }
-
- @election = Election.find(params[:id])
- end
-
- def update
+
+ def update_general_information
@election = Election.find(params[:id])
if @election.update_attributes(params[:election])
flash[:notice] = 'Election was successfully updated.'
end
end
+
+ def show
+ @sidebar_content = render_to_string :partial => 'progress',
+ :locals => { :page => 'review' }
+
+ @election = Election.find(params[:id])
+ end
+
def start_election
@election = Election.find(params[:id])
@election.voters.each do |voter|
@election.candidates << @candidate
if @candidate.save
+ # check to see if they've uploaded a picture
+ if params[:picture][:uploaded_data]
+ picture = Picture.new(params[:picture])
+ @candidate.picture = picture if picture.save
+ end
+
@candidate = Candidate.new
redirect_to :action => 'edit_candidates', :id => @election.id
else
voter = Voter.find( params[:id] )
voter.destroy
end
+
+ def toggle_authenticated
+ @election = Election.find(params[:id])
+ if params[:authenticated] == "1"
+ @election.authenticated = true
+ else
+ @election.authenticated = false
+ end
+ @election.save
+ end
## methods for computing and printing results
####################################################################
require_dependency "election"
def index
- if params[:urlpassword]
+ if params[:election_id]
+ @election = Election.find(params[:election_id])
+ unless @election.authenticated?
+ @voter = Voter.find(:all,
+ :conditions => ["session_id = ? and election_id = ?",
+ session.session_id, @election.id])[0]
+
+ @voter = Voter.new unless @voter
+
+ @voter.election = @election
+ @voter.session_id = session.session_id
+ @password = "open." + @election.id.to_s
+ end
+ elsif params[:urlpassword]
password = params[:urlpassword]
if @voter = FullVoter.find(:all,
:conditions => [ "password = ?", password ] )[0]
+ @election = @voter.election
+ @password = @voter.password
+ end
+ end
- @voter.vote = Vote.new if @voter.vote.nil?
- @voter.vote.set_defaults! if @voter.vote.rankings.empty?
+ if @voter and @election
+ # initialize things if the vote is blank
+ if @voter.vote.nil?
+ @voter.vote = Vote.new
+ @voter.save
+ end
+
+ @voter.vote.set_defaults! if @voter.vote.rankings.empty?
- @election = @voter.election
-
- # if the election is now finished
- if @election.enddate < Time.now
- # compute and display results
-
- @results = @election.results
- @candidates = {}
- @election.candidates.each {|c| @candidates[c.id] = c}
- @names = @election.names_by_id
-
- @sidebar_content = render_to_string(:partial => 'results_sidebar')
- render :action => 'results'
+ # if the election is now finished
+ if @election.enddate < Time.now
+ redirect_to :action => :results, :id => @password
+ else
+ @sidebar_content = render_to_string(:partial => 'vote_sidebar')
+ if @election.embeddable? and params[:embed] == "true"
+ render :template => 'embed/full_vote', :layout => 'embed'
else
- @sidebar_content = render_to_string(:partial => 'vote_sidebar')
render :action => 'full_vote'
end
- elsif params[:urlpassword]
- redirect_to :action => 'index'
end
end
end
def confirm
if authenticate
@voter.vote.confirm!
- render :action => 'thanks'
+
+ if @voter.election.embeddable? and params[:embed] == "true" \
+ and @voter.election.early_results?
+ redirect_to :action => :results, :id => @password, :embed => 'true'
+ else
+ render :action => 'thanks'
+ end
else
redirect_to :action => 'index'
end
end
end
+ def results
+ if authenticate and
+ (@voter.election.early_results? \
+ or @voter.election.enddate < Time.now)
+
+ @election = @voter.election
+ # compute and display results
+
+ @results = @election.results
+ @candidates = {}
+ @election.candidates.each {|c| @candidates[c.id] = c}
+ @names = @election.names_by_id
+
+ @sidebar_content = render_to_string(:partial => 'results_sidebar')
+ if @election.embeddable? and params[:embed] == "true"
+ render :template => 'embed/results', :layout => 'embed'
+ else
+ render :action => 'results'
+ end
+ else
+ redirect_to :action => 'index'
+ end
+ end
private
def authenticate
password = params[:id]
- @voter = FullVoter.find(:all, :conditions => [ "password = ?", password ] )[0]
+ if password == "open"
+ election = Election.find(params[:format])
+ unless election.authenticated?
+ @voter = Voter.find(:all,
+ :conditions => ["session_id = ? and election_id = ?",
+ session.session_id, election.id])[0]
+ @password = "open." + election.id.to_s
+ end
+ else
+ @voter = FullVoter.find(:all,
+ :conditions => [ "password = ?", password ] )[0]
+ @password = @voter.password
+ end
+ @voter
end
end
reasons << "You must have at least two candidates."
end
- if self.voters.length <= 1
+ if self.voters.length <= 1 and self.authenticated?
reasons << "You must have at least two voters."
end
active == 2
end
+ def authenticated?
+ authenticated
+ end
+
def shortdesc
shortdesc = description.split(/\n/)[0]
end
has_attachment :storage => :file_system,
:max_size => 1.megabytes,
- :thumbnails => { :thumb => '70x53>' },
+ :thumbnails => { :thumb => '70x53' },
:processor => :Rmagick
validates_as_attachment
super
token_generator = UniqueTokenGenerator.new( 16 )
- until not token.empty? and Token.find(:all, :conditions => [ "token = ?", token ]).empty?
+ until not token.empty? and Token.find(:all, :conditions => [ "token = ?", token ]).empty? and token[0..3] != "open"
self.token = token_generator.token
end
rankings.each { |ranking| ranking.destroy }
end
- def settime
- self.time = Time.now
- self.save
- end
-
def confirm!
self.confirmed = 1
+ self.time = Time.now
self.save
unless self.voter.election.quickvote?
# too. It creates a vote with the candidates listed in order of preference
# based on alphabetical order. Meant to be manipulated and then confirmed
def set_defaults!
- self.votes = voter.election.candidates.sort.collect {|c| c.id }
+ self.votes = self.voter.election.candidates.sort_by { rand }.collect {|c| c.id }
self.save
end
--- /dev/null
+<div class="candidate_box_info">
+ <% if @current_candidate.picture %>
+ <div class="candidate_box_picture">
+ <img src="<%= url_for @current_candidate.picture.public_filename(:thumb) %>" />
+ </div>
+ <% end %>
+ <div class="candidate_box_description">
+ <% if @current_candidate.description.length > 0 %>
+ <%= h(@current_candidate.description) %>
+ <% else %>
+ <!-- no description -->
+ <% end %>
+ </div>
+ <div class="clear-div"></div>
+</div>
<p style="float: left;"><label for="candidate_picture">Picture</label> (optional and < 100x100 pixels)<br />
-<%= file_field :candidate, :picture %></p>
+<%= file_field :picture, :uploaded_data%></p>
<div class="clear-div"></div>
<br />
<div style="display: none;" id="candidate_description_<%= @current_candidate.id %>">
- <%=h (@current_candidate.description) %>
+ <%= render :partial => 'candidate_box_info' %>
</>
</span>
</li>
<div class="candidate_box" id="cand<%= @current_candidate.id %>">
- <div class="candidate_box_name"><%=h @current_candidate.name %></div>
+ <div class="candidate_box_name">
+
+ <%=h @current_candidate.name %></div>
<div class="candidate_box_menu">
<%= link_to_remote "Delete",
:complete => "Element.remove('cand#{@current_candidate.id}')",
:id => @current_candidate.id } %>
</div>
<div class="clear-div"></div>
-
- <div class="candidate_box_info">
- <div class="candidate_box_picture">
- <% if @current_candidate.picture? %>
- <img src="<%= url_for :action => 'candidate_picture',
- :id => @current_candidate.id %>" />
- <% end %>
- </div>
- <div class="candidate_box_description">
- <% if @current_candidate.description.length > 0 %>
- <%= h(@current_candidate.description) %>
- <% else %>
- <!-- no description -->
- <% end %>
- </div>
- <div class="clear-div"></div>
- </div>
+ <%= render :partial => 'candidate_box_info' %>
</p>
</div>
<!--[form:election]-->
<p><label for="election_name">Title</label><br/>
-<%= text_field 'election', 'name', :size => 60 %></p>
+<%= text_field :election, :name, :size => 60 %></p>
<p><label for="election_description">Description</label><br/>
-<%= text_area 'election', 'description', :rows => 5, :cols => 60 %></p>
+<%= text_area :election, :description, :rows => 5, :cols => 60 %></p>
<!--
<p><label for="election_anonymous">Anonymous Vote</label>
-<%= check_box 'election', 'anonymous', {}, 1, 0 %></p>
+<%= check_box :election, :anonymous, {}, 1, 0 %></p>
<p>Election/Voting Start Date<br />
<%= datetime_select :election, :startdate %></p>
<% type_hash = {}; ELECTION_TYPES.each {|k,v| type_hash[v] = k} %>
<%= select_tag 'election[election_method]', options_for_select(type_hash, @election.election_method) %></p>
+<p><label for="election_election_method">Enable Embeddable Elections?</label>
+<%= check_box :election, :embeddable %></p>
+
+<p><label for="election_election_method">Should results be visible before end of election?</label>
+<%= check_box :election, :early_results%></p>
<!--[eoform:election]-->
-->
<%= hidden_field :raw_voter_list, :email, :value => 2 %>
</p>
-
<p><%= submit_tag "Add Voters" %></p>
+
+++ /dev/null
-<h1><strong><%=h @election.name %>:</strong> Edit Overview</h1>
-
-<% form_tag(:action => 'update', :id => @election) do %>
- <%= render :partial => 'overview_form' %>
- <%= submit_tag 'Done!' %>
-<% end %>
--- /dev/null
+<div id="title-header">
+ <span class="header">Election Overview</span>
+ <span class="subheader"></span>
+</div>
+
+<% form_tag(:action => 'update_general_information', :id => @election) do %>
+ <%= render :partial => 'overview_form' %>
+ <%= submit_tag 'Done' %>
+<% end %>
<span class="subheader"></span>
</div>
+<p id="unauth_notice" <%= 'style="display: none;"' if @election.authenticated %>>Anyone will be able to
+vote in this election.</p>
+
+<div id="voter_info_box" <%= 'style="display: none;"' unless @election.authenticated %>>
<%= render :partial => 'voter_list' %>
<% form_tag (:action => 'edit_voters', :id => @election.id) do %>
<%= render :partial => 'voters_form' %>
<% end %>
+</div>
+
+<%= check_box :election, :authenticated %> Only allow registered voters
+
+<%= observe_field "election_authenticated",
+ :url => { :action => 'toggle_authenticated', :id => @election.id },
+ :complete => 'Element.toggle($("voter_info_box")); Element.toggle($("unauth_notice"));',
+ :with => 'authenticated' %>
+
+<script type="text/javascript">
+</script>
<div class="normal-header">
<span class="header">Continue</span>
<% elsif @election.done? %>
<div id="status">Election is finished. <%= link_to "View results",
:action => 'results', :id => @election.id %>.</div>
+<% else %>
+ <p style="text-align: right;">
+ <%= link_to "Edit General Information",
+ :action => 'edit_general_information', :id => @election.id %>
+ </p>
<% end %>
<p><strong>Summary</strong></p>
<%= h(@election.description) %>
</blockquote>
-<p><strong>End Date</strong></p>
+<p><strong>Additional Information</strong></p>
-<blockquote>
-<%= @election.enddate %>
-</blockquote>
+<ul> <li>Elections will end at <strong><%= @election.enddate
+%></strong>.</li> <li>Elections results <strong><% if
+@election.early_results %>will be<% else %>will not be<% end
+%></strong> will be visible while election is in progress.</li>
-<% unless @election.active %>
-<p><%= link_to "Edit overview.", :action => 'edit', :id => @election.id %></p>
+<% if @election.embeddable %>
+<li>Elections <strong>will be</strong> embeddable.</li>
<% end %>
+</ul>
+
+
<div class="normal-header">
<span class="header">Candidates</span>
<span class="subheader"></span>
</div>
-<% unless @election.candidates.empty? %>
- <%= render :partial => 'candidate_list' %>
- <% unless @election.active %>
- <p><%= link_to "Add, remove, or edit candidates.", :action => 'edit_candidates', :id => @election.id %></p>
- <% end %>
-<% else %>
- <p><em>There are currently no candidates registered. <%= link_to "Add some!", :action => 'edit_candidates', :id => @election.id unless @election.active %></em></p>
+<% if not (@election.active? or @election.done?) %>
+ <p style="text-align: right;">
+ <%= link_to "Edit Candidates",
+ :action => 'edit_candidates', :id => @election.id %></p>
+<% end %>
+
+
+<% if @election.candidates.empty? %>
+ <p><em>There are currently no candidates registered.</em>
+ <%= link_to "Add some!", :action => 'edit_candidates', :id => @election.id %>
+ </p>
+<% else %>
+ <%= render :partial => 'candidate_list' %>
<% end %>
<div class="normal-header">
<span class="subheader"></span>
</div>
-<% unless @election.voters.empty? %>
- <%= render :partial => 'voter_list' %>
- <%= link_to "Add or remove voters.", :action => 'edit_voters', :id => @election.id unless @election.active %></em></p>
+<% if not (@election.active? or @election.done?) %>
+<p style="text-align: right;">
+ <%= link_to "Change Voters/Options",
+ :action => 'edit_voters', :id => @election.id %></p>
+<% end %>
+
+<% if not @election.authenticated? %>
+ <p><em>This election is open the public.</em></p>
+<% elsif @election.voters.empty? %>
+ <p><em>There are currently no voters registered. </em>
+ <%= link_to "Add some!", :action => 'edit_voters',
+ :id => @election.id %></p>
<% else %>
- <p><em>There are currently no voters registered. <%= link_to "Add some!", :action => 'edit_voters', :id => @election.id unless @election.active %></em></p>
+ <%= render :partial => 'voter_list' %>
+ <p><em><%= link_to "Add or remove voters.", :action => 'edit_voters',
+ :id => @election.id unless @election.active? or @election.done? %>
+ </em></p>
<% end %>
-<% unless @election.active? %>
+<% if not (@election.active? or @election.done?) %>
<div class="normal-header">
<span class="header">Start Election</span>
<ul>
<li>The vote will be "frozen" so that further edits to the
candidate list and voting list cannot occur.</li>
+ <% if @election.authenticated? %>
<li>All voters will be emailed notifying them that the vote has
begun and of their unique login token.</li>
+ <% end %>
</ul>
<%= button_to 'Start Election!', :action => 'start_election', :id => @election.id %>
<% end %>
+<% elsif @election.embeddable? %>
+
+<div class="normal-header">
+ <span class="header">Embedding</span>
+ <span class="subheader"></span>
+</div>
+
+
+<p>To embed your election, copy and paste the following code into your
+homepage:</p>
+
+<blockquote>
+<tt><pre><%= h("<iframe src='") + votepassword_url(:urlpassword => "open." + @election.id.to_s) + h("'") + "<br />" + h(" width='330px' height='370px'></iframe>") %></pre></tt>
+</blockquote>
+
<% end %>
--- /dev/null
+<div id="header">
+<img id="header_icon" src="/images/embed_header_icon.png" />
+<h2>Vote Now</h2>
+</div>
+<div id="voting-box">
+
+ <ul id="rankings-list">
+ <% @voter.vote.rankings.each do |ranking| %>
+ <li class="ranking" id="ranking_<%= ranking.candidate.id %>">
+ <img alt="<%= white_list ranking.candidate.name %>"
+ src="<% if ranking.candidate.picture -%>
+ <%= url_for ranking.candidate.picture.public_filename(:thumb) -%>
+ <%- else -%>
+ /images/default_icon.png
+ <%- end %>" />
+ <p class="ranking-info">
+ <strong><%= white_list ranking.candidate.name %></strong><br />
+ <%= white_list ranking.candidate.description %></p>
+ </li>
+ <% end %>
+ </ul>
+
+ <div style="clear:both;"></div>
+
+ <div id="voting-bottom">
+ <div id="container">
+ <a href="<%= url_for :action => :confirm, :id => @password, :embed => 'true' %>"><h2 id="submit_vote_button">Submit Vote</h2></a>
+ <p><b>Drag and drop</b> to rank your favorite videos</p>
+ </div>
+ </div>
+</div>
+
+<%= sortable_element 'rankings-list',
+ :url => { :action => "sort_candidates", :id => @voter.vote.id } %>
+
--- /dev/null
+<div id="header">
+<img id="header_icon" src="/images/embed_header_icon.png" />
+<h2>Current Standings</h2>
+</div>
+<div id="voting-box">
+
+ <ul id="rankings-list">
+ <% @election.ssd_result.ranked_candidates.flatten.each do |ranking_id| %>
+ <% ranking = @candidates[ranking_id] %>
+ <li class="ranking" id="ranking_<%= ranking.id %>">
+ <img alt="<%= white_list ranking.name %>"
+ src="<% if ranking.picture -%>
+ <%= url_for ranking.picture.public_filename(:thumb) -%>
+ <%- else -%>
+ /images/default_icon.png
+ <%- end %>" />
+ <p class="ranking-info">
+ <strong><%= white_list ranking.name %></strong><br />
+ <%= white_list ranking.description %></p>
+ </li>
+ <% end %>
+ </ul>
+
+ <div style="clear:both;"></div>
+
+ <div id="results-bottom">
+ <div id="container">
+ <a href="<%= votepassword_url :urlpassword => "open." + @voter.election.id.to_s, 'embed' => 'true' %>"><h2>Results</h2></a>
+
+ <p>Your vote was recorded correctly.</p>
+
+ </div>
+ </div>
+</div>
+
+
--- /dev/null
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
+ <title>Selectricity</title>
+ <%= stylesheet_link_tag "embed", :media => "all" %>
+ <%begin%>
+ <%= stylesheet_link_tag "ie6hacks", :media => "all" if
+ request.user_agent =~ /msie\s(5\.[5-9]|[6]\.[0-9]*).*(win)/i %>
+ <%rescue NoMethodError%>
+ <%end%>
+ <%= javascript_include_tag "prototype", "effects", "dragdrop", "controls" %>
+ </head>
+
+ <body>
+ <%= @content_for_layout %>
+ </body>
+
+</html>
<h2>Details</h2>
-<p><%= link_to "Auditing Information", { :action => 'details', :id => @voter.password }, :popup => [] %></p>
+<p><%= link_to "Auditing Information", { :action => 'details', :id => @password }, :popup => [] %></p>
least preferred. Please list <em>all</em> choices in every vote.
<em>(For example, 123 or 321 or 213, etc.)</em></p>
-<%= form_tag :action => 'review', :id => @voter.password %>
+<%= form_tag :action => 'review', :id => @password %>
<%= text_field :vote, :votestring -%>
<%= submit_tag "Vote!" %>
<%= render :partial => 'common/sortable_vote' %>
<div style="margin-left: 30pt;">
-<%= button_to "Submit Vote", :action => 'review', :id => @voter.password %>
+<%= button_to "Submit Vote", :action => 'review', :id => @password %>
</div>
<% @voter.election.candidates.each do |candidate| %>
<% @current_candidate = candidate %>
-
<div id="cand<%= @current_candidate.id %>">
- <h3><%=h @current_candidate.name -%></h3>
- <blockquote>
- <%=h (@current_candidate.description) %>
- </blockquote>
+ <h3><%= h @current_candidate.name %></h3>
+ <%= render :partial => 'election/candidate_box_info' %>
</div>
<% end %>
</ul>
+
<p>Please select from one of the following pages.</p>
<div style="text-align: center;">
- <p><%= button_to 'Confirm This Vote', :action => 'confirm', :id => @voter.password %></p>
+ <p><%= button_to 'Confirm This Vote', :action => 'confirm', :id => @password %></p>
<p>If you choose, you will be able to go back<br />and change it up until
the end of hte voting period.</p>
-
<p><%= button_to 'Discard This Vote', votepassword_url(
- :action => 'index', :urlpassword => @voter.password) %></p>
+ :action => 'index', :urlpassword => @password) %></p>
<p>You will be returned to the voting page to vote<br /> again, if you choose.</p>
map.connect 'voter/:action',
:controller => 'voter',
- :requirements => { :action => /(review|confirm|authenticate|index|login|reminder)/ }
+ :requirements => { :action => /(review|confirm|authenticate|index|login|reminder|results)/ }
+
+ map.voteopen 'voter/open.:election_id',
+ :controller => 'voter',
+ :action => 'index'
map.votepassword 'voter/:urlpassword',
:controller => 'voter',
:action => 'index'
- map.connect 'quickvote/:action/:id',
+ map.connect 'quickvote/:action/(open.)?:id',
:controller => 'quickvote',
:requirements => { :action => /(create|add_candidate|sort_candidates|my_quickvotes)/ }
--- /dev/null
+class AddEmbeddableSupport < ActiveRecord::Migration
+ def self.up
+ add_column :elections, :embeddable, :boolean,
+ :null => false, :default => false
+ add_column :elections, :authenticated, :boolean,
+ :null => false, :default => true
+ add_column :elections, :early_results, :boolean,
+ :null => false, :default => false
+ end
+
+ def self.down
+ remove_column :elections, :embeddable
+ remove_column :elections, :authenticated
+ remove_column :elections, :early_results
+ end
+end
# migrations feature of ActiveRecord to incrementally modify your database, and
# then regenerate this schema definition.
-ActiveRecord::Schema.define(:version => 1) do
+ActiveRecord::Schema.define(:version => 2) do
create_table "candidates", :force => true do |t|
t.column "election_id", :integer, :null => false
t.column "quickuser", :string
t.column "election_method", :string, :limit => 100, :default => "ssd"
t.column "type", :string, :limit => 100, :default => "", :null => false
+ t.column "embeddable", :boolean, :default => false, :null => false
+ t.column "authenticated", :boolean, :default => true, :null => false
+ t.column "early_results", :boolean, :default => false, :null => false
end
add_index "elections", ["user_id"], :name => "fk_user_election"
--- /dev/null
+@charset "utf-8";\r
+/* CSS Document */\r
+\r
+/*****************************************************************************************\r
+ *\r
+ * "Reset Reloaded"\r
+ * Thanks to Eric Meyer\r
+ * http://meyerweb.com/eric/thoughts/2007/05/01/reset-reloaded/\r
+ *\r
+ */\r
+\r
+html, body, div, span, applet, object, iframe,\r
+h1, h2, h3, h4, h5, h6, p, blockquote, pre,\r
+a, abbr, acronym, address, big, cite, code,\r
+del, dfn, em, font, img, ins, kbd, q, s, samp,\r
+small, strike, strong, sub, sup, tt, var,\r
+dl, dt, dd, fieldset, form, label, legend,\r
+table, caption, tbody, tfoot, thead, tr, th, td {\r
+ margin: 0;\r
+ padding: 0;\r
+ border: 0;\r
+ outline: 0;\r
+ font-weight: inherit;\r
+ font-style: inherit;\r
+ font-size: 100%; \r
+ font-family: inherit;\r
+ vertical-align: baseline;\r
+}\r
+\r
+strong, h2, h3 {\r
+ font-weight: bold;\r
+}\r
+\r
+body {\r
+ line-height: 1;\r
+ color: black;\r
+ background: white;\r
+}\r
+\r
+/* tables still need 'cellspacing="0"' in the markup */\r
+table {\r
+ border-collapse: separate;\r
+ border-spacing: 0;\r
+}\r
+\r
+caption, th, td {\r
+ text-align: left;\r
+ font-weight: normal;\r
+}\r
+\r
+blockquote:before, blockquote:after,\r
+q:before, q:after {\r
+ content: "";\r
+}\r
+\r
+blockquote, q {\r
+ quotes: "" "";\r
+}\r
+\r
+\r
+\r
+\r
+\r
+/* GENERIC *****************************************************************************/\r
+\r
+body {\r
+ font-family: helvetica,verdana;\r
+ font-size: 11px;\r
+ color: white;\r
+}\r
+\r
+a {\r
+ color: inherit;\r
+ text-decoration: none;\r
+}\r
+\r
+.submit_vote_button {\r
+ cursor: pointer;\r
+}\r
+\r
+\r
+#header {\r
+ width: 330px;\r
+ height: 53px;\r
+ background: transparent url(/images/embed_basic_bg.png) top left no-repeat;\r
+ margin: 0px;\r
+ padding: 0px;\r
+ overflow: hidden;\r
+}\r
+\r
+#header h2 {\r
+ font-size: 25px;\r
+ margin: 12px 0px 12px 7px;\r
+ color: #FFF;\r
+ font-weight: normal;\r
+}\r
+#header_icon {\r
+ display: float;\r
+ float: right;\r
+}\r
+\r
+\r
+/* VOTING ******************************************************************************/\r
+\r
+#voting-box {\r
+ width: 330px;\r
+ height: 317px;\r
+ background: transparent url(/images/embed_voting_bg.png) top left no-repeat;\r
+ margin: 0px;\r
+ padding: 0px;\r
+ overflow: hidden;\r
+}\r
+\r
+ul {\r
+ margin: 0 0 0 40px;\r
+ padding: 0 0 0 0;\r
+ list-style: none;\r
+}\r
+\r
+.ranking {\r
+ margin: 0px;\r
+ height: 53px;\r
+ overflow: hidden !important;\r
+}\r
+\r
+.ranking img {\r
+ margin: 0 0 0 0;\r
+ padding: 0 0 0 0;\r
+ float: left;\r
+ clear: left;\r
+}\r
+\r
+.ranking-info {\r
+ margin-left: 70px;\r
+ width: 202px;\r
+ height: 23px;\r
+ padding: 11px 6px 13px 6px;\r
+ color: #666666;\r
+ line-height: 1.2em;\r
+ border: 3px solid transparent;\r
+}\r
+\r
+.ranking-info a {\r
+ font-weight: bold;\r
+ color: #666666;\r
+}\r
+\r
+#voting-bottom {\r
+ color: #464646;\r
+ position: absolute;\r
+ top: 318px;\r
+ width: 330px;\r
+}\r
+\r
+#container {\r
+ margin: 0 auto 0 auto;\r
+ width: 90%;\r
+}\r
+\r
+#voting-bottom h2, #results-bottom h2 {\r
+ padding-top: 20px;\r
+ height: 0px;\r
+ width: 119px;\r
+ overflow: hidden;\r
+ float: left;\r
+ margin-top: 16px;\r
+}\r
+\r
+#voting-bottom p, #results-bottom p {\r
+ float: left;\r
+ width: 160px;\r
+ margin-top: 12px;\r
+ margin-left: 10px;\r
+ line-height: 1.3em;\r
+}\r
+\r
+\r
+#voting-bottom h2 {\r
+ background: transparent url(/images/embed_voting_submitvote.png);\r
+}\r
+\r
+#results-bottom h2 {\r
+ background: transparent url(/images/embed_results_changevote.png);\r
+}\r
+\r
+\r
+\r
+\r
+\r
+\r
+\r
+\r
+\r
+\r
+\r
+\r
+\r
+\r
+\r
+\r
+\r
+\r
.candidate_box_info {
margin: 0.5em 0 0.5em 3em;
}
-/*.candidate_box_picture {
- width: 100px;
+.candidate_box_picture {
float: left;
- margin: 0 0.8em 0.5em 0;
-}*/
-.candidate_box_picture img {
- width: 100px;
- border: 1px solid black;
+ margin: 0 0.8em 0.4em 0;
}
.candidate_box_description {
display: inline;