From a8bd5a21296d98a843871711954adb11f6a10dfb 2015-03-09 05:08:14 From: Bradley M. Kuhn Date: 2015-03-09 05:08:14 Subject: [PATCH] Leave text w/ percentage when no progressbar The progressbar is generated by Javascript. As such, the text here won't have a progressbar formatted around it when the browser doesn't support Javascript. However, since the Javascript does update the text, we can format the Django template to put in place text that we wish will appear when no Javascript is turned on, and then allow the Javascript to make it right when it's available. Graceful degradation: I may be its last proponent. --- diff --git a/www/conservancy/static/npoacct/index.html b/www/conservancy/static/npoacct/index.html index c2e8821af71377b5308a336038394c837a3a3f22..55a6bf55980945c386ca2730cb5114fbe54d16c8 100644 --- a/www/conservancy/static/npoacct/index.html +++ b/www/conservancy/static/npoacct/index.html @@ -106,7 +106,7 @@ el.attachEvent('on'+ev, function() {handler.apply(el);});

Support NPO Accounting Project Now!

${{ fundgoal.fundraiser_so_far_amount|floatformat:0|intcomma }} raised toward
our ${{ fundgoal.fundraiser_goal_amount|floatformat:0|intcomma }} goal.
-
{{ fundgoal.percentage_there|floatformat:1 }}%
+
(i.e., {{ fundgoal.percentage_there|floatformat:1 }}%)

(Progress bar updated daily.)

Help us reach our goal:

diff --git a/www/conservancy/templates/base_compliance.html b/www/conservancy/templates/base_compliance.html index ec92a219158472a010ca5f9c1d9c1594108bbae0..eda3cd7ef45e47db2089fee1a8bf038dc3f5daeb 100644 --- a/www/conservancy/templates/base_compliance.html +++ b/www/conservancy/templates/base_compliance.html @@ -22,7 +22,7 @@ ${{ fundgoal.fundraiser_so_far_amount|floatformat:0|intcomma }} of ${{ fundgoal.fundraiser_goal_amount|floatformat:0|intcomma }} match met.
-
{{ fundgoal.percentage_there|floatformat:1 }}%
+
(i.e., {{ fundgoal.percentage_there|floatformat:1 }}%)

Donate now via PayPal: