Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2007-01-29 02:15:19

squaredeye
Member
From: Greenville, SC
Registered: 2005-07-31
Posts: 1,495
Website

javascript img rotation on click + flexible size = fun?

I need help thinking through this one :)

I’ve got an elastic layout that I’ve got some images that also flex.
In the CSS, they are given the rule width: 100%, and since the images
have no specified height or width, the image grows or shrinks proportionately with
the container div.

GOAL:
I’d now like to have a list of images (3-5), that rotate on-click using JS.
(much like this one)
I am speculating that the above example might not be the best option, but it illustrates my need.

STIPULATIONS:

  • these images need to be placed by upm_image
  • I need the images to retain their flexibility (this has been difficult to find).

Possible?

THE ALTERNATIVES:
I can imagine using a lightbox scenario, although I find these overdone, and slightlly dramatic, for what should be a simple and quick movement for a user.


Offline

#2 2007-01-29 02:25:42

masa
Member
From: Asturias, Spain
Registered: 2005-11-25
Posts: 1,091

Re: javascript img rotation on click + flexible size = fun?

ma_smith wrote:

I can imagine using a lightbox scenario, although I find these overdone, and slightlly dramatic, for what should be a simple and quick movement for a user.

I’m with you on this one – have been looking for something similar myself. In the WYSIWYG editor I used to use this was blissfully easy to set up.

I wonder if there’s a way to get rid of the tedious transition effects in Lightbox. If the images would just snap into place, that would definitely be my ticket.

Cheers Martin

Offline

#3 2007-01-29 02:31:22

squaredeye
Member
From: Greenville, SC
Registered: 2005-07-31
Posts: 1,495
Website

Re: javascript img rotation on click + flexible size = fun?

Martin,
Glad to hear I have some backup :)
for me its not just the transitions, although those really take it overboard. Its the question of whether or not a modal window is appropriate for what I want to achieve. Which in my case, I believe it is not.


Offline

#4 2007-01-29 02:45:09

masa
Member
From: Asturias, Spain
Registered: 2005-11-25
Posts: 1,091

Re: javascript img rotation on click + flexible size = fun?

I agree. I try to keep things simple myself.

There’s all sorts of lovely gallery- and slideshow plug-ins available for txp, but it sure would be a nice addition to have a bone-simple one that allows users to flip through the images in situ just by clicking them or employing an automatically generated pair of << >> arrow links.

An excellent candidate for the plug-in request listing, huh!?

Last edited by masa (2007-01-29 02:45:45)

Offline

#5 2007-01-29 03:11:10

masa
Member
From: Asturias, Spain
Registered: 2005-11-25
Posts: 1,091

Re: javascript img rotation on click + flexible size = fun?

Now that you’ve got me thinking about it, I’m just throwing out some more ideas here…

What I like very much about Lightbox is the fact, that when you hover over the image it displays a previous or next image indicator depending on whether you hover over the right or left area. I’d prefer small arrow icons to appear, but that could probably done by simply substituting such images in anyone’s custom installation as is the case with Lightbox.

It would also be a nice addition to add an attribute setting, allowing to display plain-text links like previous | next just below the image.

Also an attribute to auto-run and loop the slideshow would be terriffic!

<txp:slideshow showtextlinks=“1” autorun=“1” loop=“1”>

What do you think?

Last edited by masa (2007-01-29 03:16:37)

Offline

#6 2007-01-29 03:16:11

squaredeye
Member
From: Greenville, SC
Registered: 2005-07-31
Posts: 1,495
Website

Re: javascript img rotation on click + flexible size = fun?

hmm, not for me :)
I think that’s a nice feature, and accomplished with other scripts out there.
I am looking for flexible (scalable) image proportions and no gimmickery.


Offline

#7 2007-01-29 03:20:25

masa
Member
From: Asturias, Spain
Registered: 2005-11-25
Posts: 1,091

Re: javascript img rotation on click + flexible size = fun?

ma_smith wrote:

I think that’s a nice feature, and accomplished with other scripts out there.

Would you mind giving me a hint as to what scripts you had in mind? :-)

Offline

#8 2007-01-29 14:21:06

squaredeye
Member
From: Greenville, SC
Registered: 2005-07-31
Posts: 1,495
Website

Re: javascript img rotation on click + flexible size = fun?

I’ve been googling for awhile on this, and have found more than enough lightbox effects using mootools or prototype that will do what you’re looking for.

here’s a good start

:)


Offline

#9 2007-01-29 14:45:50

maniqui
Member
From: Buenos Aires, Argentina
Registered: 2004-10-10
Posts: 3,070
Website

Re: javascript img rotation on click + flexible size = fun?

ma_smith wrote:

I am looking for flexible (scalable) image proportions and no gimmickery.

Hi Matthew,

maybe this can be helpful: simple jquery slideshow

You may need to adapt it to your needings.
The thing about flexible size… do you want your images to adapt always to 100% of the div width?
The images are going to be pixelated if they are tiny or huge… or am I wrong?


La música ideas portará y siempre continuará

TXP Builders – finely-crafted code, design and txp

Offline

#10 2007-01-29 15:20:11

hakjoon
Member
From: Arlington, VA
Registered: 2004-07-29
Posts: 1,634
Website

Re: javascript img rotation on click + flexible size = fun?

You could also check out the jQuery jCarousel which can do a pretty nice simple slideshow .


Shoving is the answer – pusher robot

Offline

#11 2007-01-29 17:33:14

mrdale
Member
From: Walla Walla
Registered: 2004-11-19
Posts: 2,215
Website

Re: javascript img rotation on click + flexible size = fun?

That jQuery stuff is pretty cool Hak. And a combo of wet_for_each_image and upm_image should allow for some pretty cool TXP Galleries.

I always wanted to integrate something like this gallery with TXP, but didn’t have the PHProps. I helped create this script which is a variant of this that adds controls and slideshow features as well as a small/medium/large image size. Pretty old stuff really (almost 3 years), I can only imagine what it looks like on the IEs. Maybe it’s useful.

Offline

#12 2007-01-29 18:19:33

hcgtv
Plugin Author
From: Key Largo, Florida
Registered: 2005-11-29
Posts: 2,722
Website

Re: javascript img rotation on click + flexible size = fun?

mrdale wrote:

I always wanted to integrate something like this gallery with TXP, but didn’t have the PHProps.

You don’t really need that much PHP skills nowadays, it’s more abut HTML and CSS than anything else.

This slideshow in my sample gallery can be made to look like you want it very easily.

Offline

Board footer

Powered by FluxBB