Hi guys

I'm using this module in production, it just saved me ! Easy to use for simple node theming, and with some CSS it's jsut great !

Is it planned to make it compatible with Webforms ? I know webform is a "special module", because webforms are not really nodes... I tried today to render a webform with Display suite, using the Node layout functionnality. And guess what ? DS renderd everything correctly (text before the form, CCK image field), apart from the form itself...

Hope you can make it, this will make this module even more awesome !

Comments

swentel’s picture

Yeah, we normally set of the rendering by DS - I'll look for the right key for webforms this weekend. I'm pretty sure, this will be an key in the node object which you could use in admin/ds/nd/fields

swentel’s picture

Ok, you can create a field at admin/ds/nd/fields, create a code field, enter a key and title (can be anything) and use following php code:

  return $object->content['webform']['#value'];

Exclude it for all other content types except for webform too. This field will show up and you can drag it around where you like than.

swentel’s picture

Status: Active » Fixed

Added to snippets page too.

swentel’s picture

Status: Fixed » Closed (fixed)
jax’s picture

Status: Closed (fixed) » Active

This isn't working anymore. The body nor the form are displaying.

jax’s picture

Status: Active » Closed (fixed)

Never mind. In the teaser build mode the webform module doesn't render the form. You need to either use the full build mode or set the configuration on the webform to show the complete form in the teaser.

Anonymous’s picture

In Drupal 7 this seems to have changed. It seems as though the "value" array item is no longer present. I think rendering the form should be done somewhat similarly to below, but haven't been able to actually print any thing out. Just wondering if anyone else has gotten this work correctly.

<?php
  print render($entity->webform['components']);
?>
Anonymous’s picture

Status: Closed (fixed) » Active
swentel’s picture

Status: Active » Fixed

see #1040834: Refactor webform_field_extra_fields() - this patch will go in webform in the next release, so you can apply that patch safely to the current codebase of webform. This will make the 'webform' field available by default.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.