Archives
Trending
Support
Login
clear text
XML
Django
JavaScript
MATLAB
C
C++
C#
Python
SQL
Shell
Bash
Markdown
YAML
JSON
HTML
CSS
PHP
Java
Ruby
Go
Rust
Swift
Kotlin
Arduino
TypeScript
Perl
Autohotkey
Lua
SQF
R
Scala
Haskell
Groovy
Dart
Clojure
VB.NET
Objective-C
PowerShell
Bash
CoffeeScript
Verilog
/* Create Custom Functions to Render Bookmark Button */ function custom_bookmark_button( $post_id ) { /* need to flag if this can render login form */ add_filter( 'jnews_can_render_account_popup', '__return_true' ); if ( is_plugin_active( 'jnews-bookmark/jnews-bookmark.php' ) ) { wp_enqueue_style( 'jnews-bookmark', JNEWS_BOOKMARK_URL . '/assets/css/plugin.css', array(), JNEWS_BOOKMARK_VERSION, 'all' ); wp_enqueue_script( 'jnews-bookmark', JNEWS_BOOKMARK_URL . '/assets/js/plugin.js', array( 'jquery' ), JNEWS_BOOKMARK_VERSION, true ); $bookmark_status = get_user_meta( get_current_user_id(), 'jnews_bookmark_article', true ); $bookmark_status = '' !== $bookmark_status ? $bookmark_status : array(); $class = 'fa fa-bookmark-o'; $status = false; if ( array_key_exists( $post_id, (array) $bookmark_status ) && $bookmark_status[ $post_id ]['status'] === true ) { $class = 'fa fa-bookmark'; $status = true; } $output = '
'; echo jnews_sanitize_by_pass( $output ); } }
Mark as private (unlisted)
for 30 minutes
for 6 hours
for 1 day
for 1 week
for 1 month
for 1 year
everlasting (like CCCP)