CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviContribute (Moderator: Donald Lobo) »
  • Some appearance fixes for the Contribution Page template
Pages: [1]

Author Topic: Some appearance fixes for the Contribution Page template  (Read 460 times)

ken

  • I live on this forum
  • *****
  • Posts: 916
  • Karma: 53
    • City Bible Forum
  • CiviCRM version: 4.6.3
  • CMS version: Drupal 7.36
  • MySQL version: 5.5.41
  • PHP version: 5.3.10
Some appearance fixes for the Contribution Page template
January 06, 2011, 06:14:15 pm
When I turn on 'pay later' or 'pledges' on a Contribution Page, these fields 'run in' together.

I notice that while other features on the page have a 3 <div>'s ('label', 'content', and 'clear') these features only have 1 ('content'). The absence of the 'label' pushes these features to the left, and the abcense of the 'clear' causes them to run in together.

Below is a patch I've applied to my system to align these features, as well as the features for 'recurring payment', 'PCP supporter', and 'for organisation'. I don't use these last 3 so those changes should be tested before use.

Ken

Code: [Select]
--- /data/Download/CiviCRM/civicrm-3.3.2-drupal/templates/./CRM/Contribute/Form/Contribution/Main.tpl 2010-12-30 20:36:29.000000000 +1100
+++ /data/Work/IT/CiviCRM/Local/3.3.2/templates/./CRM/Contribute/Form/Contribution/Main.tpl 2011-01-07 09:11:54.433635000 +1100
@@ -95,6 +95,7 @@
      </div>
      {else}
      <div class="crm-section {$form.is_pledge.name}-section">
+ <div class="label">&nbsp;</div>
  <div class="content">
  {$form.is_pledge.html}&nbsp;
  {if $is_pledge_interval}
@@ -102,31 +103,38 @@
  {/if}
  {$form.pledge_frequency_unit.html}&nbsp;{ts}for{/ts}&nbsp;{$form.pledge_installments.html}&nbsp;{ts}installments.{/ts}
  </div>
+ <div class="clear"></div>
      </div>
      {/if}
  {/if}
 {/if}
  {if $form.is_pay_later}
      <div class="crm-section {$form.is_pay_later.name}-section">
+ <div class="label">&nbsp;</div>
  <div class="content">{$form.is_pay_later.html}&nbsp;{$form.is_pay_later.label}</div>
+ <div class="clear"></div>
      </div>
  {/if}
  {if $form.is_recur}
      <div class="crm-section {$form.is_recur.name}-section">
- <div class="content">
- <p><strong>{$form.is_recur.html} {ts}every{/ts} &nbsp;{$form.frequency_interval.html} &nbsp; {$form.frequency_unit.html}&nbsp; {ts}for{/ts} &nbsp; {$form.installments.html} &nbsp;{$form.installments.label}</strong>
- </p>
- <p><span class="description">{ts}Your recurring contribution will be processed automatically for the number of installments you specify. You can leave the number of installments blank if you want to make an open-ended commitment. In either case, you can choose to cancel at any time.{/ts}
+ <div class="label">&nbsp;</div>
+ <div class="content">
+ <p><strong>{$form.is_recur.html} {ts}every{/ts} &nbsp;{$form.frequency_interval.html} &nbsp; {$form.frequency_unit.html}&nbsp; {ts}for{/ts} &nbsp; {$form.installments.html} &nbsp;{$form.installments.label}</strong>
+ </p>
+ <p><span class="description">{ts}Your recurring contribution will be processed automatically for the number of installments you specify. You can leave the number of installments blank if you want to make an open-ended commitment. In either case, you can choose to cancel at any time.{/ts}
          {if $is_email_receipt}
              {ts}You will receive an email receipt for each recurring contribution. The receipts will include a link you can use if you decide to modify or cancel your future contributions.{/ts}
          {/if}
          </p>
-     </div>
+ </div>
+ <div class="clear"></div>
      </div>
  {/if}
  {if $pcpSupporterText}
      <div class="crm-section pcpSupporterText-section">
+ <div class="label">&nbsp;</div>
  <div class="content">{$pcpSupporterText}</div>
+ <div class="clear"></div>
      </div>
  {/if}
      {assign var=n value=email-$bltID}
@@ -140,9 +148,11 @@
 
  {if $form.is_for_organization}
  <div class="crm-section {$form.is_for_organization.name}-section">
+ <div class="label">&nbsp;</div>
      <div class="content">
      {$form.is_for_organization.html}&nbsp;{$form.is_for_organization.label}
      </div>
+ <div class="clear"></div>
      </div>
  {/if}
 

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviContribute (Moderator: Donald Lobo) »
  • Some appearance fixes for the Contribution Page template

This forum was archived on 2017-11-26.