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) »
  • customizing contribution page
Pages: [1]

Author Topic: customizing contribution page  (Read 4748 times)

digitalslacker

  • I’m new here
  • *
  • Posts: 5
  • Karma: 0
customizing contribution page
October 25, 2010, 05:03:28 pm
I've been working on customizing two contribution pages. One is a membership page and the other is a plain donation page.
I have been using this resource I found (thanks lobo) in the forum. http://wiki.civicrm.org/confluence/display/CRMDOC32/Customize+Built-in,+Profile,+Contribution+and+Event+Registration+Screens

That's gotten me almost all the way but I have one more problem.
I'm trying to stylize the buttons at the bottom of the page ("Make Contribution", "Continue", "Go Back", etc.)

There are two approaches I have tried and neither got me all the way there.

1) Style out the button with a plain background image and change the text on each step of each page as I need to.
ISSUE: I can't figure out how to change the button text and have it needs to be different for each page. So Step 1 of the membership page says "Review Your Membership" and step 2 would say "Submit Your Membership". Same logic for the donation page. Might be simple but it's eluded me.

2) Style out the button with an image that contains the text already.
ISSUE: There doesn't seem to be any anchor points on the CSS that lets me style the donation page and membership pages differently. My client wants the language consistent and different for each page.

I do know that I can use a .tpl file to customize areas of the contribution pages and i read that I can use a /1/ or /2/ to change them based on the ID of the contribution page. I wasn't really able to tell though how I could change the text because it's stored in some array.

I feel like this should be possible based on everything I have looked at and that I'm just missing something easy.

Disclaimer, I'm a developer but php isn't my expertise and I'm fairly new to drupal and civi.

I would appreciate a bump in the right direction.

digitalslacker

  • I’m new here
  • *
  • Posts: 5
  • Karma: 0
Re: customizing contribution page
October 27, 2010, 04:56:21 am
*bump*
anyone? or is what i'm trying just not possible?

xavier

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4453
  • Karma: 161
    • Tech To The People
  • CiviCRM version: yes probably
  • CMS version: drupal
Re: customizing contribution page
October 27, 2010, 01:27:44 pm
Hi, if you want two different profiles, you can set different profiles (clone it) and have different templates per profile (/1 /2).

Quote from: digitalslacker on October 25, 2010, 05:03:28 pm
1) Style out the button with a plain background image and change the text on each step of each page as I need to.
ISSUE: I can't figure out how to change the button text and have it needs to be different for each page. So Step 1 of the membership page says "Review Your Membership" and step 2 would say "Submit Your Membership". Same logic for the donation page. Might be simple but it's eluded me.


Not sure I understand: you have been able to style the button, but are not happy with the existing text on the button ?

It has nothing to do with the layout, but with changing the text, correct ?

(on the latest 3.2 version you have an option to replace one text by another without having to change code)

Quote from: digitalslacker on October 25, 2010, 05:03:28 pm

2) Style out the button with an image that contains the text already.
ISSUE: There doesn't seem to be any anchor points on the CSS that lets me style the donation page and membership pages differently. My client wants the language consistent and different for each page.

I do know that I can use a .tpl file to customize areas of the contribution pages and i read that I can use a /1/ or /2/ to change them based on the ID of the contribution page. I wasn't really able to tell though how I could change the text because it's stored in some array.


The number is the number of the profile, not the countribution page, isn't it ?

Otherwise, yes, it might be that the button is an html blob indeed (could you paste the relevant smarty part) ?

The easiest is to code the html button directly (pretty sure the name is static, ie. you can hard code it), and don't display the html blob.

X+
-Hackathon and data journalism about the European parliament 24-26 jan. Watch out the result

digitalslacker

  • I’m new here
  • *
  • Posts: 5
  • Karma: 0
Re: customizing contribution page
October 27, 2010, 05:26:32 pm
xavier you are awesome.
i got too close to it and never even thought about just conditionally hard coding the buttons....
I over complicated it


for others...in your custom Main.tpl
Code: [Select]
<div id="crm-submit-buttons" class="crm-submit-buttons">
     <span class="crm-button crm-button-type-upload crm-button_qf_Main_upload">

    {if $priceSet}
    <input class="form-submit default" name="_qf_Main_upload" value="Confirm Contribution" type="submit" id="_qf_Main_upload-bottom" style="background:url('/crm_files/donationreview.gif') no-repeat scroll left top #70716B !important;" />
    {else}
                   <input class="form-submit default" name="_qf_Main_upload" value="Confirm Contribution" type="submit" id="_qf_Main_upload-bottom" style="background:url('/crm_files/membershipreview.gif') no-repeat scroll left top #70716B !important;"/>
    {/if}
</span>
    </div>


the if $priceset seems to be the trick to conditionally determining if it's a donation page or a membership page.

thanks again



stevethepug

  • I’m new here
  • *
  • Posts: 20
  • Karma: 0
Re: customizing contribution page
November 10, 2010, 11:24:39 am
"on the latest 3.2 version you have an option to replace one text by another without having to change code"

I too would like to change the text on the contribution button and would love to do it without changing code. I'm using 3.2 but can't find where to do this.... can you point me in the right direction?

petednz

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4899
  • Karma: 193
    • Fuzion
  • CiviCRM version: 3.x - 4.x
  • CMS version: Drupal 6 and 7
Re: customizing contribution page
November 10, 2010, 12:15:19 pm
You might be looking for Word Replacement - under Admin > Option list or http://drupal.demo.civicrm.org/civicrm/admin/options/wordreplacements&reset=1
Sign up to StackExchange and get free expert advice: https://civicrm.org/blogs/colemanw/get-exclusive-access-free-expert-help

pete davis : www.fuzion.co.nz : connect + campaign + communicate

stevethepug

  • I’m new here
  • *
  • Posts: 20
  • Karma: 0
Re: customizing contribution page
November 11, 2010, 01:10:31 am
Thank you! This looks like a great feature and I had no idea it was there  :)

Fred

  • I post occasionally
  • **
  • Posts: 37
  • Karma: 1
  • CiviCRM version: 4.x
  • CMS version: Joomla 3.x
  • MySQL version: 5.x
  • PHP version: 5.x
Re: customizing contribution page
December 12, 2013, 02:56:16 pm
Quote from: petednz on November 10, 2010, 12:15:19 pm
You might be looking for Word Replacement - under Admin > Option list or http://drupal.demo.civicrm.org/civicrm/admin/options/wordreplacements&reset=1
I'm running Joomla 3.1.5 with CiviCRM 4.4.3, but can't find an 'Option List' under the Administer menu. Is there a way to configure the Contribution button text that works with Joomla/civiCRM/

joanne

  • Administrator
  • Ask me questions
  • *****
  • Posts: 852
  • Karma: 83
  • CiviCRM version: 4.4.16
  • CMS version: Drupal 7
Re: customizing contribution page
December 12, 2013, 03:04:42 pm
The menus have changed since 2010.  Location is  Administer › Customize Data and Screens › Word Replacements

Fred

  • I post occasionally
  • **
  • Posts: 37
  • Karma: 1
  • CiviCRM version: 4.x
  • CMS version: Joomla 3.x
  • MySQL version: 5.x
  • PHP version: 5.x
Re: customizing contribution page
December 12, 2013, 08:33:21 pm
Thank you. I've found the 'Word Replacement' under Administer > Customize Data and Screens > Word Replacements, and have been able to use it to change 'Contribute' to 'Submit' on the contribution form, but I can't get it to change 'I am contributing on behalf of an organization.' to 'I am registering on behalf of an organization.', or to just change 'contributing' to 'registering'. Any suggestions on how to change 'I am contributing on behalf of an organization.' to 'I am registering on behalf of an organization.'?

Fred

  • I post occasionally
  • **
  • Posts: 37
  • Karma: 1
  • CiviCRM version: 4.x
  • CMS version: Joomla 3.x
  • MySQL version: 5.x
  • PHP version: 5.x
Re: customizing contribution page
December 12, 2013, 08:42:24 pm
I found it. The 'I am contributing on behalf of an organization.' text can be customized under the 'Manage Contribution Pages'  'title and settings' screen.

joanne

  • Administrator
  • Ask me questions
  • *****
  • Posts: 852
  • Karma: 83
  • CiviCRM version: 4.4.16
  • CMS version: Drupal 7
Re: customizing contribution page
December 12, 2013, 08:46:10 pm
Please don't post the same question in two places.  One of us has been wasting their time answering your duplicate post. 

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviContribute (Moderator: Donald Lobo) »
  • customizing contribution page

This forum was archived on 2017-11-26.