Tedd Sperling <tedd@xxxxxxxxxxxx> wrote: > It's Friday so I am allowed to ask odd questions. W00T! Friday! > Here's the problem -- I need to count the number of times a user activates a LightBox -- how do you do that? > > Here's a LightBox Example: > > http://www.webbytedd.com/c2/lightbox/ > > All the javascript is there (jQuery et al). > > Ideally, I would like to have a php/javascript combination that would: > > 1. Detect when a user clicked the LightBox; > 2. Pass that value to PHP so I can keep count. > > Any ideas? First off, do you have the javascript code available in an unsquished form? That would mean I could read it. Not knowing whether your JS code or Lightbox has any hooks that you can take advantage of, I'd steal the onclick event from those images that start lightbox, fire off an AJAX request and ignore the return, then fire the lightbox event handler. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php