Template:2012FR/Form-section/Radiobuttons/5-buttons: Difference between revisions
Content deleted Content added
No edit summary |
update |
||
Line 1:
<html>
<style
#radiobuttons-table-header {
font-weight: bold;
font-size: 1.3em;
margin-bottom: 0.8em;
}
.frequency-options {
margin
}
#radiobuttons-table {
font-size: 1.2em;
}
Line 30 ⟶ 29:
</style>
<script
function clearOther(box) {
document.getElementById("input_amount_other").checked = true;
Line 46 ⟶ 45:
}
$(document).ready(function() {
$(".frequency-options label").click(function() {
$(".frequency-options label").removeClass("checked");
$(this).addClass("checked");
});
$(".radiobuttons-cell label").click(function() {
$(".radiobuttons-cell label").removeClass("checked");
$(this).addClass("checked");
});
$(".input_amount_other").click(function() {
$("#input_amount_other_box").focus();
});
// hide frequency options in India, where we can only handle one-time donations
if (document.paypalcontribution.country.value === 'IN') {
$("#frequency_onetime").attr('checked', true);
$(".frequency-options").hide();
$("#cancel-monthly").hide();
}
});
</script>
Line 67 ⟶ 77:
</div>
<div id="radiobuttons-table-body">
<table id="radiobuttons-table">
<tr>
<td class="radiobuttons-cell">
<input type="radio" name="amount" id="input_amount_0" onclick="selectAmount();" value="</html>{{{donate-amount-0}}}<html>" />
<label for="input_amount_0"></html>{{2012FR/CurrencyFormat|{{{donate-amount-0}}}|{{{currency}}}|{{{country}}}|{{{language}}}}}<html></label>
</td>
<td class="radiobuttons-cell">
<input type="radio" name="amount" id="input_amount_1" onclick="selectAmount();" value="</html>{{{donate-amount-1}}}<html>" />
<label for="input_amount_1"></html>{{2012FR/CurrencyFormat|{{{donate-amount-1}}}|{{{currency}}}|{{{country}}}|{{{language}}}}}<html></label>
</td>
<td class="radiobuttons-cell">
<input type="radio" name="amount" id="input_amount_2" onclick="selectAmount();" value="</html>{{{donate-amount-2}}}<html>" />
<label for="input_amount_2"></html>{{2012FR/CurrencyFormat|{{{donate-amount-2}}}|{{{currency}}}|{{{country}}}|{{{language}}}}}<html></label>
</td>
</tr>
<tr>
<td class="radiobuttons-cell">▼
</td>▼
<td class="radiobuttons-cell">
<input type="radio" name="amount" id="
<label for="
</td>
<td class="radiobuttons-cell">
<input type="radio" name="amount" id="
<label for="
▲ </td>
<input type="text" id="input_amount_other_box" size="3" autocomplete="off" value="" onfocus="clearOther(this)"/>▼
<input type="radio" name="amount" id="input_amount_other" value="Other" onclick="document.getElementById('input_amount_other_box').focus();">
<label for="input_amount_other">
<span></html>{{int:donate_interface-other}}<html></span>
▲ <input type="text" id="input_amount_other_box" size="3" autocomplete="off" value="" onfocus="clearOther(this);"
</label>
</td>
</tr>
</table>
</div>
</html>
|