Description

Outputs the custom WP Geo marker title or defaults to the post title if a custom title is not set.

Usage

<?php wpgeo_title( $post_id = null, $default_to_post_title = true ); ?>

Parameters

$post_id
(int) Post ID. If null, defaults to the current post in the loop.

$default_to_post_title
(boolean) Returns the post title if no custom title set. Defaults to true.

Examples

Outputs the title for the current post in the loop.

<?php get_wpgeo_title(); ?>

Outputs the custom title for post ID 30 or nothing if a custom title has not been set.

<?php wpgeo_title( 30, false ); ?>

Notes

See also: get_wpgeo_title

Change Log

Since: 3.2

Source File

wpgeo_title() is located in wp-includes/templates.php.

Related

get_wpgeo_title

Leave a Reply