HEX
Server: nginx/1.26.1
System: Linux 850a3e23ecee 5.15.0-122-generic #132-Ubuntu SMP Thu Aug 29 13:45:52 UTC 2024 x86_64
User: (1000)
PHP: 8.2.27
Disabled: NONE
Upload Files
File: /var/www/html/wp-content/plugins/fixed-toc/compatibility/rate-my-post-plugin.php
<?php

/**
 * Removes the shortcodes of Rate My Post when creating a TOC data.
 *
 * Because the shortcodes only run once, they can't run when creating data.
 *
 * @since 3.1.16
 *
 * @param string $content
 *
 * @return string
 */
function fixedtoc_remove_shortcodes_for_data( $content ) {
	return str_replace( array(
		'[ratemypost]',
		'[ratemypost-result]'
	), '', $content );
}

add_filter( 'fixedtoc_data_raw_content', 'fixedtoc_remove_shortcodes_for_data' );