![]() | | ||||||||
| | #1 |
| Banned War Room Member |
Hi all. I have a peeling corner on one of our websites that appears when the user visits the site. What I want it to do is for it to appear upon exit: ie. when the user moves to the back button or to close out the page. Anyone have any ideas???
|
| | |
| | #2 |
| Senior Warrior Member War Room Member Join Date: Sep 2008 Location: Honolulu, Hawaii, USA & Montreal Canada
Posts: 2,218
Blog Entries: 1 Thanks: 759
Thanked 724 Times in 505 Posts
|
Hi Belinda Could you tell us what script or plugin you are using to create the "peeling" effect? If I knew perhaps I could figure out how to tie it in to an event when you exit the page. All the best... Bill |
| | |
| | #3 |
| Banned War Room Member |
Hi Bill-- I am using the script found here: How to create a peeling corner on your website that can contain advertations or anything else. |
| | |
| | #4 |
| Senior Warrior Member War Room Member Join Date: Sep 2008 Location: Honolulu, Hawaii, USA & Montreal Canada
Posts: 2,218
Blog Entries: 1 Thanks: 759
Thanked 724 Times in 505 Posts
|
Hi Belinda I haven't actually tried it but by looking at it I think I see how you could do this: 1 - Remove or comment out the last line in your peel.js script (line # 64). 2 - Replace or edit the BODY tag of your index.html or index.php as follows: Code: <BODY onUnload="jaaspeel.putObjects()"> Bill |
| | |
| | #6 |
| Senior Warrior Member War Room Member Join Date: Sep 2008 Location: Honolulu, Hawaii, USA & Montreal Canada
Posts: 2,218
Blog Entries: 1 Thanks: 759
Thanked 724 Times in 505 Posts
|
Hi Belinda Does it still run the peeling script when the site loads (it shouldn't with the last line removed)? And are you still including the peel.js script with the document head (not body) using this line: Code: <script src="peel/peel.js" type="text/javascript"></script> Bill |
| | |
| | #7 |
| Banned War Room Member |
Let me try putting the script source in the head and see if that works. It doesn't load when the page loads, but nothing happens if I go to close out the browser or hit the bck button either...
|
| | |
| | #8 |
| Banned War Room Member |
Nope, still didn't work... Your help is greatly appreciated though. What I think some people do is put some hidden div or tag in the html that when moused over in an attempt to close out the page brings up the script...
|
| | |
| | #9 |
| Banned War Room Member |
Well I tried it with onmouseover and a link which loads the peeling corner, but only the peeling corner and not the rest of the page....so close and yet so far...
|
| | |
| | #10 |
| Senior Warrior Member War Room Member Join Date: Sep 2008 Location: Honolulu, Hawaii, USA & Montreal Canada
Posts: 2,218
Blog Entries: 1 Thanks: 759
Thanked 724 Times in 505 Posts
|
Hi Belinda Sorry you are having so much trouble with this. Can you show me the format of the link you created? Anything you can activate with an onMouseOver should also be possible to activate with an onUnload event. Bill |
| | |
| | #11 |
| Banned War Room Member |
Here you go: <a href="somedomain.php" onMouseOver="jaaspeel.putObjects()">test</a> |
| | |
![]() |
|
| Tags |
| corner, exit, peeling |
| Thread Tools | |
| |
![]() |