Hello,
i have added a custom script to the funtions.php and this works well for me but it only works on the Main Page and no where else.
I dont know if this error is caused by enfold or wrong code?
add_action('wp_footer', 'hide_on_sent');
function hide_on_sent(){
?>
<script type="text/javascript">
document.addEventListener( 'wpcf7mailsent', function( event ) {
setTimeout(function() {
$('#hideonsent').hide(); }, 0);
setTimeout(function() {
$('#hideonsent').show(); }, 5000);
setTimeout(function() {
$('.wpcf7-mail-sent-ok').hide(); }, 5000);
}, false );
</script>
<?php
}
Hope there is somebody who can help me cause i try since hours with no effect.
Thanks,
Banshee350
Hey Banshee350,
Can you give us temporary admin access to your website in the private content box below, so that we can have a closer look?
Best regards,
Victoria
Off course, here the login.
Hi Banshee350,
The event listener has to be added to the class, id or tag and your code does not use that. Please adjust the script accordingly.
Best regards,
Victoria