By rizaa on
Any image uploaded even those for forum or story submission shows up as the latest image - how to restrict latest image to those images which has been added to gallery ( or various galleries ) for the sole purpose as photo pix etc .
Even if an image is uploaded via image assist and it is ultimately not used in a story etc the image shows up as the latest image :(
Thus I will like 'latest image' from those which has been uploaded a gallery only.
Any help will be gratefully acknowledged.
[ My million thanks to luyendao shouchen somebodysysop benshell and others for kindly replying my previous posts ]
Comments
Try here
http://drupal.org/node/53987#comment-121382
--
Cheers,
Thong
Tip: http://drupal.org/forum-posting
Website: http://www.edoodle.co.nz
Drupal for artists - demo at Website for artists
Quick fix
The image block function for the 4.7 image module can be configured for both number of photos and category.
Look for function image_block() on line 206 of image.module. You'll find the code for "latest" block on line 217
$images = image_get_latest()By adding arguments to the call image_get_latest() you can "Fetch the latest N image(s) - optionally from a given term."
To get the latest image from a gallery change to
$images = image_get_latest(1,3)Where 3 is the tid # of the gallery you want.ok, that works GREAT!
ok, that works GREAT! thanks.
Now.....what if I don't want people to be able to click on that image?
Another quick fix...
... around line 219 you'll see this:
change it to this: