Timeline for Displaying an image in a programmatically created block (Drupal 7)
Current License: CC BY-SA 3.0
10 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Mar 1, 2012 at 20:34 | comment | added | Charlie Schliesser | Yes, so that links to a taxonomy term, not to a node. Are you trying to print the image of a term or of a ndoe? | |
Mar 1, 2012 at 19:57 | comment | added | Mike2012 | Do you mean this? l($child->name, "taxonomy/term/$child->tid") | |
Mar 1, 2012 at 19:56 | vote | accept | Mike2012 | ||
Mar 1, 2012 at 19:02 | comment | added | Charlie Schliesser | Scratch the above comment -- Where in this code are you printing the node link? | |
Mar 1, 2012 at 18:57 | comment | added | Charlie Schliesser | I'll add an answer below. If you are using taxonomy_term_load you should have the full term object available to you, including images. | |
Mar 1, 2012 at 18:23 | comment | added | Mike2012 | It is an image field (Didn't these fields come from cck?). Normally I do display these elements using a block created by Views but I think in the case that will not work. I am trying to overwrite the default view of a taxonomy term to display the child terms if they exist and if the term has no children show the nodes that have the taxonomy of the leaf. As far as I could tell there was no way to do this with Views. | |
Mar 1, 2012 at 17:28 | comment | added | Charlie Schliesser | Are you sure it's a CCK image or is it just a image field? CCK doesn't really exist in Drupal 7, outside of providing some support for upgrade paths and the like. If you've added an Image Field to a vocabulary, you can use Views to create a block that shows a term (or several terms) in a table format, including fields from the terms such as your image field. | |
Mar 1, 2012 at 17:23 | history | edited | Mike2012 | CC BY-SA 3.0 |
added 1099 characters in body
|
Mar 1, 2012 at 7:22 | answer | added | Countzero | timeline score: 1 | |
Feb 29, 2012 at 22:41 | history | asked | Mike2012 | CC BY-SA 3.0 |