SitePoint Sponsor

User Tag List

Results 1 to 3 of 3

Hybrid View

  1. #1
    SitePoint Enthusiast
    Join Date
    Feb 2010
    Posts
    73
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Help with Colorbox lightboxes 'already visted' link

    Hi guys,

    I've been trying to do this with CSS and had some great help from the guys in the CSS forum, but we found out it might be more possible with PHP.

    I am using Colorbox, a lightbox JsQuery, to load an external PHP file. Basically, when a user has clicked on a thumbnail image and the page opens up the colorbox, when the user then closes it, I would like the padded background of the thumbnail to be a different color - almost like a 'visited' state (as I say, we tried it with CSS but couldn't get it to work entirely).

    Is there some PHP I can assign that says: if div class is clicked, display padded bg color #000000...?

    Hope this makes sense!

    Thank you and I hope to hear from you!

    SM

  2. #2
    SitePoint Enthusiast
    Join Date
    Feb 2010
    Posts
    73
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Sorry guys, click here for the link to my test site!

  3. #3
    Mouse catcher silver trophy
    Stevie D's Avatar
    Join Date
    Mar 2006
    Location
    Yorkshire, UK
    Posts
    5,820
    Mentioned
    110 Post(s)
    Tagged
    1 Thread(s)
    Thinking about this again – without wanting to send you on a wild goose chase through every forum we've got – this is probably a Javascript question. Javascript can dynamically update the page and apply a 'class' to any image/link you've clicked on (although it isn't persistent, so it won't hold if you refresh the page or go to a different page then come back), but PHP can't update the page as you go.


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
  •