-
Hide Google reCAPTCHA v3 badge
Google reCAPTCHA v3 is out and it identifies spam bots behind the scenes, but it displays a badge in the bottom of every page of your website. If you want to hide that you can use the following css. .grecaptcha-badge { Like us on Facebook below to reveal the rest of the content.
go to article -
PHP detect a mobile device and display code accordingly
This is an old trick, but it’s still great to use especially in this case where your site visitors can click directly on their phone to call your business. function isMobileDevice() { return preg_match("/(android|avantgo|blackberry|bolt|boost|cricket|docomo|fone|hiptop|mini|mobi|palm|phone|pie|tablet|up\.browser|up\.link Like us on Facebook below to reveal the rest of the content.
go to article -
Display content on your site up to a certain date with PHP.
The following bit of code is handy if you need to display events on your site up to a certain date etc, or any other date related material. <?php $message = <<<EOF // this can be any html content - with complete syntax such as <div class="something"></div> EOF; if(mktime(0,0,0,8,19,2018) > strtotime('now')) { // the […]
go to article -
CSS to resize the Google reCAPTCHA in a form
Have you ever built a site that is completely responsive in all sizes, but then you notice the Google reCAPTCHA extends past the outer element forcing that dreaded space to the right side? Now you can fix it with the following CSS. By default you would use .g-recaptcha, but if you’re using a plugin you’ll […]
go to article