I can not hide webform block by Per user submission limit.
I choose Per user submission limit = 1- > ever, but block is shown.
How can I hide the block, if it was submitted?
I can not hide webform block by Per user submission limit.
I choose Per user submission limit = 1- > ever, but block is shown.
How can I hide the block, if it was submitted?
When a visitor submit a form, cookie with a name "webform-123" (123 - webform ID) save in his browser. In the block visibility settings use the cookie existence check with PHP:
<?php
$match = FALSE;
if(!isset($_COOKIE['webform-123'])) {
$match = TRUE;
}
return $match;
?>
If the cookie does not exist, the condition will return the TRUE and the block will be displayed.