Permalink
Browse files

changing views to nysenate.gov layout

  • Loading branch information...
1 parent 6165aab commit 2660e92538101b91f75ce8f14489e501fe5d97e6 Jared Williams committed Dec 15, 2010
View
@@ -3,16 +3,19 @@
<classpathentry kind="src" path="src"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry kind="con" path="org.eclipse.jst.j2ee.internal.module.container"/>
- <classpathentry kind="lib" path="WebContent/WEB-INF/lib/asm-3.1.jar"/>
+ <classpathentry kind="con" path="org.eclipse.jst.server.core.container/org.eclipse.jst.server.tomcat.runtimeTarget/Apache Tomcat v6.0 (2)"/>
+ <classpathentry kind="lib" path="WebContent/WEB-INF/lib/jasypt-1.6.jar"/>
+ <classpathentry kind="lib" path="WebContent/WEB-INF/lib/mail.jar"/>
<classpathentry kind="lib" path="WebContent/WEB-INF/lib/commons-codec-1.4.jar"/>
+ <classpathentry kind="lib" path="WebContent/WEB-INF/lib/commons-httpclient-3.1.jar"/>
+ <classpathentry kind="lib" path="WebContent/WEB-INF/lib/commons-lang-2.5.jar"/>
+ <classpathentry kind="lib" path="WebContent/WEB-INF/lib/commons-logging-1.1.jar"/>
+ <classpathentry kind="lib" path="WebContent/WEB-INF/lib/asm-3.1.jar"/>
<classpathentry kind="lib" path="WebContent/WEB-INF/lib/commons-collections-3.1.jar"/>
<classpathentry kind="lib" path="WebContent/WEB-INF/lib/commons-dbcp-1.2.1.jar"/>
<classpathentry kind="lib" path="WebContent/WEB-INF/lib/commons-fileupload-1.2.1.jar"/>
- <classpathentry kind="lib" path="WebContent/WEB-INF/lib/commons-httpclient-3.1.jar"/>
<classpathentry kind="lib" path="WebContent/WEB-INF/lib/commons-io-1.4.jar"/>
<classpathentry kind="lib" path="WebContent/WEB-INF/lib/commons-lang-2.2.jar"/>
- <classpathentry kind="lib" path="WebContent/WEB-INF/lib/commons-lang-2.5.jar"/>
- <classpathentry kind="lib" path="WebContent/WEB-INF/lib/commons-logging-1.1.jar"/>
<classpathentry kind="lib" path="WebContent/WEB-INF/lib/commons-logging.jar"/>
<classpathentry kind="lib" path="WebContent/WEB-INF/lib/commons-pool-1.2.jar"/>
<classpathentry kind="lib" path="WebContent/WEB-INF/lib/datanucleus-cache-2.0.0-release.jar"/>
@@ -35,18 +38,15 @@
<classpathentry kind="lib" path="WebContent/WEB-INF/lib/datanucleus-xmltypeoracle-2.0.0-release.jar"/>
<classpathentry kind="lib" path="WebContent/WEB-INF/lib/httpclient-4.0.3.jar"/>
<classpathentry kind="lib" path="WebContent/WEB-INF/lib/httpmime-4.0.3.jar"/>
- <classpathentry kind="lib" path="WebContent/WEB-INF/lib/jasypt-1.6.jar"/>
<classpathentry kind="lib" path="WebContent/WEB-INF/lib/jdo2-api-2.3-ec.jar"/>
<classpathentry kind="lib" path="WebContent/WEB-INF/lib/log4j-1.2.14.jar"/>
<classpathentry kind="lib" path="WebContent/WEB-INF/lib/log4j-1.2.16.jar"/>
- <classpathentry kind="lib" path="WebContent/WEB-INF/lib/mail.jar"/>
<classpathentry kind="lib" path="WebContent/WEB-INF/lib/mysql-connector-java-3.1.7-bin.jar"/>
<classpathentry kind="lib" path="WebContent/WEB-INF/lib/slf4j-api-1.5.6.jar"/>
<classpathentry kind="lib" path="WebContent/WEB-INF/lib/ws-commons-util-1.0.2.jar"/>
<classpathentry kind="lib" path="WebContent/WEB-INF/lib/xmlrpc-client-3.1.3.jar"/>
<classpathentry kind="lib" path="WebContent/WEB-INF/lib/xmlrpc-common-3.1.3.jar"/>
<classpathentry kind="lib" path="WebContent/WEB-INF/lib/xmlrpc-server-3.1.3.jar"/>
<classpathentry kind="lib" path="WebContent/WEB-INF/lib/xstream-1.3.1.jar"/>
- <classpathentry kind="con" path="org.eclipse.jst.server.core.container/org.eclipse.jst.server.tomcat.runtimeTarget/Apache Tomcat v6.0"/>
<classpathentry kind="output" path="WebContent/WEB-INF/classes"/>
</classpath>
@@ -1,18 +1,7 @@
-<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
- pageEncoding="ISO-8859-1"
- import="java.util.*,bbsignup.src.*,bbsignup.model.*,javax.jdo.*"
- %>
-<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
-<html>
-<link rel="stylesheet" type="text/css" media="screen" href="style.css"/>
-
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>BillBuzz! Authentication</title>
-</head>
-<body>
+<%@ page language="java" import="java.util.*,bbsignup.src.*,bbsignup.model.*,javax.jdo.*"%>
+<jsp:include page="header.jsp" />
+<div id="main">
<center>
-<br/>
<%
String email = request.getParameter("email");
@@ -60,7 +49,6 @@
}
%>
-<%@ include file="footer.jsp" %>
</center>
-</body>
-</html>
+</div>
+<%@ include file="nfooter.jsp"%>
@@ -1,17 +1,9 @@
-<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
- pageEncoding="ISO-8859-1"
- import="java.util.*,bbsignup.src.*,bbsignup.model.*,javax.jdo.*"
+<%@ page language="java" import="java.util.*,bbsignup.src.*,bbsignup.model.*,javax.jdo.*"
%>
-<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
-<html>
-<link rel="stylesheet" type="text/css" media="screen" href="style.css"/>
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>Insert title here</title>
-</head>
-<body>
+
+<jsp:include page="header.jsp" />
+<div id="main">
<center>
-<br/>
<%
String email = (String)request.getParameter("email");
String key = (String)request.getParameter("key");
@@ -44,7 +36,6 @@
%>
-<%@ include file="footer.jsp" %>
</center>
-</body>
-</html>
+</div>
+<%@ include file="nfooter.jsp"%>
@@ -0,0 +1,32 @@
+<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
+ pageEncoding="ISO-8859-1"%>
+<!DOCTYPE html>
+<html>
+ <head>
+ <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
+ <title>NYSS BillBuzz</title>
+ <link rel="stylesheet" type="text/css" href="style.css" />
+ <link rel="stylesheet" type="text/css" href="nys.css" />
+ <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script>
+ <script type="text/javascript" src="js.js"></script>
+ </head>
+ <body>
+ <div id="page">
+ <div id="header">
+ <a href="index.jsp">
+ <img src="http://www.nysenate.gov/sites/all/themes/nys/images/nyss_logo.png" id="logo" />
+ </a>
+
+ </div>
+
+ <div id="nav_bar">
+ Already subscribed?
+ <ul>
+ <li><a href="update.jsp">Update</a></li>
+ <li>or</li>
+ <li><a href="unsubscribe.jsp">Unsubscribe</a></li>
+ </ul>
+ </div>
+
+
+
@@ -1,114 +1,11 @@
-<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
- pageEncoding="ISO-8859-1"
- import="servlets.SenatorContext,java.util.*,bbsignup.src.*,bbsignup.model.Senator,javax.jdo.*"%>
+<%@ page contentType="text/html; charset=ISO-8859-1"
+ pageEncoding="ISO-8859-1" language="java" import="servlets.SenatorContext,java.util.*,bbsignup.src.*,bbsignup.model.Senator"%>
+ <jsp:include page="header.jsp" />
<%
-
List<Senator> list = (List<Senator>)SenatorContext.getSenators(this.getServletContext());;
%>
-<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
-<html>
-<link rel="stylesheet" type="text/css" media="screen" href="style.css" />
-<script type="text/javascript"
- src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.js"></script>
-<script type="text/javascript">
-
-function addError(message, msg) {
- if(message == "") {
- return msg;
- }
- else {
- return message += "<br>" + msg;
- }
-}
- $(document).ready(
- function() {
- /*reset = function() {
- $('.cb_').each(function() {
- doCheck(this, $(this).attr('party'));
- });
- };*/
-
- doCheck = function(curSelector, party) {
- if (!$('#cb_all').is(':checked')) {
- $('.senator').each(function(index) {
- var parties = $($('.party').get(index)).html();
-
- var check = $(this).children("INPUT[type='checkbox']");
-
- var re = new RegExp('(\\(|\\- )' + party
- + '(\\)| \\-)');
- if (parties.match(re)) {
- $(check).attr('checked',
- $(curSelector).is(':checked'));
- }
- });
- }
- };
-
- clearAll = function() {
- $("INPUT[type='checkbox']").attr('checked', false);
- };
-
- $('#cb_all').change(
- function() {
- $("INPUT[type='checkbox']").attr('checked',
- $('#cb_all').is(':checked'));
- });
-
- $('.cb_').change(function() {
- doCheck(this, $(this).attr('party'));
- //reset();
- });
-
- $('#process').click(function(event) {
-
-
- message = "";
- e1 = document.forms.senators.email1.value;
- e2 = document.forms.senators.email2.value;
- fn = document.forms.senators.firstname.value;
- ln = document.forms.senators.lastname.value;
-
- if(!fn){
- message = addError(message, "Enter your first name");
- }
- if(!ln) {
- message = addError(message, "Enter your last name");
- }
- if(e1 == null || e2 == null || e1 != e2) {
- message = addError(message, "Your email addresses must match!");
- }
- else {
- if(!e1.match(/.*?@.*?\..*?/)) {
- message = addError(message, "Enter a valid email address");
- }
- }
-
- if(message != "") {
- $("#error").html(message);
- $("#error").css({'display' : 'inherit'});
- $('html,body').animate({
- scrollTop:$("#error").offset().top}, 500);
- return false;
- }
- else {
- return true;
-
- }
-
- });
-
- });
-
-</script>
-
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
-<title>Sign up for BillBuzz!</title>
-</head>
-<body>
-
<center>
+<div id="main">
<%
String update = (String) session.getAttribute("update");
String fn = (String) session.getAttribute("fn");
@@ -135,6 +32,7 @@ function addError(message, msg) {
session.setAttribute("ln", null);
session.setAttribute("e", null);
session.setAttribute("update", null);
+ session.setAttribute("subs", null);
}
if(subs != null && subs.size() == 0) {
%>
@@ -155,11 +53,9 @@ function addError(message, msg) {
<form id="inputForm" name="senators" method="post"
action="subscribe">
-
-
<h2>What is BillBuzz?</h2>
-<div class="main">
+<div class="bb_main">
<table>
<tr>
<td>
@@ -181,9 +77,9 @@ function addError(message, msg) {
</div>
<div id ="error" class="bad" style="font-size: 85%; width: 40%;display:none;"></div>
-<h2 style="left: -385px">Sign Up</h2>
+<h2>Sign Up</h2>
<p></p>
-<div class="main"><br>
+<div class="bb_main"><br>
<table>
<tr>
<td>First name</td>
@@ -306,6 +202,6 @@ function addError(message, msg) {
</div>
</form>
-<%@ include file="footer.jsp"%></center>
-</body>
-</html>
+</div>
+</center>
+<%@ include file="nfooter.jsp"%>
View
@@ -0,0 +1,87 @@
+function addError(message, msg) {
+ if(message == "") {
+ return msg;
+ }
+ else {
+ return message += "<br>" + msg;
+ }
+}
+ $(document).ready(
+ function() {
+ /*reset = function() {
+ $('.cb_').each(function() {
+ doCheck(this, $(this).attr('party'));
+ });
+ };*/
+
+ doCheck = function(curSelector, party) {
+ if (!$('#cb_all').is(':checked')) {
+ $('.senator').each(function(index) {
+ var parties = $($('.party').get(index)).html();
+
+ var check = $(this).children("INPUT[type='checkbox']");
+
+ var re = new RegExp('(\\(|\\- )' + party
+ + '(\\)| \\-)');
+ if (parties.match(re)) {
+ $(check).attr('checked',
+ $(curSelector).is(':checked'));
+ }
+ });
+ }
+ };
+
+ clearAll = function() {
+ $("INPUT[type='checkbox']").attr('checked', false);
+ };
+
+ $('#cb_all').change(
+ function() {
+ $("INPUT[type='checkbox']").attr('checked',
+ $('#cb_all').is(':checked'));
+ });
+
+ $('.cb_').change(function() {
+ doCheck(this, $(this).attr('party'));
+ //reset();
+ });
+
+ $('#process').click(function(event) {
+
+
+ message = "";
+ e1 = document.forms.senators.email1.value;
+ e2 = document.forms.senators.email2.value;
+ fn = document.forms.senators.firstname.value;
+ ln = document.forms.senators.lastname.value;
+
+ if(!fn){
+ message = addError(message, "Enter your first name");
+ }
+ if(!ln) {
+ message = addError(message, "Enter your last name");
+ }
+ if(e1 == null || e2 == null || e1 != e2) {
+ message = addError(message, "Your email addresses must match!");
+ }
+ else {
+ if(!e1.match(/.*?@.*?\..*?/)) {
+ message = addError(message, "Enter a valid email address");
+ }
+ }
+
+ if(message != "") {
+ $("#error").html(message);
+ $("#error").css({'display' : 'inherit'});
+ $('html,body').animate({
+ scrollTop:$("#error").offset().top}, 500);
+ return false;
+ }
+ else {
+ return true;
+
+ }
+
+ });
+
+ });
Oops, something went wrong.

0 comments on commit 2660e92

Please sign in to comment.