tp TouchPointWP Interfaces storedAsPost - TenthPres/TouchPoint-WP GitHub Wiki

tp\TouchPointWP\Interfaces\storedAsPost

This is a base interface for classes that store TouchPoint items as posts in WordPress.


  • Full name: \tp\TouchPointWP\Interfaces\storedAsPost

Methods

getPost

Get the WP_Post object corresponding to the object.

public getPost(bool $create = false): \WP_Post|null

Parameters:

Parameter Type Description
$create bool Set true if the post should be created if it doesn't exist. This would need to be
implemented in each module, and is not implemented in most.