LLMS_Notification::get( string $key, $skip_cache = false )
Get notification properties
Description Description
Parameters Parameters
- $key
-
(string) (Required) key to retrieve
Return Return
(mixed)
Source Source
File: includes/models/model.llms.notification.php
public function get( $key, $skip_cache = false ) { // id will always be accessed from the object if ( 'id' === $key ) { return $this->id; } // return cached values if they exist if ( ! is_null( $this->$key ) && ! $skip_cache ) { return $this->$key; } // get the value from the database global $wpdb; return $wpdb->get_var( $wpdb->prepare( "SELECT {$key} FROM {$this->get_table()} WHERE id = %d", $this->id ) ); }
Expand full source code Collapse full source code View on GitHub
Changelog Changelog
Version | Description |
---|---|
3.8.0 | Introduced. |