Documentation

gwp_post_id

The {gwp_post_id} merge tag returns the post-id for a certain url.

Parameters

  • url – The URL of the post for which the ID is to be retrieved. This parameter is required.

Example Usage

{gwp_post_id url="/some-post/"}

This will output the ID of the post located at “https://yoursite.com/some-post/”. If the post ID cannot be found, an error message will be displayed.

Advanced Merge Tagsv1.7.2

To use the functionalities described in this documentation, you'll need to get the GravityWP - Advanced Merge Tags add-on.

Read more