活动页面添加参赛作品瀑布流
[PumpkinHouse.git] / PumpkinHouseWeb / Account / ExternalAuth.Master
blobf91aca08dc2d43595252efb8e6d1f20afcf99705
1 <%@ Master Language="C#" AutoEventWireup="true" CodeBehind="ExternalAuth.master.cs" Inherits="PumpkinHouse.Account.ExternalAuth" MasterPageFile="~/Account/Account.Master" %>\r
2 \r
3 <asp:Content ID="Head" runat="server" ContentPlaceHolderID="headHolder">\r
4     <asp:ContentPlaceHolder ID="headHolder" runat="server">\r
5     </asp:ContentPlaceHolder>\r
6     <form runat="server">\r
7     <asp:ScriptManager ID="ScriptManager1" runat="server">\r
8         <CompositeScript ScriptMode="Release">\r
9             <Scripts>\r
10                <asp:ScriptReference Path="/Scripts/data.js" />\r
11                <asp:ScriptReference Path="/Scripts/ajaxCall.js" />\r
12                <asp:ScriptReference Path="/Scripts/util.js" />\r
13             </Scripts>\r
14         </CompositeScript>\r
15     </asp:ScriptManager>\r
16     </form>\r
17     <script type="text/javascript">\r
18         var globalExternalPartner;\r
19         var returnUrl = '<%= ReturnUrl %>';\r
20         $(function () {\r
21             $('#newAccountForm').validate({\r
22                 messages: {\r
23                     email: {\r
24                         required: '请输入注册邮箱',\r
25                         email: '请输入正确的邮箱',\r
26                         remote: '邮箱已存在?请切换到"绑定已有账号"'\r
27                     },\r
28                     nickname: {\r
29                         required: '请输入昵称名',\r
30                         remote: '此昵称已经被使用'\r
31                     },\r
32                      password: {\r
33                         required: '请输入密码'\r
34                     }\r
35                },\r
36                 submitHandler: function () {\r
37                     var avatar = $('#avatar').attr('src');\r
38                     var user = new UserForRegistration($.trim($("#email").val()), $('#nickname').val(), $("#password").val(), avatar, $('#followMe').attr('checked') == 'checked', $('#advertise').attr('checked') == 'checked');\r
39                     ajaxRegisterAssociateAccount(true, user, function () { document.location = '/guide/step1.aspx'; }, handleFault);\r
40                 }\r
41             });\r
42             $('#existingAccountForm').validate({\r
43                 messages: {\r
44                     email2: {\r
45                         required: '请输入注册邮箱',\r
46                         email: '请输入正确的邮箱'\r
47                     },\r
48                     password2: {\r
49                         required: '请输入密码'\r
50                     }\r
51                 },\r
52                 submitHandler: function () {\r
53                     ajaxAssociateAccount(true, $("#email2").val(), $("#password2").val(), globalExternalPartner, function () { document.location = returnUrl; }, handleFault);\r
54                 }\r
55             });\r
56         });\r
58         \r
59         $(document).ready(function () {\r
60             $(".tabStepMenu1").click(function () {\r
61                 $(".tabStepMenu1 a").addClass("liSelected");\r
62                 $(".tabStepMenu2 a").removeClass("liSelected");\r
63                 $(".ConBox1").css("display", "block");\r
64                 $(".ConBox2").css("display", "none");\r
65             });\r
66             $(".tabStepMenu2").click(function () {\r
67                 $(".tabStepMenu2 a").addClass("liSelected");\r
68                 $(".tabStepMenu1 a").removeClass("liSelected");\r
69                 $(".ConBox2").css("display", "block");\r
70                 $(".ConBox1").css("display", "none");\r
71             });\r
72         });\r
74     </script>\r
75 </asp:Content>\r
77 <asp:Content ID="Content" runat="server" ContentPlaceHolderID="AccountContentHolder">\r
78    <asp:ContentPlaceHolder ID="ContentHolder" runat="server">\r
79          \r
80    </asp:ContentPlaceHolder>\r
82     <div class="tabStepMenu clearfix" style="margin-top:20px;">\r
83         <ul class="float_l">\r
84                 <li class="tabStepMenu1"><a class="liSelected">创建新账号</a></li>\r
85             <li class="tabStepMenu2"><a>绑定已有账号</a></li>\r
86         </ul>\r
87     </div>\r
88     \r
89     <div class="ConBox1" style=" height:460px;">\r
90     <form id="newAccountForm" >\r
91     <div class="Congra-title"><h1>欢迎来到木头盒子,简单填写以下信息就OK啦!</h1></div>\r
92         <div class="qsLoginBox">\r
93            <dl class="float_l">\r
94                 <dd><img id="avatar" alt="头像" src="<%= User.AvatarUrl %>" width="180" height="180" /></dd>\r
95            </dl>\r
96            <ul class="float_l">\r
97                 <li>昵称<input type="text" id="nickname" value="<%= User.NickName %>" name="nickname" class="input required" remote="/PublicService/AccountService.svc/ajax/IsNicknameAvailable"/></li>\r
98                 <li>邮箱<input type="text" id="email" name="email" class="input required email" remote="/PublicService/AccountService.svc/ajax/IsEmailAvailable" /></li>\r
99                 <li>密码<input type="password" id="password" name="password" class="input required"/></li>\r
100            </ul>\r
101            <div class="clearfix"></div>\r
102            <ul class="ul2">\r
103               <li>\r
104               <% if (ShowWeiboRequest)\r
105                  { %><input type="checkbox" id="followMe" class="ck" checked="checked" /><label for="followMe">关注木头盒子<%= WeiboName %></label><% } %>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\r
106               <% if (ShowAdvertiseRequest)\r
107                  { %><input type="checkbox" id="advertise" class="ck" checked="checked" /><label for="advertise">推荐我们给您的好友</label><%} %>\r
108               <br />\r
109               <input type="submit" value="进入木头盒子" id="hasExistingBtn" class="Public-Btn-Box NextStep" />\r
110               </li>\r
111            </ul>\r
112         </div>\r
113     </form>\r
114     </div>\r
116     <div class="ConBox2 hide" style=" height:460px;">\r
117     <form id="existingAccountForm" >\r
118     <div class="Congra-title"><h1>您已经注册了木头盒子帐号,登录后我们会帮您绑定帐号。</h1></div>\r
119         <div class="qsLoginBox">\r
120            <ul class="float_l" style="margin-left:0px;">\r
121                 <li>邮箱<input type="text" id="email2" name="email2" class="input required email" /></li>\r
122                 <li>密码<input type="password" id="password2" name="password2" class="input required"/></li>\r
123            </ul>\r
124            <div class="clearfix"></div>\r
125            <ul class="ul2">\r
126               <li><input type="checkbox" id="rememberMe" value="" name="rememberMe" class="ck" checked/>&nbsp;<label for="rememberMe">下次自动登录</label>\r
127               <br />\r
128               <input type="submit" value="登录并绑定帐号" id="Submit1" class="Public-Btn-Box NextStep" />\r
129               </li>\r
130            </ul>\r
131         </div>\r
132     </form>\r
133     </div>\r
134 </asp:Content>\r