I need to code a exit popup plugin with jquery . It should be similar as this one http://kbeezie.com/view/cross-browser-exit-pop/ the demonstration is here http://kbeezie.com/exitpop.html Can anyone please help me how to code this so it display on all pages and posts. Any type of help/tip will be appreciated. THanks
|
Before I give you any code, I want to be very clear that exit popups are frowned upon in pretty much every development community. They're annoying to users, create a bad customer experience, and will tick off just about any developer who ever looks at your site. I can't say this any more emphatically, but please, please, please do not use exit popups on your site. OK, now that you've ignored that recommendation ... here's how you'd do it anyway. Your plugin will consist of two files: In addition to the standard plugin headers, your
This code will load your script on every post and page in the header of your site. Now, just place the relevant code from that tutorial you linked to in your
Let me say one more time that I absolutely do not encourage you use this kind of feature in any site. It's a quick way to get your name on the top of many developers' "I don't like this guy" lists. |
|||||||
|