Answers for "wordpress display title of page"

PHP
2

wordpress echo the page title

<?php echo get_the_title(post->$ID); ?>
Posted by: Guest on November-30-2020
1

wordpress get site title

You are not outputting anything to show. You are only assigning blog name to a variable. You need to echo the content. It should be :

<h1><?php echo get_bloginfo( 'name' ); ?></h1>
Hope this helps :)
Posted by: Guest on March-08-2021
1

how to add title to wordpress php

// For website name in <title> tag
<?php wp_title(); ?>
  
// For the Post title within the loop
<?php the_title(); ?>
Posted by: Guest on November-23-2019

Browse Popular Code Answers by Language