By gsh2000 on
IMG_ASSIST: Teaser Thumbnail image --> Story Page Preview Size Image ?
Hello Drupal’ists….
Anyone know how to have a Story Teaser display the Thumbnail image, and then the Story Page for this Teaser, automatically display the larger Preview Size for this Image?
4.7.3, Using IMAGE module + IMG_ASSIST, Garland Theme
Thanks
Garry, Los Angeles, USA
garry@trantech.com
Comments
Maybe Someday
Currently that's not possible, because img_assist works with the Drupal filter system and the output is cached. I've been thinking about changing img_assist (in a future version) to work with the nodeapi hook instead so that it could potentially do something like this (at the expensive of load time -- since output wouldn't normally be cached).
changing img_assist
thanks for the rapid reply... would be great to see this on a future IMG_ASST release...
This image behavior is effectively implemented currently in the IMAGE module, in the Image Gallery … performance overhead a small price to pay…
thanks, GARRY
www.joo2joo.org
imagecache
If you're not afraid of a little php, I'd recommend imagecache (http://drupal.org/project/imagecache) and a custom template for the story node type.
Ronan
------------------------------------
Gorton Studios - Websites that Work. http://www.gortonstudios.com/
http://www.gortonstudios.com/portfolio/technologies/drupal
------------------------------------
Ronan
Founder - NodeSquirrel - https://www.nodesquirrel.com/
Agency Tools Lead - Pantheon - https://www.pantheon.io/
hook_nodeapi solution
I had the same problem and addressed it with hook_nodeapi, like so...
Please elaborate
yogadex,
Can you elaborate briefly where you put that code and which variables are passed on to the function?
Thanks, riemann
Found the solution myself
There's a good description on how to use custom_nodeapi() on http://www.angrydonuts.com/the_nuisance_of_the_read_more_fl
Additionally, I slightly changed the code given above in order to make it work with my installation and I also got rid of the caption:
Excerpt + Image assist
I just use the excerpt module with the image assist module. In the "teaser" area produced by the excerpt module I put a thumbnail image selected from image assist, and in the main body I make a separate selection and put a preview size image. Works great. No hassle.
AWESOME ! Thanks a lot !
AWESOME !
Thanks a lot !
Anyone know if this works
Anyone know if this works in 5.7? I can't get it to work, any ideas?
Drupal 5.7
By replacing $node->teaser" with "$node->content[body]['#value']" the above snippet worked for me in Drupal 5.7