Remove tagline from the HTML on the home page without plugin?

If first check in your header.php file and check in title tag what is print. if in title tag bloginfo then it’s replace with wp_title(”) because bloginfo is not replace with code. Header.php <title><?php wp_title(”); ?></title> After function.php file put this code: function wpdocs_theme_name_wp_title( $title, $sep ) { if ( is_feed() ) { return $title; … Read more

Permalink and ACF field

You’ll need to use some different functions for obtaining the post thumbnail and title from outside of the loop: get_the_title( $post_id ) – https://developer.wordpress.org/reference/functions/get_the_title/ and get_the_post_thumbnail( $post_id, ‘post_cover’ ) – https://developer.wordpress.org/reference/functions/get_the_post_thumbnail/ Note: These functions only return the title and post thumbnail so will need to be echoed out.

How To capitalize The First Letter Of Every Word In The Post Title

The code below was assembled of different pieces I’ve found around and it was not tested. Consider it as an idea only. <?php add_filter( ‘the_title’, ‘my_capitalize_title’, 10, 2 ); function my_capitalize_title( $title, $id ) { // get separate words $words = preg_split( ‘/[^\w]*([\s]+[^\w]*|$)/’, $title, NULL, PREG_SPLIT_NO_EMPTY ); $stop_words = array( ‘the’, // ‘a’, ‘and’, ‘of’, … Read more

Print post title with markup

Using your example, you could… <h4><?php echo get_the_title( $post_id ); ?></h4> Or $h4 = get_the_title(); echo ‘<h4>’ . $h4 . ‘</h4>’; More on get_the_title(). Or you could use the_title(). the_title( ‘<h4>’, ‘</h4>’ );

disallow publish posts with special title

The “easy” answer is: put a filter on it. add_action( ‘transition_post_status’, ‘my_function’, 10, 3 ); function my_function( $new_status, $old_status, $post ) { if ( ‘publish’ !== $new_status or ‘publish’ === $old_status ) return; if ( ‘post’ !== $post->post_type ) return; // restrict the filter to a specific post type $title = $post->post_title; $restricted_title = “title … Read more

Loop doesn’t show title of second post and posts thereafter

The code posted for your index.php file contains an error. The WordPress function the_post() is called twice in each iteration. As this function iterates the post index and sets up the conditionals for each post, calling this twice is the likely cause of your problem. Remove the second instance of the_post() immediately after your H2. … Read more

Gutenberg – Title field required

You could use PluginPrePublishPanel to check for the title and lock publishing if it’s empty. Have a look at the accepted answer here for an example of locking the post – Add pre-publish conditions to the block editor For your example you could modify the checking portion as follows: const { registerPlugin } = wp.plugins; … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)