It would be awesome and not too difficult (I think) to add a mouse-rollover-effect using the onmouseover/onmouseout Only local images are allowed. attributes.
The only thing that needs to be added imho is in the /admin/content/node-type/some-node-type/display > display-fields the option to choose the rollover image (format) for teaser and full-node (and maybe the same for view definitions). And generating the onmouseover and onmouseout Only local images are allowed. attributes of course.

Comments

drewish’s picture

Status: Active » Closed (won't fix)

i'm not really sure what you mean for the roll over. so you'd select a different preset for before and after? that would make for huge list of possible field formatters...

if i'm misunderstanding this please feel free to re-open it.

ddorian’s picture

Status: Closed (won't fix) » Active

he is saying like the lightbox2 module that puts for example thumbnail---->large_image
that means when u clikc the thumbnail the large image opens in a lightbox
BUT he (and id like too but i know that it is not this module job and i will search more)is sayin the same thing happens when u rollover the image

check templatemonster.com rollover a template thumbnail and you'll see

rjbrown99’s picture

Perhaps something like this:
http://cssglobe.com/post/1695/easiest-tooltip-and-image-preview-using-jq...

See example #2, except in this case the rollover would ideally allow you to select which imagecache preview to load.

metabits’s picture

It would really very interesting to have the chance to toggle in between to imagecache presets with a rollover effect / onmouseover / hover. Any ideas how could I accomplish that?

Thanks

psc

Bilmar’s picture

subscribing

carsato’s picture

Before say a word i would like to thank you for this awesome module and to say excuse my english, please.

I would like to have something like http://emeka.es/clientes.php . There you can see the images using one preset and when you put the mouse over them they use other preset. There they use onmouseover="javascript:this.src='path/to/the/other/image.jpg'" to get the effect. I thing this effect is pretty cool and would be very nice to have this effect as imagecache action.

Basically this is to set up two presets and then let the user/administrator/view creator choose the preset for normal image and onmouseover image, and also onmouseout or other properties.

Well, I hope you can understand my english. Thank you very much.

jon_stewart’s picture

Priority: Normal » Minor

But this is just a few lines of javascript. Why would it even need to be included in imagecache?

Have a look at http://www.amazon.co.uk/gp/product/B001CQLW62/ref=s9_simi_gw_p21_i1?pf_r... because this is a lot more useful for many (and complicated) but doable with javascript and lightbox (Just debugging mine now!)

I think my point is that this is just manipulating existing images, and not what I see as being in the scope of purpose of imagecache.

PS I have no connection with the guys who did the superb work on imagecache!

Jon

metabits’s picture

Priority: Minor » Normal

First, thank you for this great module.

I still think that both posibilities of using an rollover effect are equal interesting.

@Jon Stewart
Maybe you could help by writing that few lines of javascript. The one of us that we are not able would be very thankful... I was able to use such a script for a static website, but I was needing to include the names of new images in the array script every time I had a new image, and that, after a while it was really tedious (not to mention every a tag in every place in every page). But I have no idea how to do this automatically with over hundred images (and growing) using my presets. And I think I am not the only one...

Thanks in advanced for future solutions to this!

psc

rjbrown99’s picture

We are going to roll out a module that does this within the next week.. stay tuned. It's a bit more than just a javascript effect. What we have is a selectable series of views fields that allow for mapping of any imagecache preset to any other imagecache preset.

You set up preset #1, let's say it is 320x280 dimensions.
You set up preset #2, let's say it is 640x480 dimensions.

You want to hover from preset #1 to preset #2. I.E. the first preset is your static picture that is output, and the second one is what the hover state is when you roll over it.

The way this is used is via views as a field output. Select field->my_image_field, and then the output options have a series of dropdowns that allow mapping from any preset to any other preset. If you have a lot of presets, there's a lot of options. It's an any-to-any solution now for hover states.

Works very well for me and is a great utility module. Give me a week or so to get it up and I'll post back here.

joecanti’s picture

Great idea, and I agree definitely a separate module job...

Here's food for thought - if you're getting javascript involved how about a transition placed between the two presets eg a wipe or fade...

You could create some really nice looking buttons and menus with this - would look like it was created in flash, but be fairly lightweight...

thanks, joe

rjbrown99’s picture

I'm hoping that there will be enough interest in the module that people will contribute things like this.

jon_stewart’s picture

It's certainly worth doing work in this area, since the default image display isn't great (aka doesn't provide the function or flexibility that a lot of people want)

Looking forward to seeing this module.

rjbrown99’s picture

Here you go -
http://drupal.org/project/hover_preview

The code is checked in, but the -dev release won't be available until the next time the packaging scripts are run on drupal.org. Please share feedback, suggestions, and especially code contributions to improve the module!

rjbrown99’s picture

Status: Active » Closed (fixed)

The -dev release of hover preview is now available.

I'm marking this as closed as I don't think the ticket is applicable to Imagecache any longer.

jon_stewart’s picture

Excellent module, and not quite what I was writing!
Thanks for sharing it.
Jon

metabits’s picture

Status: Closed (fixed) » Active

Sorry that I open again this issue but the request is only half answered with the use of hover preview module. Some of us where just asking for the possibility to use two presets when hover in an image, not creating a big version of the image floating by it.

I tested hover preview module and makes very good exactly that: creating a big version of the image when rolling with the mouse over. But does not solve the easy/traditional/standard use of hovering an image changing in between two states (imagecache presets).

I have this scenario:

- I have a big amount of works by an artist.

- The works are having, let's say, 3 imagecache presets: thumbnail, preview, big

- I have views to display lists of this works with their thumbnails that use lightbox preview>big or a link to the node (and this should stay so)

All that my artist would like to have is the possibility that when rolling over an image, anyplace in the web in any of the views, the thumbnails change to a negative version of it (wich is a 4th. imagecache preset), but when clicking still behaving like they do (lightbox or whatever).

As I said in a previous post, I do not know how to programm this, hence I'm still asking for some help.

Thank you for your efforts and help!

psc

rjbrown99’s picture

psc that could probably be done with a combination of hover preview with a clickable integration with a lightbox module. You could probably just chain the javascript effects within the .js file inside of hover preview.

I'd be open to a hover preview patch if you or someone else comes up with something workable or an optional integration with one of the lightbox modules.

jferjan’s picture

subscribing

yannick menard’s picture

subscribing

zeropaper’s picture

IMO this is a theming thing and is too much of an edge case to be an issue for imagecache.
Better keep the module light, straight to its goal and clean.

ddorian’s picture

Status: Active » Fixed

Status: Fixed » Closed (fixed)

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