Hide Author By-Line if After Certain Date

It’s probably getting the date as you expect, but the > is essentially a mathematical operator and you’re trying to use it to compare two strings. You can use strtotime() to convert the dates to integers (# of seconds elapsed since 1970-01-01), and compare those. // Hide By-Line add_action(‘wp_head’,’my_head_css’); function my_head_css(){ $excludeDate = date(“2021-06-02”); $postDate … Read more

Where do I put the code snippets I found here or somewhere else on the web?

Whenever you find a piece of code without clear installation instructions it is probably a plugin. The example you gave is a good one, because that is the most common case: add_action(‘template_redirect’, ‘remove_404_redirect’, 1); function remove_404_redirect() { // do something } To use such a snippet, put it into a plugin: Create a new file, … Read more