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 (Moderator: Dave Greenberg) »
  • Overriding Profile templates from the User Registration page
Pages: [1]

Author Topic: Overriding Profile templates from the User Registration page  (Read 3205 times)

lchanggt

  • Guest
Overriding Profile templates from the User Registration page
November 17, 2008, 09:36:53 pm
Hi,

I'm having problems overriding the civicrm profile template on the new user registration page.

In my template directory:  civicrm_templates/CRM/Profile/Form/5
I have both a Edit.tpl and a Dynamic.tpl

The Edit.tpl is being read from when I goto /civicrm/profile/edit?gid=5&reset=1 and is overriding the page fine.

However, Dynamic.tpl is not being read when I goto /user/register in Drupal.   If I create a Dynamic.tpl in civicrm_tempaltes/CRM/Profile/Form it is read, but I don't want this to affect every thing that uses the Dynamic.tpl file.

What could I be doing wrong?  I want to ensure that the changes I'm making are specific to the Profile ID 5 on the user registration page because I'm doing a lot of custom layout work on this page.

Also, how can I get smartyDebug=1 to work on the /user/register page? 

THanks,
--Leo

« Last Edit: November 17, 2008, 09:41:52 pm by lchanggt »

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: Overriding Profile templates from the User Registration page
November 18, 2008, 06:26:25 am

This should be considered as a missing feature :( (u can argue that it is a bug)

The problem is multiple profiles can be included in the register page, hence we cannot select one profile ID and use the more generic Dynamic.tpl. If you want to hack it, u can change the line of code at: CRM/Core/BAO/UFGroup.php, line 499

To get debug for the register page add

{debug}

manually to the first line of CRM/Profile/Form/Dynamic.tpl

That page is controlled by drupal and we dont go thru our theming layers as much

thanx

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

lchanggt

  • Guest
Re: Overriding Profile templates from the User Registration page
November 18, 2008, 03:07:06 pm
Thanks for the feedback. 

I think there's another bug too, because any custom data that I've put into my Profile isn't showing up on the user registration page.  Only the built-in CiviCRM fields like address and job title are showing up.  Is that correct?

--leo


Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: Overriding Profile templates from the User Registration page
November 18, 2008, 06:44:41 pm

you should check and ensure that anon user has "access all custom data" in drupal permisisons

the permissions is not "as liberal" as it sounds, so dont be wary of enabling it :)

lobo


A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM (Moderator: Dave Greenberg) »
  • Overriding Profile templates from the User Registration page

This forum was archived on 2017-11-26.