Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
updated for a better user experience
- Loading branch information
1 parent
ea29657
commit 839da66
Showing
16 changed files
with
59 additions
and
206 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -1,5 +1,9 @@ | |||
class User < ActiveRecord::Base | class User < ActiveRecord::Base | ||
acts_as_authentic | acts_as_authentic do |config| | ||
config.validate_email_field = false | |||
config.validate_login_field = false | |||
config.validate_password_field = false | |||
end | |||
|
|
||
include ExampleProfile | include ExampleProfile | ||
end | end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -1,174 +1,14 @@ | |||
|
%h2 Confirm | ||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> | %form.authentication_form{:action => signup_url, :method => :post} | ||
<html> | %fieldset | ||
<head> | / authentication_type should be "user" or "session", based on controller | ||
|
- transfer = case session[:auth_method] | ||
<title>Confirm OpenID - Stack Overflow</title> | - when "oauth" | ||
<link rel="stylesheet" href="http://sstatic.net/so/all.css?v=0554a32b907e"> | - %w(_key _token _secret auth_method oauth_provider) | ||
<link rel="shortcut icon" href="http://sstatic.net/so/favicon.ico"> | - when "openid" | ||
<link rel="apple-touch-icon" href="http://sstatic.net/so/apple-touch-icon.png"> | - %w(auth_method openid_identifier) | ||
<link rel="search" type="application/opensearchdescription+xml" title="Stack Overflow" href="http://sstatic.net/so/opensearch.xml"> | - transfer.each do |hidden| | ||
|
%input{:type => :hidden, :name => hidden.to_sym, :value => session[hidden.to_sym]} | ||
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js"></script> | %input{:type => :hidden, :name => :authentication_type, :value => :user} | ||
|
%input{:type => :text, :name => "user[email]"} | ||
<script type="text/javascript" src="http://sstatic.net/so/js/master.js?v=1efdfca3b527"></script> | %input.submit{:name => :submit, :type => :submit, :value => "Register"}/ | ||
<script type="text/javascript"> | |||
var imagePath='http://sstatic.net/so/img/'; | |||
|
|||
</script> | |||
|
|||
|
|||
</head> | |||
<body class="user-page"> | |||
<noscript><div id="noscript-padding"></div></noscript> | |||
<div id="notify-container"></div> | |||
|
|||
|
|||
<script type="text/javascript"> | |||
$(function() { notify.showFirstTime(); }); | |||
</script> | |||
|
|||
|
|||
<div id="custom-header"></div> | |||
<div class="container"> | |||
<div id="header"> | |||
<div id="topbar"> | |||
<div id="hlinks"> | |||
<span id="hlinks-user"> | |||
|
|||
|
|||
</span> | |||
<span id="hlinks-nav"> | |||
<a href="/users/login?returnurl=%2fusers%2fauthenticate%2f%26dnoa.usersuppliedidentifier%3d%2fprofiles%2flancejpollard%26openid.ns%3d%2fauth%2f2.0%26openid.mode%3did_res%26openid.op_endpoint%3dhttps%3a%2f%2fwww.google.com%2faccounts%2fo8%2fud%3fsource%3dprofiles%26openid.response_nonce%3d2010-05-24t10%3a48%3a55zx5-tosq3ptdjsa%26openid.return_to%3d%2fusers%2fauthenticate%2f%26dnoa.usersuppliedidentifier%3dhttp%25253a%25252f%25252fwww.google.com%25252fprofiles%25252flancejpollard%26openid.assoc_handle%3daoqobucg0dqpx0by92cymtrhfn0h0l3ej7bmsg-ipf4ndtwah-y-wzuu%26openid.signed%3dop_endpoint%2cclaimed_id%2cidentity%2creturn_to%2cresponse_nonce%2cassoc_handle%2cns.ext1%2cext1.mode%2cext1.type.alias4%2cext1.value.alias4%26openid.sig%3djkmixcg3h0pwpmpcvo%2blkncfhyy%3d%26openid.identity%3d%2fprofiles%2flancejpollard%26openid.claimed_id%3d%2fprofiles%2flancejpollard%26openid.ns.ext1%3d%2fsrv%2fax%2f1.0%26openid.ext1.mode%3dfetch_response%26openid.ext1.type.alias4%3d%2fcontact%2femail%26openid.ext1.value.alias4%3dlancejpollard%40gmail.com">log in</a> | |||
<span class="lsep">|</span> | |||
<a href="http://careers.stackoverflow.com/">careers</a> | |||
<span class="lsep">|</span> | |||
|
|||
</span> | |||
<span id="hlinks-custom"> | |||
<a href="/about">about</a> <span class="lsep">|</span> <a href="/faq">faq</a> | |||
</span> | |||
</div> | |||
<div id="hsearch"> | |||
<form id="search" action="/search" method="get"> | |||
<div> | |||
<input name="q" class="textbox" tabindex="1" onfocus="if (this.value=='search') this.value = ''" type="text" maxlength="80" size="28" value="search"> | |||
</div> | |||
</form> | |||
</div> | |||
</div> | |||
<br class="cbt"> | |||
<div id="hlogo"> | |||
<a href="/">Stack Overflow</a> | |||
</div> | |||
<div id="hmenus"> | |||
<div class="nav mainnavs"> | |||
<ul> | |||
<li><a id="nav-questions" href="/questions">Questions</a></li> | |||
<li><a id="nav-tags" href="/tags">Tags</a></li> | |||
<li class="youarehere"><a id="nav-users" href="/users">Users</a></li> | |||
<li><a id="nav-badges" href="/badges">Badges</a></li> | |||
<li><a id="nav-unanswered" href="/unanswered">Unanswered</a></li> | |||
</ul> | |||
</div> | |||
<div class="nav askquestion"> | |||
<ul> | |||
<li id="nav-askquestion" > | |||
<a href="/questions/ask">Ask Question</a> | |||
</li> | |||
</ul> | |||
</div> | |||
</div> | |||
</div> | |||
|
|||
<div id="content"> | |||
|
|||
<div class="subheader"> | |||
<h1>Confirm OpenID</h1> | |||
</div> | |||
<div class="page-description"> | |||
<form id="logout-user" action="/users/openidconfirm" method="post"> | |||
|
|||
<p>This OpenID does not have an account on Stack Overflow yet:</p> | |||
<p class="openid-identifier" style="font-size: 150%">http://www.google.com/profiles/lancejpollard</p> | |||
|
|||
<div> | |||
<input type="hidden" name="fkey" value="94e44e79fc85efa8913d7ceecb9428be"> | |||
<input type="hidden" name="s" value="72a20111-e749-402a-ac2c-109315bb2650"> | |||
<input type="submit" value="Create New Account" style="font-size: 120%"> | |||
<input type="button" value="Cancel" style="font-size: 120%" onclick="window.location.href = 'http://stackoverflow.com/?s=72a20111-e749-402a-ac2c-109315bb2650'"> | |||
</div> | |||
</form> | |||
|
|||
<br> | |||
<p id="help-wrongplace"> | |||
<i>If you think you already have a Stack Overflow account, and you were just trying to associate a new OpenID with an existing Stack Overflow account, <a href="javascript:void(0);" onclick="$('#help-hidden').show();$('#help-wrongplace').hide();">you're in the wrong place</a>.</i> | |||
</p> | |||
<div id="help-hidden" class="dno"> | |||
<p> | |||
You're not logged into Stack Overflow right now. If you have a Stack Overflow account, and you'd like to associate <i>another</i> OpenID with it, here's what to do: | |||
</p> | |||
<ul> | |||
<li><a href="/users/login">Log in</a> in to Stack Overflow with your existing OpenID credentials</li> | |||
<li>Click on your name to go to your user page</li> | |||
<li>Click the <b>change OpenID</b> link on your user page</li> | |||
</ul> | |||
</div> | |||
|
|||
</div> | |||
|
|||
</div> | |||
</div> | |||
<div id="footer"> | |||
<div class="footerwrap"> | |||
<div id="footer-menu"> | |||
<a href="/about">about</a> | | |||
<a href="/faq">faq</a> | | |||
<a href="http://blog.stackoverflow.com/">blog</a> | | |||
<a href="http://itc.conversationsnetwork.org/series/stackoverflow.html">podcast</a> | | |||
<a href="/privacy">privacy policy</a> | | |||
<a href="http://ads.stackoverflow.com/a.aspx?ZoneID=0&BannerID=323&AdvertiserID=5&CampaignID=194&Task=Click&SiteID=1">advertising info</a> | | |||
<b><a href="mailto:team@stackoverflow.com">contact us</a></b> | | |||
<b><a href="http://meta.stackoverflow.com">feedback always welcome</a></b> | |||
<div id="footer-sites"> | |||
<span style="color:#FE7A15;font-size:140%">■</span> <a href="http://stackoverflow.com">stackoverflow.com</a> | |||
<span style="color:#FE7A15;font-size:140%">■</span> <a href="http://stackapps.com">api/apps</a> | |||
<span style="color:#FE7A15;font-size:140%">■</span> <a href="http://careers.stackoverflow.com">careers</a> | |||
<span style="color:#E8272C;font-size:140%">■</span> <a href="http://serverfault.com">serverfault.com</a> | |||
<span style="color:#00AFEF;font-size:140%">■</span> <a href="http://superuser.com">superuser.com</a> | |||
<span style="color:#969696;font-size:140%">■</span> <a href="http://meta.stackoverflow.com">meta</a> | |||
<a href="http://www.howtogeek.com">howtogeek.com</a> | |||
<a href="http://doctype.com">doctype.com</a> | |||
</div> | |||
</div> | |||
<div id="footer-flair"> | |||
<a href="http://creativecommons.org/licenses/by-sa/2.5/" class="cc-wiki-link"></a> | |||
<a href="http://www.peakinternet.com/business/hosting/colocation-dedicated#" class="peak-link"></a> | |||
<div id="svnrev">revision: 2010.5.24.2</div> | |||
|
|||
</div> | |||
<div id="copyright"> | |||
site design / logo © 2010 stackoverflow.com internet services, inc; | |||
user contributions licensed under <a href="http://creativecommons.org/licenses/by-sa/2.5/" rel="license">cc-wiki</a> with <a href="http://blog.stackoverflow.com/2009/06/attribution-required/" rel="license">attribution required</a> | |||
</div> | |||
</div> | |||
</div> | |||
|
|||
<noscript> | |||
<div id="noscript-warning">Stack Overflow works best with JavaScript enabled<img src="http://pixel.quantserve.com/pixel/p-c1rF4kxgLUzNc.gif" alt="" class="dno"></div> | |||
</noscript> | |||
|
|||
<script type="text/javascript"> | |||
document.write(unescape("%3Cscript src='http://www.google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E")); | |||
</script> | |||
<script type="text/javascript"> | |||
var pageTracker = _gat._getTracker("UA-5620270-1"); | |||
pageTracker._trackPageview(); | |||
</script> | |||
<script type="text/javascript"> | |||
_qoptions = { qacct : "p-c1rF4kxgLUzNc" }; | |||
</script> | |||
<script type="text/javascript" src="http://edge.quantserve.com/quant.js"></script> | |||
|
|||
</body> | |||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -1,18 +1,19 @@ | |||
%h2 Login! | %h2 Login! | ||
%form#authentication_form{:action => authenticate_url, :method => :post} | - form_for @user_session, :url => authenticate_path, :html => { :method => :post, :class => "authentication_form" } do |f| | ||
= f.error_messages | |||
/ authentication_type should be "user" or "session", based on controller | |||
= oauth_login_hidden_input | |||
%fieldset | %fieldset | ||
%input{:type => :hidden, :name => :authentication_method, :value => :oauth} | %legend Click your Oauth or OpenID provider | ||
%input{:type => :hidden, :name => :authentication_type, :value => :session} | |||
%legend Click your Oauth or OpenID provider. | |||
.oauth_providers | .oauth_providers | ||
%ul | %ul | ||
- %w(google facebook twitter).each do |name| | - %w(google facebook twitter yahoo myspace linked_in).each do |name| | ||
%li.oauth_provider | %li.oauth_provider | ||
%img{:src => "/images/icons/#{name}.png"} | = image_tag "/images/icons/#{name}.png" | ||
%input{:type => :radio, :id => "#{name}_oauth_provider", :name => :oauth_provider, :value => name} | = radio_button_tag :oauth_provider, name | ||
.clearfix | .clearfix | ||
%fieldset | %fieldset | ||
%legend Or type in your OpenID address | %legend Or type in your OpenID address | ||
.openid_address | .openid_address | ||
%input.nice{:type => :text, :name => "openid_identifier"} | = text_field_tag :openid_identifier, nil, :class => :nice | ||
%input.submit{:name => :submit, :type => :submit, :value => "Register"}/ | = submit_tag "Login", :class => :submit |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -1,15 +1,17 @@ | |||
AuthlogicConnectExample::Application.routes.draw do |map| | AuthlogicConnectExample::Application.routes.draw do |map| | ||
match "/reset" => "users#detonate" |
|
||
match 'logout' => 'user_sessions#destroy', :as => :logout | match 'logout' => 'user_sessions#destroy', :as => :logout | ||
match 'login' => 'user_sessions#new', :as => :login | match 'login' => 'user_sessions#new', :as => :login | ||
match 'authenticate' => 'user_sessions#create', :as => :authenticate, :via => :post | match 'authenticate' => 'user_sessions#create', :as => :authenticate, :via => :post | ||
match 'signup' => 'users#new', :as => :signup | match 'signup' => 'users#new', :as => :signup | ||
match 'register' => 'users#create', :as => :register, :via => :post | match 'connect' => 'users#update', :as => :connect, :via => :post | ||
match 'connect' => 'users#update', :as => :connect, :via => :put |
|
||
match "reset" => "users#detonate" | |||
|
|||
map.resources :users | map.resources :users | ||
map.resource :user_session | map.resource :user_session | ||
|
|
||
match ':id' => 'users#show', :as => :profile | match ':id' => 'users#show', :as => :profile | ||
root :to => "users#new" | root :to => "users#new" | ||
|
|
||
end | end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
File renamed without changes
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.