• Resolved Jay

    (@jaytfl)


    Hi Team,

    I have a Real Flipbook 3D plugin which we are using as a Newsletter.

    Click here to see the demo of same.

    Through the NL, they dispatch an event upon opening the NL and on turning the page.

    How do I get this logged in my Simple History since this would be a JS event?

    Thanks!

Viewing 1 replies (of 1 total)
  • Plugin Author Pär Thernström

    (@eskapism)

    It sounds like it would be possible, but it would require some custom development.

    Basically these are probably the steps you need:

    – Add some JavaScript that listens to the event from Real Flipbook 3D
    – The JavaScript sends an AJAX request to your WordPress installation
    – In WordPress you need to add a [PHP function to handle the AJAX request](https://codex.ww.wp.xz.cn/AJAX_in_Plugins)
    – The PHP function logs to Simple History using the Simple History API, something like this: apply_filters( 'simple_history_log', 'Someone viewed the NL' );

    So.. possible but some coding is required. Good luck!

Viewing 1 replies (of 1 total)

The topic ‘Trigger custom log through JS event’ is closed to new replies.