1

I'm using SimpleModal to allow users to click on a post excerpt on my homepage and popup a box showing the full post. However it doesn't count for an actual view of the post when this happens. Is there a way to make wordpress recognize it as a view? I'm using wp-postviews to track view counts.

  • Some links to the plugins would be useful. You know, some of us don’t know the source code of all plugins ever written. Strange, I know, but it’s true. ;) – fuxia Apr 6 '12 at 4:19
  • good point sorry about that – Pollux Khafra Apr 6 '12 at 13:36
2

Apparently the plugin does the logging inside the wp_head hook:

add_action('wp_head', 'process_postviews');

so make sure you call wp_head() in your pop-up box, or if you can't do that (pop-up is not a html document), then just call the function directly, like:

if(function_exists('process_postviews'))
  process_postviews();

// the_content();  ?
|improve this answer|||||

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.