Support » Everything else WordPress » Difference between bloginfo() and get_bloginfo()?

  • In my mind, these two tags do the same thing..? I’m kind of confused by all the repeating tags and arguments in WordPress (especially the get_categories() function – why are there so many objects that show the exact same thing??).

    Just would like to know if anyone knows the major difference and whether one tag is better? I’ve been using get_bloginfo() a lot to retrieve my template URL, but the header file tends to use just bloginfo() to get the same thing…

    Any thoughts?

Viewing 2 replies - 1 through 2 (of 2 total)
  • esmi

    (@esmi)

    Forum Moderator

    get_bloginfo does what it says on the box. It gets data on the blog for use in your templates. bloginfo() does the same thing but automatically echoes the result to the screen/page.

    So, technically, it’s better to use bloginfo() when placing links/urls on the page as you don’t need to write echo…I see. Thanks for clearing that up!

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Difference between bloginfo() and get_bloginfo()?’ is closed to new replies.