Introduction

This training is about how you can show a fun (and maybe useful) effect to the visitors of your site.

If your visitor decides to leave your site to go to another page that they have opened in another tab in their browser, you can display a special message in your browser tab.

Not a critical factor in web development, but I have seen websites that does this in a beautiful and fun way.

Important: To do this, you need to know how to put code in the <head> section of your theme. I will not go into how that is done.

Next: How it looks



Join the Discussion
Write something…
Recent messages
MoniArora Premium
Thank you Jorn.. works very good! Thank you for sharing.
Let's make this even better...Do you know the code to also have sound as well as the message?
Best wishes
Moni
Reply
JHaugland Premium
Thank you as well.
There are several ways to trigger sound on a website, and I am sure that it can be triggered on an inactive tab.
However, I will not investigate into that functionality. Personally, I think sound that is not actively initiated by the user is not something that should be used on a website.
Reply
Nick-at-WA Premium
I like this, thanks Jorn!
Reply
JHaugland Premium
Thanks
Reply
suzieq Premium
This is awesome, thanks!!
~Suzanne
Reply
JHaugland Premium
Thank you as well
Reply
Cynthiah1 Premium
Pretty cool.
Reply
JHaugland Premium
Thanks
Reply
Loes Premium
Great little script, I love it
Reply
JHaugland Premium
Thanks
Reply
AlanJE Premium Plus
That would be great to have such interaction, thanks for the training Jorn, Best Alan
Reply
JHaugland Premium
Thank you
Reply
Top