Here is what I am trying to do. I have ddblock and imagefield as well as all of the required modules and currently they both are working. I want to set it up where the user is not required to upload an image for the slider, So I enabled the imagefield default image. The default image works with the views and nodes but does not show up in ddblock. I edited the template.php where the preprocessing is being done so it is ready for the default image.

So here is my question, How do I call the default image in template.php?

Comments

wac0020’s picture

Assigned: wac0020 » Unassigned
quicksketch’s picture

You can get the default image by pulling up the field configuration from CCK:

$field = content_fields('field_[name of field]', '[node_type]');
$image = theme('image', $field['widget']['default_image']['filepath']);
ppblaauw’s picture

Thanks for this solution.

Use it to get the default imagefield image with the dynamic display block module if no image is uploaded to a node.

The code works

quicksketch’s picture

Status: Active » Fixed

Status: Fixed » Closed (fixed)

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