Whether the widget has content to show.
Parameters
$instance
arrayrequired- Widget instance props.
Source
protected function has_content( $instance ) {
return ( $instance['attachment_id'] && 'attachment' === get_post_type( $instance['attachment_id'] ) ) || $instance['url'];
}
Changelog
Version | Description |
---|---|
4.8.0 | Introduced. |
User Contributed Notes
You must log in before being able to contribute a note or feedback.