Use Bootstrap modal for Terms of Service

This commit is contained in:
Erik Michaels-Ober 2011-12-25 09:17:49 -08:00
parent d420b5fff9
commit 0dc2b11bca
8 changed files with 516 additions and 253 deletions

View File

@ -0,0 +1,260 @@
/* =========================================================
* bootstrap-modal.js v1.4.0
* http://twitter.github.com/bootstrap/javascript.html#modal
* =========================================================
* Copyright 2011 Twitter, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
* ========================================================= */
!function( $ ){
"use strict"
/* CSS TRANSITION SUPPORT (https://gist.github.com/373874)
* ======================================================= */
var transitionEnd
$(document).ready(function () {
$.support.transition = (function () {
var thisBody = document.body || document.documentElement
, thisStyle = thisBody.style
, support = thisStyle.transition !== undefined || thisStyle.WebkitTransition !== undefined || thisStyle.MozTransition !== undefined || thisStyle.MsTransition !== undefined || thisStyle.OTransition !== undefined
return support
})()
// set CSS transition event type
if ( $.support.transition ) {
transitionEnd = "TransitionEnd"
if ( $.browser.webkit ) {
transitionEnd = "webkitTransitionEnd"
} else if ( $.browser.mozilla ) {
transitionEnd = "transitionend"
} else if ( $.browser.opera ) {
transitionEnd = "oTransitionEnd"
}
}
})
/* MODAL PUBLIC CLASS DEFINITION
* ============================= */
var Modal = function ( content, options ) {
this.settings = $.extend({}, $.fn.modal.defaults, options)
this.$element = $(content)
.delegate('.close', 'click.modal', $.proxy(this.hide, this))
if ( this.settings.show ) {
this.show()
}
return this
}
Modal.prototype = {
toggle: function () {
return this[!this.isShown ? 'show' : 'hide']()
}
, show: function () {
var that = this
this.isShown = true
this.$element.trigger('show')
escape.call(this)
backdrop.call(this, function () {
var transition = $.support.transition && that.$element.hasClass('fade')
that.$element
.appendTo(document.body)
.show()
if (transition) {
that.$element[0].offsetWidth // force reflow
}
that.$element.addClass('in')
transition ?
that.$element.one(transitionEnd, function () { that.$element.trigger('shown') }) :
that.$element.trigger('shown')
})
return this
}
, hide: function (e) {
e && e.preventDefault()
if ( !this.isShown ) {
return this
}
var that = this
this.isShown = false
escape.call(this)
this.$element
.trigger('hide')
.removeClass('in')
$.support.transition && this.$element.hasClass('fade') ?
hideWithTransition.call(this) :
hideModal.call(this)
return this
}
}
/* MODAL PRIVATE METHODS
* ===================== */
function hideWithTransition() {
// firefox drops transitionEnd events :{o
var that = this
, timeout = setTimeout(function () {
that.$element.unbind(transitionEnd)
hideModal.call(that)
}, 500)
this.$element.one(transitionEnd, function () {
clearTimeout(timeout)
hideModal.call(that)
})
}
function hideModal (that) {
this.$element
.hide()
.trigger('hidden')
backdrop.call(this)
}
function backdrop ( callback ) {
var that = this
, animate = this.$element.hasClass('fade') ? 'fade' : ''
if ( this.isShown && this.settings.backdrop ) {
var doAnimate = $.support.transition && animate
this.$backdrop = $('<div class="modal-backdrop ' + animate + '" />')
.appendTo(document.body)
if ( this.settings.backdrop != 'static' ) {
this.$backdrop.click($.proxy(this.hide, this))
}
if ( doAnimate ) {
this.$backdrop[0].offsetWidth // force reflow
}
this.$backdrop.addClass('in')
doAnimate ?
this.$backdrop.one(transitionEnd, callback) :
callback()
} else if ( !this.isShown && this.$backdrop ) {
this.$backdrop.removeClass('in')
$.support.transition && this.$element.hasClass('fade')?
this.$backdrop.one(transitionEnd, $.proxy(removeBackdrop, this)) :
removeBackdrop.call(this)
} else if ( callback ) {
callback()
}
}
function removeBackdrop() {
this.$backdrop.remove()
this.$backdrop = null
}
function escape() {
var that = this
if ( this.isShown && this.settings.keyboard ) {
$(document).bind('keyup.modal', function ( e ) {
if ( e.which == 27 ) {
that.hide()
}
})
} else if ( !this.isShown ) {
$(document).unbind('keyup.modal')
}
}
/* MODAL PLUGIN DEFINITION
* ======================= */
$.fn.modal = function ( options ) {
var modal = this.data('modal')
if (!modal) {
if (typeof options == 'string') {
options = {
show: /show|toggle/.test(options)
}
}
return this.each(function () {
$(this).data('modal', new Modal(this, options))
})
}
if ( options === true ) {
return modal
}
if ( typeof options == 'string' ) {
modal[options]()
} else if ( modal ) {
modal.toggle()
}
return this
}
$.fn.modal.Modal = Modal
$.fn.modal.defaults = {
backdrop: false
, keyboard: false
, show: false
}
/* MODAL DATA- IMPLEMENTATION
* ========================== */
$(document).ready(function () {
$('body').delegate('[data-controls-modal]', 'click', function (e) {
e.preventDefault()
var $this = $(this).data('show', true)
$('#' + $this.attr('data-controls-modal')).modal( $this.data() )
})
})
}( window.jQuery || window.ender );

View File

@ -711,5 +711,9 @@ $(function() {
}); });
return false; return false;
}); });
$('.alert-message').alert() $('.alert-message').alert();
$('#tos').modal({
backdrop: true,
keyboard: true
});
}); });

View File

@ -1,243 +0,0 @@
%h2
= t("titles.tos")
%ol
%li
%h3
Acceptance of Terms
%p
The City of Boston (&quot;City&quot;) provides the Adopt-a-Hydrant program (&quot;AHA&quot;) to you subject to the following Terms of Service Agreement (&quot;Agreement&quot;) which may be updated by us from time to time without notice to you. By accessing and using AAH, you accept and agree to be bound by the terms and provision of this Agreement.
%li
%h3
Description of Adopt-a-Hydrant
%p
Adopt-a-Hydrant is an initiative of the City to encourage residents to shovel out snowed-in fire hydrants. The AAH website allows users to &quot;adopt&quot; a fire hydrant, or state that you intend to help shovel that fire hydrant out if it gets covered by snow.
%p
Unless explicitly stated otherwise, any new features that augment or enhance AAH are covered by this Agreement.
%li
%h3
Obligations
%p
If you choose to adopt a fire hydrant using the AAH website, you are under no obligation and have no responsibility to actually shovel out that fire hydrant or any fire hydrant.
%li
%h3
Termination of Obligations
%p
If you provide any information that is untrue, inaccurate, offensive, not current, or incomplete, or the City has reasonable grounds to suspect that such information is untrue, inaccurate, offensive, not current, or incomplete, the City has the right to suspend or terminate your account and refuse any and all current or future use of the AAH services (or any portion thereof).
%p
Accounts that consistently adopt fire hydrants without shoveling them out may also be terminated.
%p
Additionally, you agree that the City may, without prior notice, immediately terminate, limit your access to, or suspend your AAH service. Cause for such termination, limitation of access, or suspension shall include but not be limited to:
%ol.alpha
%li
breaches or violations of this Agreement or other incorporated agreements or guidelines,
%li
requests by law enforcement or other government agencies,
%li
discontinuance or material modification to AAH (or any part thereof),
%li
unexpected technical or security issues or problems,
%li
extended periods of inactivity,
%li
engagement by you in fraudulent or illegal activities.
%p
Further, you agree that all terminations, limitations of access, and suspensions for cause shall be made in the City's sole discretion and that the City shall not be liable to you or any third party for any termination of your account, any associated email address, or access to AAH.
%li
%h3
City Public Records Policy
%p
Registration data, as well as data you submit using AAH, are subject to all applicable City, State and Federal public records laws.
%li
%h3
Member Conduct
%p
You understand that all information entered by the user is the sole responsibility of the person from whom such Content originated. This means that you, and not the City, are entirely responsible for all Content that you submit or otherwise make available via AAH. The City does not control the sign-in content posted and, as such, does not guarantee the accuracy, integrity, or quality of such Content. You understand that by using AAH, you may be exposed to Content that is offensive, indecent, or objectionable. Under no circumstances will the City be liable in any way for any Content, including, but not limited to, any errors or omissions in any Content, or any loss or damage of any kind incurred as a result of the use of any Content submitted or otherwise made available via AAH.
%p
We are under no obligation to enforce this Agreement on your behalf against another user. While we encourage you to let us know if you believe another user violated this Agreement, we reserve the right to investigate and take appropriate action at the City's sole discretion.
%p
You agree to not use AAH to:
%ol.alpha
%li
submit Content that is false or inaccurate;
%li
submit Content that does not generally pertain to the designated topic or theme;
%li
submit or otherwise make available any Content that is unlawful, harmful, threatening, abusive, harassing, tortuous, defamatory, vulgar, obscene, libelous, invasive of another's privacy, hateful, or racially, ethnically, or otherwise objectionable;
%li
harm minors in any way;
%li
impersonate any person or entity, or falsely state or otherwise misrepresent your affiliation with a person or entity;
%li
submit or otherwise make available any Content that you do not have a right to make available under any law or under contractual or fiduciary relationships (such as inside information, proprietary and confidential information learned or disclosed as part of employment relationships or under nondisclosure agreements);
%li
submit or otherwise make available any Content that infringes any patent, trademark, trade secret, copyright, or other proprietary rights (&quot;Rights&quot;) of any party;
%li
submit or otherwise make available any unsolicited or unauthorized advertising, promotional materials, &quot;junk mail,&quot; &quot;spam,&quot; &quot;chain letters,&quot; &quot;pyramid schemes,&quot; or any other form of communication not relevant to specific City service requests;
%li
submit or otherwise make available any material that contains software viruses or any other computer code, files or programs designed to interrupt, destroy or limit the functionality of any computer software or hardware or telecommunications equipment;
%li
intentionally or unintentionally violate any applicable local, state, national or international law;
%li
&quot;stalk&quot; or otherwise harass another; or
%li
collect or store personal data about other users in connection with the prohibited conduct and activities set forth in paragraphs (a) through (k) above.
%p
You acknowledge that the City may or may not pre-screen Content that is shared, but that the City and its designees shall have the right (but not the obligation) in their sole discretion to pre-screen, refuse, or remove any Content that is available via AAH. Without limiting the foregoing, the City and its designees shall have the right to remove any Content that violates this Agreement or is otherwise objectionable. You agree that you must evaluate, and bear all risks associated with, the use of any Content, including any reliance on the accuracy, completeness, or usefulness of such Content.
%p
You acknowledge, consent and agree that the City may access, preserve and disclose your account information and Content if required to do so by law or in a good faith belief that such access preservation or disclosure is reasonably necessary to:
%ol.roman
%li
comply with legal process;
%li
enforce this Agreement;
%li
respond to claims that any Content violates the rights of third parties;
%li
respond to your requests for customer service;
%li
protect the rights, property or personal safety of the City, its users and the public.
%p
You may not attempt to override or circumvent any of the usage rules embedded into AAH.
%p
You may not trace any information of any other AAH user or visitor or otherwise use AAH for the purpose of obtaining information of any other AAH user.
%p
You may not attempt to gain unauthorized access to AAH or the computer systems and networks connected to AAH through hacking, password mining, or any other means.
%p
You may not release the results of any performance or functional evaluation of AAH to any third party without prior written approval of the City for each such release.
%p
You may not take any action that imposes, or may impose, in the City's sole discretion, an unreasonable or disproportionately large load on the City's technology infrastructure or otherwise make excessive traffic demands of AAH.
%li
%h3
Interstate Nature of Communications on Adopt-a-Hydrant
%p
When you use the application, you acknowledge that in using AAH, you will be causing communications to be sent potentially through a variety of networks (Internet service provider, wireless phone network, etc.) As a result, even communications that seem to be intrastate in nature can result in the transmission of interstate communications regardless of where you are physically located at the time of transmission. Accordingly, you agree that use of the AAH may result in interstate data transmissions.
%li
%h3
Submissions to the City
%p
By submitting feedback (&quot;Submissions&quot;) to the City through the AAH feedback function, you acknowledge and agree that:
%ol.alpha
%li
your Submissions do not contain confidential or proprietary information;
%li
the City is not under any obligation of confidentiality, express or implied, with respect to the Submissions;
%li
the City shall be entitled to use or disclose (or choose not to use or disclose) such Submissions for any purpose, in any way, in any media worldwide;
%li
the City may have something similar to the Submissions already under consideration or in development;
%li
your Submissions automatically become the property of the City without any obligation of the City to you;
%li
you are not entitled to any compensation or reimbursement of any kind from the City under any circumstances.
%li
%h3
Indemnity
%p
You agree to indemnify and hold the City and its subsidiaries, affiliates, officers, agents, employees, partners, and licensors harmless from any claim or demand (including reasonable attorneys' fees) made by any third party due to or arising out of:
%ol.alpha
%li
Content you submit or otherwise make available through AAH,
%li
your use of AAH,
%li
your connection to AAH,
%li
your violation of this Agreement,
%li
your violation of any Rights of another.
%li
%h3
Modifications to Adopt-a-Hydrant
%p
The City reserves the right at any time and from time to time to modify or discontinue, temporarily or permanently, AAH (or any part thereof) with or without notice. You agree that the City shall not be liable to you or to any third party for any modification, suspension or discontinuance of the AAH (or any part thereof).
%li
%h3
Links
%p
The City may provide links to other World Wide Web sites or resources. You acknowledge and agree that the City is not responsible for the availability of such external sites or resources.
%p
AAH may facilitate your use of third party services not provided by the City (&quot;Third Party Services&quot;). The City makes no representations or warranties regarding the performance of such Third Party Services, their compliance with applicable laws and regulations, or any other aspects of such Third Party Services. Your use of Third Party Services is at your own risk and you are solely responsible for complying with all legal and contractual requirements necessary for using Third Party Services.
%li
%h3
The City's Proprietary Rights
%p
You acknowledge and agree that AAH contains proprietary and confidential information that is owned by the City and protected by applicable intellectual property and other laws. You will not use such proprietary information in any way whatsoever except for use of AAH in compliance with the provisions of this Agreement.
%h4.upcase
Disclaimer of Warranties
%p.upcase
You expressly understand and agree that:
%ol.alpha.upcase
%li
Your use of AAH is at your sole risk. The application is provided on an &quot;as is&quot; and &quot;as available&quot; basis. The city expressly disclaims all warranties of any kind, whether express or implied, including, but not limited to the implied warranties of title, merchantability, fitness for a particular purpose and non-infringement.
%li
The city and its subsidiaries, affiliates, officers, employees, agents, partners, and licensors make no warrany that:
%ol.roman
%li
AAH will meet your requirements;
%li
AAH will be uninterrupted, timely, secore, or error-free;
%li
the results that may be obtained from the use of AAH will be accurate or reliable;
%li
any errors in the software will be corrected;
%li
AAH will be free from corruption, viruses, hacking, or other security intrusion.
%li
%h3
Limitation of Liability
%p.upcase
You expressly understand and agree that the city shall not be liable to you for any punitive, indirect, incidental, special, consequential, or exemplary damages, including, but not limtied to, damages for loss of profits, goodwill, use, data, or other intangible losses resulting from:
%ol.alpha.upcase
%li
Your access to or use of or inability to access or use the services;
%li
any conduct or content or any third party on the services, including without limitation, any defamatory, offensive or illegal conduct of other users or third parties;
%li
any content obtained from the services;
%li
unauthorized access, use or alteration of your transmissions or content, whether based on warranty, contract, tort (including negligence) or any other legal theory, whether or not the city has been informed of the possibility of such damage, and even if a remedy set forth herein is found to have failed of its essential purpose.
%p.upcase
You expressly agree that the city is not responsible for any contact or interaction between you and any other user of AAH and that you bear the sole risk of transmitting through the application any content, including information which identifies you or your location.
%p.upcase
You agree that the negation of damages set forth above is a fundamental element of the basis of the bargain between the city and you and that the foregoing limitation of liability is an agreed upon allocation of risk between you and the city. You acknowledge that absent your agreement to this limitation of liability the city would not provide AAH to you.
%li
%h3
Notice
%p
The City may provide you with notices regarding AAH, including changes to this Agreement, by email, SMS, text message, postings on AAH, or any other reasonable means now known or hereafter developed. Notices shall be effective immediately.
%p
Such notices may not be received if you violate this Agreement by accessing the AAH in an unauthorized manner. You agree that you will be deemed to have received any and all notices that would have been delivered had you accessed AAH in an authorized manner.
%li
%h3
Minor
%p
You represent that you are 13 years of age or older and, if you are under the age of 18, you either are an emancipated minor, or have obtained the legal consent of your parent or legal guardian to accept and agree to be bound by the terms and provisions of this Agreement.
%p
If you have agreed to allow your minor child, or a child for whom you are legal guardian (&quot;Minor&quot;), to use AAH, you agree that you shall be solely responsible for:
%ol.alpha
%li
the online conduct of such Minor,
%li
monitoring such Minors access to and use of AAH, and
%li
the consequences of any use of AAH by such Minor.
%li
%h3
Governing Law and Venue
%p
This Agreement is governed by the laws of the Commonwealth of Massachusetts without regard to any conflict of law provisions. You agree that any claim or dispute with the City relating in any way to your use of AAH shall be brought exclusively before a state or federal court sitting in Boston, Massachusetts, and you irrevocably waive any jurisdictional, venue, or inconvenient forum objections to such courts.
%li
%h3
Miscellaneous
%p
This Agreement constitutes the entire agreement between you and the City with respect to your use of AAH, superseding any prior version of this Agreement between you and the City with respect to AAH.
%p
If any provision of this Agreement shall be unlawful, void, or unenforceable, then that provision shall be deemed severed from this Agreement and shall not affect the validity or enforceability of the remaining provisions of this Agreement.
%p
The City's failure to assert any right or provision under this Agreement shall not constitute a waiver of such right or provision.
%p
You agree that any cause of action arising out of or related to your use of AAH must commence within one year after the cause of action accrues. Otherwise, such cause of action is permanently barred.
%p
The section titles in this Agreement are for convenience only and have no legal or contractual effect.
%p
Last updated August 10, 2011.

View File

@ -10,6 +10,7 @@
= javascript_include_tag "https://ajax.googleapis.com/ajax/libs/jqueryui/1/jquery-ui.min.js" = javascript_include_tag "https://ajax.googleapis.com/ajax/libs/jqueryui/1/jquery-ui.min.js"
= javascript_include_tag "bootstrap-twipsy" = javascript_include_tag "bootstrap-twipsy"
= javascript_include_tag "bootstrap-alerts" = javascript_include_tag "bootstrap-alerts"
= javascript_include_tag "bootstrap-modal"
= javascript_include_tag "main" = javascript_include_tag "main"
= csrf_meta_tag = csrf_meta_tag
%meta{:name => "viewport", :content => "initial-scale=1.0, user-scalable=no"} %meta{:name => "viewport", :content => "initial-scale=1.0, user-scalable=no"}

View File

@ -35,7 +35,7 @@
= f.password_field "password_confirmation" = f.password_field "password_confirmation"
= f.submit t("buttons.sign_up"), :class => "btn primary" = f.submit t("buttons.sign_up"), :class => "btn primary"
%p %p
= t("defaults.tos", :tos => link_to(t("titles.tos"), tos_path, :id => "tos_link")).html_safe = t("defaults.tos", :tos => link_to(t("titles.tos"), "#", :id => "tos_link", :"data-controls-modal" => "tos")).html_safe
#user_sign_in_fields{:style => "display: none;"} #user_sign_in_fields{:style => "display: none;"}
%label{:for => "user_password", :id => "user_password_label"} %label{:for => "user_password", :id => "user_password_label"}
= t("labels.password") = t("labels.password")
@ -50,6 +50,7 @@
= f.submit t("buttons.email_password"), :class => "btn primary" = f.submit t("buttons.email_password"), :class => "btn primary"
%p %p
= link_to t("links.remembered_password"), "#", :id => "user_remembered_password_link" = link_to t("links.remembered_password"), "#", :id => "user_remembered_password_link"
= render :partial => "sidebar/tos"
:javascript :javascript
$(function() { $(function() {
$('#user_email').focus(); $('#user_email').focus();

View File

@ -0,0 +1,248 @@
.modal.hide.fade#tos
.modal-header
%a{:class => "close", :href => "#"}
&times;
%h2
= t("titles.tos")
.modal-body
%ol
%li
%h3
Acceptance of Terms
%p
The City of Boston (&quot;City&quot;) provides the Adopt-a-Hydrant program (&quot;AHA&quot;) to you subject to the following Terms of Service Agreement (&quot;Agreement&quot;) which may be updated by us from time to time without notice to you. By accessing and using AAH, you accept and agree to be bound by the terms and provision of this Agreement.
%li
%h3
Description of Adopt-a-Hydrant
%p
Adopt-a-Hydrant is an initiative of the City to encourage residents to shovel out snowed-in fire hydrants. The AAH website allows users to &quot;adopt&quot; a fire hydrant, or state that you intend to help shovel that fire hydrant out if it gets covered by snow.
%p
Unless explicitly stated otherwise, any new features that augment or enhance AAH are covered by this Agreement.
%li
%h3
Obligations
%p
If you choose to adopt a fire hydrant using the AAH website, you are under no obligation and have no responsibility to actually shovel out that fire hydrant or any fire hydrant.
%li
%h3
Termination of Obligations
%p
If you provide any information that is untrue, inaccurate, offensive, not current, or incomplete, or the City has reasonable grounds to suspect that such information is untrue, inaccurate, offensive, not current, or incomplete, the City has the right to suspend or terminate your account and refuse any and all current or future use of the AAH services (or any portion thereof).
%p
Accounts that consistently adopt fire hydrants without shoveling them out may also be terminated.
%p
Additionally, you agree that the City may, without prior notice, immediately terminate, limit your access to, or suspend your AAH service. Cause for such termination, limitation of access, or suspension shall include but not be limited to:
%ol.alpha
%li
breaches or violations of this Agreement or other incorporated agreements or guidelines,
%li
requests by law enforcement or other government agencies,
%li
discontinuance or material modification to AAH (or any part thereof),
%li
unexpected technical or security issues or problems,
%li
extended periods of inactivity,
%li
engagement by you in fraudulent or illegal activities.
%p
Further, you agree that all terminations, limitations of access, and suspensions for cause shall be made in the City's sole discretion and that the City shall not be liable to you or any third party for any termination of your account, any associated email address, or access to AAH.
%li
%h3
City Public Records Policy
%p
Registration data, as well as data you submit using AAH, are subject to all applicable City, State and Federal public records laws.
%li
%h3
Member Conduct
%p
You understand that all information entered by the user is the sole responsibility of the person from whom such Content originated. This means that you, and not the City, are entirely responsible for all Content that you submit or otherwise make available via AAH. The City does not control the sign-in content posted and, as such, does not guarantee the accuracy, integrity, or quality of such Content. You understand that by using AAH, you may be exposed to Content that is offensive, indecent, or objectionable. Under no circumstances will the City be liable in any way for any Content, including, but not limited to, any errors or omissions in any Content, or any loss or damage of any kind incurred as a result of the use of any Content submitted or otherwise made available via AAH.
%p
We are under no obligation to enforce this Agreement on your behalf against another user. While we encourage you to let us know if you believe another user violated this Agreement, we reserve the right to investigate and take appropriate action at the City's sole discretion.
%p
You agree to not use AAH to:
%ol.alpha
%li
submit Content that is false or inaccurate;
%li
submit Content that does not generally pertain to the designated topic or theme;
%li
submit or otherwise make available any Content that is unlawful, harmful, threatening, abusive, harassing, tortuous, defamatory, vulgar, obscene, libelous, invasive of another's privacy, hateful, or racially, ethnically, or otherwise objectionable;
%li
harm minors in any way;
%li
impersonate any person or entity, or falsely state or otherwise misrepresent your affiliation with a person or entity;
%li
submit or otherwise make available any Content that you do not have a right to make available under any law or under contractual or fiduciary relationships (such as inside information, proprietary and confidential information learned or disclosed as part of employment relationships or under nondisclosure agreements);
%li
submit or otherwise make available any Content that infringes any patent, trademark, trade secret, copyright, or other proprietary rights (&quot;Rights&quot;) of any party;
%li
submit or otherwise make available any unsolicited or unauthorized advertising, promotional materials, &quot;junk mail,&quot; &quot;spam,&quot; &quot;chain letters,&quot; &quot;pyramid schemes,&quot; or any other form of communication not relevant to specific City service requests;
%li
submit or otherwise make available any material that contains software viruses or any other computer code, files or programs designed to interrupt, destroy or limit the functionality of any computer software or hardware or telecommunications equipment;
%li
intentionally or unintentionally violate any applicable local, state, national or international law;
%li
&quot;stalk&quot; or otherwise harass another; or
%li
collect or store personal data about other users in connection with the prohibited conduct and activities set forth in paragraphs (a) through (k) above.
%p
You acknowledge that the City may or may not pre-screen Content that is shared, but that the City and its designees shall have the right (but not the obligation) in their sole discretion to pre-screen, refuse, or remove any Content that is available via AAH. Without limiting the foregoing, the City and its designees shall have the right to remove any Content that violates this Agreement or is otherwise objectionable. You agree that you must evaluate, and bear all risks associated with, the use of any Content, including any reliance on the accuracy, completeness, or usefulness of such Content.
%p
You acknowledge, consent and agree that the City may access, preserve and disclose your account information and Content if required to do so by law or in a good faith belief that such access preservation or disclosure is reasonably necessary to:
%ol.roman
%li
comply with legal process;
%li
enforce this Agreement;
%li
respond to claims that any Content violates the rights of third parties;
%li
respond to your requests for customer service;
%li
protect the rights, property or personal safety of the City, its users and the public.
%p
You may not attempt to override or circumvent any of the usage rules embedded into AAH.
%p
You may not trace any information of any other AAH user or visitor or otherwise use AAH for the purpose of obtaining information of any other AAH user.
%p
You may not attempt to gain unauthorized access to AAH or the computer systems and networks connected to AAH through hacking, password mining, or any other means.
%p
You may not release the results of any performance or functional evaluation of AAH to any third party without prior written approval of the City for each such release.
%p
You may not take any action that imposes, or may impose, in the City's sole discretion, an unreasonable or disproportionately large load on the City's technology infrastructure or otherwise make excessive traffic demands of AAH.
%li
%h3
Interstate Nature of Communications on Adopt-a-Hydrant
%p
When you use the application, you acknowledge that in using AAH, you will be causing communications to be sent potentially through a variety of networks (Internet service provider, wireless phone network, etc.) As a result, even communications that seem to be intrastate in nature can result in the transmission of interstate communications regardless of where you are physically located at the time of transmission. Accordingly, you agree that use of the AAH may result in interstate data transmissions.
%li
%h3
Submissions to the City
%p
By submitting feedback (&quot;Submissions&quot;) to the City through the AAH feedback function, you acknowledge and agree that:
%ol.alpha
%li
your Submissions do not contain confidential or proprietary information;
%li
the City is not under any obligation of confidentiality, express or implied, with respect to the Submissions;
%li
the City shall be entitled to use or disclose (or choose not to use or disclose) such Submissions for any purpose, in any way, in any media worldwide;
%li
the City may have something similar to the Submissions already under consideration or in development;
%li
your Submissions automatically become the property of the City without any obligation of the City to you;
%li
you are not entitled to any compensation or reimbursement of any kind from the City under any circumstances.
%li
%h3
Indemnity
%p
You agree to indemnify and hold the City and its subsidiaries, affiliates, officers, agents, employees, partners, and licensors harmless from any claim or demand (including reasonable attorneys' fees) made by any third party due to or arising out of:
%ol.alpha
%li
Content you submit or otherwise make available through AAH,
%li
your use of AAH,
%li
your connection to AAH,
%li
your violation of this Agreement,
%li
your violation of any Rights of another.
%li
%h3
Modifications to Adopt-a-Hydrant
%p
The City reserves the right at any time and from time to time to modify or discontinue, temporarily or permanently, AAH (or any part thereof) with or without notice. You agree that the City shall not be liable to you or to any third party for any modification, suspension or discontinuance of the AAH (or any part thereof).
%li
%h3
Links
%p
The City may provide links to other World Wide Web sites or resources. You acknowledge and agree that the City is not responsible for the availability of such external sites or resources.
%p
AAH may facilitate your use of third party services not provided by the City (&quot;Third Party Services&quot;). The City makes no representations or warranties regarding the performance of such Third Party Services, their compliance with applicable laws and regulations, or any other aspects of such Third Party Services. Your use of Third Party Services is at your own risk and you are solely responsible for complying with all legal and contractual requirements necessary for using Third Party Services.
%li
%h3
The City's Proprietary Rights
%p
You acknowledge and agree that AAH contains proprietary and confidential information that is owned by the City and protected by applicable intellectual property and other laws. You will not use such proprietary information in any way whatsoever except for use of AAH in compliance with the provisions of this Agreement.
%h4.upcase
Disclaimer of Warranties
%p.upcase
You expressly understand and agree that:
%ol.alpha.upcase
%li
Your use of AAH is at your sole risk. The application is provided on an &quot;as is&quot; and &quot;as available&quot; basis. The city expressly disclaims all warranties of any kind, whether express or implied, including, but not limited to the implied warranties of title, merchantability, fitness for a particular purpose and non-infringement.
%li
The city and its subsidiaries, affiliates, officers, employees, agents, partners, and licensors make no warrany that:
%ol.roman
%li
AAH will meet your requirements;
%li
AAH will be uninterrupted, timely, secore, or error-free;
%li
the results that may be obtained from the use of AAH will be accurate or reliable;
%li
any errors in the software will be corrected;
%li
AAH will be free from corruption, viruses, hacking, or other security intrusion.
%li
%h3
Limitation of Liability
%p.upcase
You expressly understand and agree that the city shall not be liable to you for any punitive, indirect, incidental, special, consequential, or exemplary damages, including, but not limtied to, damages for loss of profits, goodwill, use, data, or other intangible losses resulting from:
%ol.alpha.upcase
%li
Your access to or use of or inability to access or use the services;
%li
any conduct or content or any third party on the services, including without limitation, any defamatory, offensive or illegal conduct of other users or third parties;
%li
any content obtained from the services;
%li
unauthorized access, use or alteration of your transmissions or content, whether based on warranty, contract, tort (including negligence) or any other legal theory, whether or not the city has been informed of the possibility of such damage, and even if a remedy set forth herein is found to have failed of its essential purpose.
%p.upcase
You expressly agree that the city is not responsible for any contact or interaction between you and any other user of AAH and that you bear the sole risk of transmitting through the application any content, including information which identifies you or your location.
%p.upcase
You agree that the negation of damages set forth above is a fundamental element of the basis of the bargain between the city and you and that the foregoing limitation of liability is an agreed upon allocation of risk between you and the city. You acknowledge that absent your agreement to this limitation of liability the city would not provide AAH to you.
%li
%h3
Notice
%p
The City may provide you with notices regarding AAH, including changes to this Agreement, by email, SMS, text message, postings on AAH, or any other reasonable means now known or hereafter developed. Notices shall be effective immediately.
%p
Such notices may not be received if you violate this Agreement by accessing the AAH in an unauthorized manner. You agree that you will be deemed to have received any and all notices that would have been delivered had you accessed AAH in an authorized manner.
%li
%h3
Minor
%p
You represent that you are 13 years of age or older and, if you are under the age of 18, you either are an emancipated minor, or have obtained the legal consent of your parent or legal guardian to accept and agree to be bound by the terms and provisions of this Agreement.
%p
If you have agreed to allow your minor child, or a child for whom you are legal guardian (&quot;Minor&quot;), to use AAH, you agree that you shall be solely responsible for:
%ol.alpha
%li
the online conduct of such Minor,
%li
monitoring such Minors access to and use of AAH, and
%li
the consequences of any use of AAH by such Minor.
%li
%h3
Governing Law and Venue
%p
This Agreement is governed by the laws of the Commonwealth of Massachusetts without regard to any conflict of law provisions. You agree that any claim or dispute with the City relating in any way to your use of AAH shall be brought exclusively before a state or federal court sitting in Boston, Massachusetts, and you irrevocably waive any jurisdictional, venue, or inconvenient forum objections to such courts.
%li
%h3
Miscellaneous
%p
This Agreement constitutes the entire agreement between you and the City with respect to your use of AAH, superseding any prior version of this Agreement between you and the City with respect to AAH.
%p
If any provision of this Agreement shall be unlawful, void, or unenforceable, then that provision shall be deemed severed from this Agreement and shall not affect the validity or enforceability of the remaining provisions of this Agreement.
%p
The City's failure to assert any right or provision under this Agreement shall not constitute a waiver of such right or provision.
%p
You agree that any cause of action arising out of or related to your use of AAH must commence within one year after the cause of action accrues. Otherwise, such cause of action is permanently barred.
%p
The section titles in this Agreement are for convenience only and have no legal or contractual effect.
%p
Last updated August 10, 2011.

View File

@ -8,7 +8,6 @@ AdoptAThing::Application.routes.draw do
get 'address' => 'addresses#show', :as => 'address' get 'address' => 'addresses#show', :as => 'address'
get 'info_window' => 'info_window#index', :as => 'info_window' get 'info_window' => 'info_window#index', :as => 'info_window'
get 'sitemap' => 'sitemaps#index', :as => 'sitemap' get 'sitemap' => 'sitemaps#index', :as => 'sitemap'
get 'tos' => 'info_window#tos', :as => 'tos'
scope "sidebar", :controller => :sidebar do scope "sidebar", :controller => :sidebar do
get :search, :as => 'search' get :search, :as => 'search'

View File

@ -68,11 +68,4 @@ class InfoWindowControllerTest < ActionController::TestCase
assert_template 'users/sign_in' assert_template 'users/sign_in'
assert_select 'h2', 'Sign in to adopt this Hydrant' assert_select 'h2', 'Sign in to adopt this Hydrant'
end end
test 'should show terms of service' do
get :tos
assert_response :success
assert_template 'info_window/tos'
assert_select 'h2', 'Terms of Service'
end
end end