Created
July 4, 2018 13:03
-
-
Save helloromero/d97a74c279fcbec8acaf4de3ecdd1eec to your computer and use it in GitHub Desktop.
Hide collect.chat after submitted (requieres js-cookie)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$(function() { | |
var collect_chat_completed = Cookies.get('collect_chat_completed'); | |
if (collect_chat_completed == "true" && !Cookies.get('collect_chat_timer')) { | |
Cookies.set('collect_chat_timer', 'true', { expires: 1 }); | |
Cookies.set('collect_chat_completed', 'true', { expires: 1 }); | |
Cookies.set('collect_chat_closed', 'true', { expires: 1 }); | |
} | |
if (Cookies.get('collect_chat_completed') == "true") { | |
$('#collect-chat-launcher').hide(); | |
} | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment