My webpage is accessible for users without sign in, but some action requires an authentication.
I would like to show the Janrain popup window only when the user clicked on the Sign in button. My webpages usually generated dynamically with Javascript.
As far as I know, the only way to show the popup is to include an a element to the page with class="rpxnow", add the link to the rpxnow.com/js/lib/rpx.js script, and this script will add an onclick handler to my a element.
But I didn't have any a element when the page was loaded, and I don't like to waste the anonymous user's bandwidth with the unnecessary <script> tags on every page.
So my question is: how to attach the Janrain popup event trigger to a dynamically created HTML element?
What's the language you are using? Just add the script tag when needed:
But you still need a element.