This website uses cookies to personalize your experience. By using this website you agree to our cookie policy.

Reply To: Hiding Search Bar

#51706
Ernest MarcinkoErnest Marcinko
Keymaster

That is exactly what the code I suggested should do:

add_filter( 'asp_shortcode_output', function( $output, $id ){
	if ( $id != 1 ) {
		return $output;
	}
	if ( get_the_ID() == 13702 || get_the_ID() == 2428 ) {
		return '';
	}

	return $output;
}, 10, 2 );

If it doesn’t work, then there is something wrong I can’t foresee, unfortunately I can’t test this code on my end as it needs the exact same setup as yours.

If you want, you can add temporary back-end and sFTP access, and I will debug this – it’s probably something very minor. I can’t guarantee anything (as custom code is beyond support), but I can try.