Skip to content

Instantly share code, notes, and snippets.

@iworks
Created March 15, 2024 09:25
Show Gist options
  • Save iworks/6306dbd1fc839806b8d09cec358477b4 to your computer and use it in GitHub Desktop.
Save iworks/6306dbd1fc839806b8d09cec358477b4 to your computer and use it in GitHub Desktop.
Sierotki: add the FORM tag to protected tags
<?php
/*
Plugin Name: Sierotki: add the FORM tag to protected tags
Plugin URI: http://iworks.pl/szybki-wordpress-obrazki-leniwe-ladowanie
Description: Added the FORM HTML tag to protected tags, to avoid orphans replacements.
Version: 1.0.0
Author: Marcin Pietrzak
Author URI: http://iworks.pl/
License: GPLv2 or later
*/
add_filter(
'iworks_orphan_protected_tags',
function( $protected_tags ) {
$protected_tags[] = 'form';
return $protected_tags;
}
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment