0

I'm using ThemeKey to switch my theme for mobile users. The problem i'm having is that i'm using image zoom for my products and on iphones it blocks the dropdown due to a hidden element. My question is, is it possible to change the way a content type is displayed per theme without disturbing the regular 'desktop' version of the site?

Clarification: What I'm referring to is when you go to Manage Display, how can you reposition content entities differently per theme.

1

Those settings are one per content type and will be applied for all themes you enabled.

I suggest to do that within the themes themselves - start by adding the node--[content type machine name].tpl.php and then exclude/move around the fields you need.

Example for hiding a specific field:

hide($content['field_name_goes_here']);

Other useful things:

hide($content['links']);
hide($content['comments']);

To see a full list of fields and exact names, install devel and do a dpm($content); in tpl file.

Also check the template_preprocess_node() function for more and better control of the fields values.

  • Are are Technically correct but my problem is I'm not using a custom template file for my site. I'm using DS and this is enough as far as customization. Is there any other way to accomplish this without creating a new template? – Digital fire Sep 6 '12 at 20:12
  • As far as I know you can't, but I'm not so sure as I didn't use DS that much. – Aram Boyajyan Sep 7 '12 at 8:13

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.