Guest
17 Feb 2014 10:01

I have a custom template where I call fields by ID,

but I still want to keep the grouped fields call (fields set as "grouped" and displaied in tabs below the fields I call with ID)

To do so I commented out some parts of the template, and left there other ones that I believed were there to call grouped fields... but I must have made something wrong because the tabs are not working correcty (see here http://direct.alkemica.net/eventi1/voce/5-corsi/59-nato-due-volte-osho-tantra ) and my php knowledge is not enough to understand where the error is...

I attach the template file, if anyone has time please take a look at it and tell me which parts should I comment to achieve what I want.

thank you!

Last Modified: 02 Mar 2014


Guest
17 Feb 2014 10:05

ok, it seems I solved this by trial and error

but still the tabs have a strange look... not sure if it due to the code commented in the template though


Sergey
Total posts: 13,748
19 Feb 2014 01:37

What is the editor you use to edit files? You need to configure it to have unix type line endings. When I open it it adds new line after every break.

You have commented line

item->fields_by_groups[null]);?>

It should be before

get('tmpl_params.item_grouping_type', 0), array(1)) && count($this->item->fields_by_groups)): ?>

Cannot tell you line because I have extra lines there.

This will delete ungrouped fields from be in tabs.


Guest
19 Feb 2014 03:40

I use sublime text 2 editor

thank yuo, i managed to do it by trial and error, but I'll have a further look!


Sergey
Total posts: 13,748
19 Feb 2014 23:23

I expect you use it on Windows. by default it hase SYSTEM for line endings.

Open user preferences and add there

{

    "font_size": 12.0,

    "default_line_ending": "unix"

}

Font size is an example.

Powered by Cobalt