Commit graph

2152 commits

Author SHA1 Message Date
Bradley M. Kuhn
1574b2dc37 Match right form for these changes.
The general selectors previously used here matched either form.  With
this change, they will only match the form for which the selection was
actually made.
2014-12-03 21:09:25 -05:00
Bradley M. Kuhn
2d96daee90 Rework Javascript final form validation.
The problem before was that an error in the annual form would prevent
submission of the monthly form and vice-versa.  That is herein corrected
with this change, which assures that the input with id of "amount" if
the specific form (id'd with "annual" or "monthly") is the only one
checked.
2014-12-03 20:44:15 -05:00
Bradley M. Kuhn
9c40bf2e60 supporter-form & support-form-submit: class,not id
These should be classes, not ids, and the ids should identify whether
it's the monthly or the annual form.
2014-12-03 20:43:28 -05:00
Bradley M. Kuhn
8c3ecd347a Return amount to id; add id for error span.
I actually think I want amount to be id rather than a class, now that I
figured out the proper selector to find them all.

Also, the $("span", input.parent()) was buggy if there were any other
span's other than error-related ones in the supporter-form-inputs div.

Finally, ditch that <small> stuff and simply place a font-size reduction
into the CSS for the form-error-show.
2014-12-03 20:42:33 -05:00
Bradley M. Kuhn
6b9bdb335e Modify PayPal "no_shipping" var via t-shirt choice
According to
https://developer.paypal.com/docs/classic/paypal-payments-standard/integration-guide/Appx_websitestandard_htmlvariables/

  no_shipping has the following values:
      0: prompt for an address, but do not require one
      1: do not prompt for an address
      2: prompt for an address, and require one
      The default is 0.

Ideally, any time they change wantGift, even in a pure HTML form, we'd
change it between 0 and 2 as appropriate (i.e., we need the address if
they want the t-shirt).

However, I couldn't find an easy way to make this modification in pure
CSS or HTML, so it only happens in Javascript-enabled browsers.

This is still graceful degradation, since the only impact is in cases
where a non-Javascript user fails to give us an address, and we have to
email later to get the shipping address.
2014-12-03 18:50:53 -05:00
Bradley M. Kuhn
e0f0ee820f Monthly supporter can enter variable amount.
This required some doing.  I'm not completely sure it works, but I
roughly followed the tutorial available at:
  https://www.paypal.com/webapps/mpp/get-started/create-recurring-donation-button
with back-reference to this:
  https://developer.paypal.com/docs/classic/paypal-payments-standard/integration-guide/Appx_websitestandard_htmlvariables/

My main concern with this setup currently is that 'p3' must be set to
'1', which would seem from the documentation to be saying the payment
will recur only once.  There is a subtle hint via the tutorial that
setting 'src' to 1 will override 'p3' with whatever is found in 'srt',
but that's not said anywhere explicitly that I can find.  So, I'm going
with this and I'll just test it myself with a monthly subscription to
see if it's indefinite (which is the behavior we herein desire).

Finally, note that "amount" is now a class rather than id, since I'm now
using the associated jQuery .on('input') code for both the annual and
monthly amount boxes.
2014-12-03 18:10:45 -05:00
Bradley M. Kuhn
58f45a556b Typo fix. (HT: pehjota) 2014-12-03 17:44:38 -05:00
Bradley M. Kuhn
342590123f Fix typo. 2014-12-03 16:55:17 -05:00
Bradley M. Kuhn
eea08767d3 Change default to "no t-shirt".
I suspect some supporters are just accepting the default, so by default,
the t-shirt option will be "No", and supporters will have to
affirmatively chose "Yes".

Thanks to previously committed Javascript hack, users with Javascript
capable browsers should avoid seeing the t-shirt sizing options until
they chose "Yes".
2014-12-03 16:20:57 -05:00
Bradley M. Kuhn
a61e246db1 Add supporter. 2014-12-03 15:54:03 -05:00
Bradley M. Kuhn
9f1b3710da Add supporter. 2014-12-03 15:31:31 -05:00
Bradley M. Kuhn
83cfcfacfb Corrected endblock. 2014-12-03 14:27:47 -05:00
Bradley M. Kuhn
bc5f1b6c63 Add another supporter. 2014-12-03 14:26:55 -05:00
Bradley M. Kuhn
08275e0cbb Another supporter. 2014-12-03 14:19:01 -05:00
Bradley M. Kuhn
3256391c99 Remove male dominated placeholder. 2014-12-03 13:49:06 -05:00
Bradley M. Kuhn
f1c46c481d Move support higher up. 2014-12-03 13:48:09 -05:00
Bradley M. Kuhn
33025998fb Shorten title, reword information. 2014-12-03 13:47:50 -05:00
Bradley M. Kuhn
50cf881501 Add supporter program to front page. 2014-12-03 13:46:44 -05:00
Bradley M. Kuhn
27276109ad Add copyleft.org and NPO Acct to "Learn more" link 2014-12-03 13:46:29 -05:00
Bradley M. Kuhn
093400150a Create a new update. 2014-12-03 13:41:24 -05:00
Bradley M. Kuhn
7fec31ce8a Hide t-shirt size selector when t-shirt's unwanted
Use Javascript to hide the t-shirt size selector when the the user
selects "No" for "Do you want a t-shirt?".  Reshow it (and make sure
it's shown by default) for "Yes".
2014-12-03 13:33:26 -05:00
Bradley M. Kuhn
fcbb3b5085 Supporter means /supporter/ now, so change this. 2014-12-03 13:16:40 -05:00
Bradley M. Kuhn
d737a5e567 Correct typo. 2014-12-03 13:14:48 -05:00
Bradley M. Kuhn
08f45ac79b Skip more space here. 2014-12-03 13:11:34 -05:00
Bradley M. Kuhn
3ae6bbd937 These should be h2 headings. 2014-12-03 12:51:21 -05:00
Bradley M. Kuhn
0ef0fdf43f Note that the logos are the sponsors. 2014-12-03 12:36:53 -05:00
Bradley M. Kuhn
e926570ec5 Link to the public list. 2014-12-03 12:34:53 -05:00
Bradley M. Kuhn
2a470bc7cc <hr> is really needed here. 2014-12-03 12:34:43 -05:00
Bradley M. Kuhn
6bf2340453 Add first three supporters to sign up. 2014-12-03 12:29:29 -05:00
Bradley M. Kuhn
ba50cd0232 SVG bullet list of supporters on sponsors page.
This CSS, which I discovered from extensive research online, should work
to create a bulleted list with the bullets being the heart-shaped
Conservancy logo.
2014-12-03 12:29:24 -05:00
Bradley M. Kuhn
ece5b2581b Add missing close brace. 2014-12-03 12:27:32 -05:00
Bradley M. Kuhn
04d927961d Rework page so that it can include supporters too. 2014-12-03 10:57:10 -05:00
Bradley M. Kuhn
8ce79c7efd Put hr tag inside this div to inherit properties. 2014-12-03 09:58:52 -05:00
Bradley M. Kuhn
b9b4695f97 Match width and alignment to donate-content class. 2014-12-03 09:58:07 -05:00
Bradley M. Kuhn
5014455930 Remove http://sfconservancy.org; this is that site 2014-12-03 08:46:58 -05:00
Bradley M. Kuhn
c24285c461 Links to project websites. 2014-12-03 08:45:01 -05:00
Bradley M. Kuhn
81a73acec4 Shorten text. 2014-12-02 20:57:46 -05:00
Bradley M. Kuhn
ee7125fd31 Full name of this project, and a link. 2014-12-02 18:31:13 -05:00
Bradley M. Kuhn
f042c375be Use em padding here, and a little less of it. 2014-12-02 18:30:15 -05:00
Bradley M. Kuhn
8291c3db2e Reword text again. 2014-12-02 18:29:06 -05:00
Bradley M. Kuhn
b6b94e3206 Clarify no benefits received until 12 months. 2014-12-02 18:27:22 -05:00
Bradley M. Kuhn
44301d386b Correct Markdown-style footnote w/ HTML style one.
This footnote is now correctly formatted in HTML, with links back and
forth, as well as a jQuery UI tooltip popup for the footnote.
2014-12-02 18:25:42 -05:00
Bradley M. Kuhn
c41a897be2 Simply clear error for monthly donation.
Since the error messages relate only to the amount entered, the error
message should be cleared when switching to the monthly giving option.
2014-12-02 18:02:32 -05:00
Bradley M. Kuhn
c546833984 Amount starts class "valid", when default accepted
The default amount of $120 appears in the amount field, but the class
"valid" was usually only added when the user changes the amount.

The valid class must be added at the start to ensure someone simply
clicking with the default still can donate.
2014-12-02 17:58:39 -05:00
Bradley M. Kuhn
9aa9e73a91 600px seems better here than 500px. 2014-12-02 17:55:06 -05:00
Bradley M. Kuhn
009cc20555 Avoid donate-sidebar on small screens.
The donate-sidebar overlaps with text on small screens.  This problem is
corrected herein by using @media for 500px screens to remove display of
the sidebar.
2014-12-02 17:51:32 -05:00
Bradley M. Kuhn
dbe8d4f238 Remove hard-coded style= for donate-sidebar div
Move the CSS for the donate-sidebar into the conservancy.css file
instead of hard-coding in the HTML.
2014-12-02 17:51:10 -05:00
Bradley M. Kuhn
19ef9d196b Fix missing trailing newline. 2014-12-02 17:49:20 -05:00
Bradley M. Kuhn
1b96df2224 Use em here so that the button is a bit closer. 2014-12-02 17:49:10 -05:00
Bradley M. Kuhn
3dd381cddb Make error text even shorter. 2014-12-02 17:35:31 -05:00