Using the Views Theme Wizard, I generated the template for a view that included a CCK image field.
I'm not sure if this is intentional, but the variable output for the image ($field_image_nid_label) contained a full link to the image, e.g. <a href="/imagename">imagename</a></pre>
I actually want to make a hyperlink based on the image, so to make this useful, I will have to strip it back and reformat it as <a href="http://www.somecompany.com"><img src="/files/images/imagename" /></a>.
It would be better if $field_image_nid_label just contained the image name, so we can do with it what we will.
Comments
Comment #1
merlinofchaos commentedProbably the views info for that field type could use an option? not sure the best way to deal with this.
Comment #2
quicksketchThe solution here would be to provide a formatter which just returns the image path rather than an img tag.
Comment #3
dopry commentedIt may be cool to create some sort of imagefield_extras.module along the lines of views bonus pack that has some cool formatters and widgets for imagefield... opinions?
Comment #4
dopry commentedComment #5
dopry commentedtotally in 2.x and head.