SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Evangelist Sikwondo's Avatar
    Join Date
    Sep 2005
    Posts
    426
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    JavaScript/Ajax Image/Colour Swatch switcher

    Hi Everyone,

    Please forgive me but I am very new to Ajax, I know a little jQuery, but was just wondering if anybody could point me in the right direction...

    I am building a small store that sells T-Shirts, one t-shirt has 3 colours, so I wanted to display a colour swatch, and change the images that are displayed when the colour swatches are clicked.

    You can see the effect I mean on the following website by clicking on the colour swatch button: Daily Habits - EYE EYE CAPTAIN HOOD - KON Shop - King of Nothing

    I have been hunting around for a tutorial on how to achieve this, but so far can't find one.

    Can anyone offer me any help/advice - or point me in the direction if a suitable tutorial?

    Thank you very much
    Simon

  2. #2
    Unobtrusively zen silver trophybronze trophy
    paul_wilkins's Avatar
    Join Date
    Jan 2007
    Location
    Christchurch, New Zealand
    Posts
    14,702
    Mentioned
    101 Post(s)
    Tagged
    4 Thread(s)
    Quote Originally Posted by Sikwondo View Post
    I have been hunting around for a tutorial on how to achieve this, but so far can't find one.
    The pager example from this jQuery cycle demo page seems to be fairly close to what you're after.

    Instead of the images you would have a colour swatch, and you would use a slower and different effect instead, perhaps the scrollHoriz effect.
    Programming Group Advisor
    Reference: JavaScript, Quirksmode Validate: HTML Validation, JSLint
    Car is to Carpet as Java is to JavaScript

  3. #3
    SitePoint Evangelist Sikwondo's Avatar
    Join Date
    Sep 2005
    Posts
    426
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by paul_wilkins View Post
    The pager example from this jQuery cycle demo page seems to be fairly close to what you're after.

    Instead of the images you would have a colour swatch, and you would use a slower and different effect instead, perhaps the scrollHoriz effect.
    ThanksPaul, that's great


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •