?> class Akismet_REST_API { /** * Register the REST API routes. */ public static function init() { if ( ! function_exists( 'register_rest_route' ) ) { // The REST API wasn't integrated into core until 4.4, and we support 4.0+ (for now). return false; } register_rest_route( 'akismet/v1', '/key', array( array( 'methods' => WP_REST_Server::READABLE, 'permission_callback' => array( 'Akismet_REST_API', 'privileged_permission_callback' ), 'callback' => array( 'Akismet_REST_API', 'get_key' ), ), array( 'methods' => WP_REST_Server::EDITABLE, 'permission_callback' => array( 'Akismet_REST_API', 'privileged_permission_callback' ), 'callback' => array( 'Akismet_REST_API', 'set_key' ), 'args' => array( 'key' => array( 'required' => true, 'type' => 'string', 'sanitize_callback' => array( 'Akismet_REST_API', 'sanitize_key' ), 'description' => __( 'A 12-character Akismet API key. Available at akismet.com/get/', 'akismet' ), ), ), ), array( 'methods' => WP_REST_Server::DELETABLE, 'permission_callback' => array( 'Akismet_REST_API', 'privileged_permission_callback' ), 'callback' => array( 'Akismet_REST_API', 'delete_key' ), ) ) ); register_rest_route( 'akismet/v1', '/settings/', array( array( 'methods' => WP_REST_Server::READABLE, 'permission_callback' => array( 'Akismet_REST_API', 'privileged_permission_callback' ), 'callback' => array( 'Akismet_REST_API', 'get_settings' ), ), array( 'methods' => WP_REST_Server::EDITABLE, 'permission_callback' => array( 'Akismet_REST_API', 'privileged_permission_callback' ), 'callback' => array( 'Akismet_REST_API', 'set_boolean_settings' ), 'args' => array( 'akismet_strictness' => array( 'required' => false, 'type' => 'boolean', 'description' => __( 'If true, Akismet will automatically discard the worst spam automatically rather than putting it in the spam folder.', 'akismet' ), ), 'akismet_show_user_comments_approved' => array( 'required' => false, 'type' => 'boolean', 'description' => __( 'If true, show the number of approved comments beside each comment author in the comments list page.', 'akismet' ), ), ), ) ) ); register_rest_route( 'akismet/v1', '/stats', array( 'methods' => WP_REST_Server::READABLE, 'permission_callback' => array( 'Akismet_REST_API', 'privileged_permission_callback' ), 'callback' => array( 'Akismet_REST_API', 'get_stats' ), 'args' => array( 'interval' => array( 'required' => false, 'type' => 'string', 'sanitize_callback' => array( 'Akismet_REST_API', 'sanitize_interval' ), 'description' => __( 'The time period for which to retrieve stats. Options: 60-days, 6-months, all', 'akismet' ), 'default' => 'all', ), ), ) ); register_rest_route( 'akismet/v1', '/stats/(?P[\w+])', array( 'args' => array( 'interval' => array( 'description' => __( 'The time period for which to retrieve stats. Options: 60-days, 6-months, all', 'akismet' ), 'type' => 'string', ), ), array( 'methods' => WP_REST_Server::READABLE, 'permission_callback' => array( 'Akismet_REST_API', 'privileged_permission_callback' ), 'callback' => array( 'Akismet_REST_API', 'get_stats' ), ) ) ); register_rest_route( 'akismet/v1', '/alert', array( array( 'methods' => WP_REST_Server::READABLE, 'permission_callback' => array( 'Akismet_REST_API', 'remote_call_permission_callback' ), 'callback' => array( 'Akismet_REST_API', 'get_alert' ), 'args' => array( 'key' => array( 'required' => false, 'type' => 'string', 'sanitize_callback' => array( 'Akismet_REST_API', 'sanitize_key' ), 'description' => __( 'A 12-character Akismet API key. Available at akismet.com/get/', 'akismet' ), ), ), ), array( 'methods' => WP_REST_Server::EDITABLE, 'permission_callback' => array( 'Akismet_REST_API', 'remote_call_permission_callback' ), 'callback' => array( 'Akismet_REST_API', 'set_alert' ), 'args' => array( 'key' => array( 'required' => false, 'type' => 'string', 'sanitize_callback' => array( 'Akismet_REST_API', 'sanitize_key' ), 'description' => __( 'A 12-character Akismet API key. Available at akismet.com/get/', 'akismet' ), ), ), ), array( 'methods' => WP_REST_Server::DELETABLE, 'permission_callback' => array( 'Akismet_REST_API', 'remote_call_permission_callback' ), 'callback' => array( 'Akismet_REST_API', 'delete_alert' ), 'args' => array( 'key' => array( 'required' => false, 'type' => 'string', 'sanitize_callback' => array( 'Akismet_REST_API', 'sanitize_key' ), 'description' => __( 'A 12-character Akismet API key. Available at akismet.com/get/', 'akismet' ), ), ), ) ) ); } /** * Get the current Akismet API key. * * @param WP_REST_Request $request * @return WP_Error|WP_REST_Response */ public static function get_key( $request = null ) { return rest_ensure_response( Akismet::get_api_key() ); } /** * Set the API key, if possible. * * @param WP_REST_Request $request * @return WP_Error|WP_REST_Response */ public static function set_key( $request ) { if ( defined( 'WPCOM_API_KEY' ) ) { return rest_ensure_response( new WP_Error( 'hardcoded_key', __( 'This site\'s API key is hardcoded and cannot be changed via the API.', 'akismet' ), array( 'status'=> 409 ) ) ); } $new_api_key = $request->get_param( 'key' ); if ( ! self::key_is_valid( $new_api_key ) ) { return rest_ensure_response( new WP_Error( 'invalid_key', __( 'The value provided is not a valid and registered API key.', 'akismet' ), array( 'status' => 400 ) ) ); } update_option( 'wordpress_api_key', $new_api_key ); return self::get_key(); } /** * Unset the API key, if possible. * * @param WP_REST_Request $request * @return WP_Error|WP_REST_Response */ public static function delete_key( $request ) { if ( defined( 'WPCOM_API_KEY' ) ) { return rest_ensure_response( new WP_Error( 'hardcoded_key', __( 'This site\'s API key is hardcoded and cannot be deleted.', 'akismet' ), array( 'status'=> 409 ) ) ); } delete_option( 'wordpress_api_key' ); return rest_ensure_response( true ); } /** * Get the Akismet settings. * * @param WP_REST_Request $request * @return WP_Error|WP_REST_Response */ public static function get_settings( $request = null ) { return rest_ensure_response( array( 'akismet_strictness' => ( get_option( 'akismet_strictness', '1' ) === '1' ), 'akismet_show_user_comments_approved' => ( get_option( 'akismet_show_user_comments_approved', '1' ) === '1' ), ) ); } /** * Update the Akismet settings. * * @param WP_REST_Request $request * @return WP_Error|WP_REST_Response */ public static function set_boolean_settings( $request ) { foreach ( array( 'akismet_strictness', 'akismet_show_user_comments_approved', ) as $setting_key ) { $setting_value = $request->get_param( $setting_key ); if ( is_null( $setting_value ) ) { // This setting was not specified. continue; } // From 4.7+, WP core will ensure that these are always boolean // values because they are registered with 'type' => 'boolean', // but we need to do this ourselves for prior versions. $setting_value = Akismet_REST_API::parse_boolean( $setting_value ); update_option( $setting_key, $setting_value ? '1' : '0' ); } return self::get_settings(); } /** * Parse a numeric or string boolean value into a boolean. * * @param mixed $value The value to convert into a boolean. * @return bool The converted value. */ public static function parse_boolean( $value ) { switch ( $value ) { case true: case 'true': case '1': case 1: return true; case false: case 'false': case '0': case 0: return false; default: return (bool) $value; } } /** * Get the Akismet stats for a given time period. * * Possible `interval` values: * - all * - 60-days * - 6-months * * @param WP_REST_Request $request * @return WP_Error|WP_REST_Response */ public static function get_stats( $request ) { $api_key = Akismet::get_api_key(); $interval = $request->get_param( 'interval' ); $stat_totals = array(); $response = Akismet::http_post( Akismet::build_query( array( 'blog' => get_option( 'home' ), 'key' => $api_key, 'from' => $interval ) ), 'get-stats' ); if ( ! empty( $response[1] ) ) { $stat_totals[$interval] = json_decode( $response[1] ); } return rest_ensure_response( $stat_totals ); } /** * Get the current alert code and message. Alert codes are used to notify the site owner * if there's a problem, like a connection issue between their site and the Akismet API, * invalid requests being sent, etc. * * @param WP_REST_Request $request * @return WP_Error|WP_REST_Response */ public static function get_alert( $request ) { return rest_ensure_response( array( 'code' => get_option( 'akismet_alert_code' ), 'message' => get_option( 'akismet_alert_msg' ), ) ); } /** * Update the current alert code and message by triggering a call to the Akismet server. * * @param WP_REST_Request $request * @return WP_Error|WP_REST_Response */ public static function set_alert( $request ) { delete_option( 'akismet_alert_code' ); delete_option( 'akismet_alert_msg' ); // Make a request so the most recent alert code and message are retrieved. Akismet::verify_key( Akismet::get_api_key() ); return self::get_alert( $request ); } /** * Clear the current alert code and message. * * @param WP_REST_Request $request * @return WP_Error|WP_REST_Response */ public static function delete_alert( $request ) { delete_option( 'akismet_alert_code' ); delete_option( 'akismet_alert_msg' ); return self::get_alert( $request ); } private static function key_is_valid( $key ) { $response = Akismet::http_post( Akismet::build_query( array( 'key' => $key, 'blog' => get_option( 'home' ) ) ), 'verify-key' ); if ( $response[1] == 'valid' ) { return true; } return false; } public static function privileged_permission_callback() { return current_user_can( 'manage_options' ); } /** * For calls that Akismet.com makes to the site to clear outdated alert codes, use the API key for authorization. */ public static function remote_call_permission_callback( $request ) { $local_key = Akismet::get_api_key(); return $local_key && ( strtolower( $request->get_param( 'key' ) ) === strtolower( $local_key ) ); } public static function sanitize_interval( $interval, $request, $param ) { $interval = trim( $interval ); $valid_intervals = array( '60-days', '6-months', 'all', ); if ( ! in_array( $interval, $valid_intervals ) ) { $interval = 'all'; } return $interval; } public static function sanitize_key( $key, $request, $param ) { return trim( $key ); } } /** * Twenty Twenty-Five functions and definitions. * * @link https://developer.wordpress.org/themes/basics/theme-functions/ * * @package WordPress * @subpackage Twenty_Twenty_Five * @since Twenty Twenty-Five 1.0 */ if ( ! function_exists( 'twentytwentyfive_post_format_setup' ) ) : /** * Adds theme support for post formats. * * @since Twenty Twenty-Five 1.0 * * @return void */ function twentytwentyfive_post_format_setup() { add_theme_support( 'post-formats', array( 'aside', 'audio', 'chat', 'gallery', 'image', 'link', 'quote', 'status', 'video' ) ); } endif; add_action( 'after_setup_theme', 'twentytwentyfive_post_format_setup' ); if ( ! function_exists( 'twentytwentyfive_editor_style' ) ) : /** * Enqueues editor-style.css in the editors. * * @since Twenty Twenty-Five 1.0 * * @return void */ function twentytwentyfive_editor_style() { add_editor_style( 'assets/css/editor-style.css' ); } endif; add_action( 'after_setup_theme', 'twentytwentyfive_editor_style' ); if ( ! function_exists( 'twentytwentyfive_enqueue_styles' ) ) : /** * Enqueues the theme stylesheet on the front. * * @since Twenty Twenty-Five 1.0 * * @return void */ function twentytwentyfive_enqueue_styles() { $suffix = SCRIPT_DEBUG ? '' : '.min'; $src = 'style' . $suffix . '.css'; wp_enqueue_style( 'twentytwentyfive-style', get_parent_theme_file_uri( $src ), array(), wp_get_theme()->get( 'Version' ) ); wp_style_add_data( 'twentytwentyfive-style', 'path', get_parent_theme_file_path( $src ) ); } endif; add_action( 'wp_enqueue_scripts', 'twentytwentyfive_enqueue_styles' ); if ( ! function_exists( 'twentytwentyfive_block_styles' ) ) : /** * Registers custom block styles. * * @since Twenty Twenty-Five 1.0 * * @return void */ function twentytwentyfive_block_styles() { register_block_style( 'core/list', array( 'name' => 'checkmark-list', 'label' => __( 'Checkmark', 'twentytwentyfive' ), 'inline_style' => ' ul.is-style-checkmark-list { list-style-type: "\2713"; } ul.is-style-checkmark-list li { padding-inline-start: 1ch; }', ) ); } endif; add_action( 'init', 'twentytwentyfive_block_styles' ); if ( ! function_exists( 'twentytwentyfive_pattern_categories' ) ) : /** * Registers pattern categories. * * @since Twenty Twenty-Five 1.0 * * @return void */ function twentytwentyfive_pattern_categories() { register_block_pattern_category( 'twentytwentyfive_page', array( 'label' => __( 'Pages', 'twentytwentyfive' ), 'description' => __( 'A collection of full page layouts.', 'twentytwentyfive' ), ) ); register_block_pattern_category( 'twentytwentyfive_post-format', array( 'label' => __( 'Post formats', 'twentytwentyfive' ), 'description' => __( 'A collection of post format patterns.', 'twentytwentyfive' ), ) ); } endif; add_action( 'init', 'twentytwentyfive_pattern_categories' ); if ( ! function_exists( 'twentytwentyfive_register_block_bindings' ) ) : /** * Registers the post format block binding source. * * @since Twenty Twenty-Five 1.0 * * @return void */ function twentytwentyfive_register_block_bindings() { register_block_bindings_source( 'twentytwentyfive/format', array( 'label' => _x( 'Post format name', 'Label for the block binding placeholder in the editor', 'twentytwentyfive' ), 'get_value_callback' => 'twentytwentyfive_format_binding', ) ); } endif; add_action( 'init', 'twentytwentyfive_register_block_bindings' ); if ( ! function_exists( 'twentytwentyfive_format_binding' ) ) : /** * Callback function for the post format name block binding source. * * @since Twenty Twenty-Five 1.0 * * @return string|void Post format name, or nothing if the format is 'standard'. */ function twentytwentyfive_format_binding() { $post_format_slug = get_post_format(); if ( $post_format_slug && 'standard' !== $post_format_slug ) { return get_post_format_string( $post_format_slug ); } } endif; Fitness – Five F's of Life https://fivefoflife.com Faith, Fitness, Family, Friends, Finance Tue, 11 Aug 2026 11:21:59 +0000 en-US hourly 1 https://wordpress.org/?v=7.1 What have I learned in 2020 …. https://fivefoflife.com/?p=338&utm_source=rss&utm_medium=rss&utm_campaign=what-have-i-learned-in-2020 Thu, 21 Jan 2021 05:55:09 +0000 http://fivefoflife.com/?p=338 It’s been 3 years since I have blogged. I know I am long over due for one. I will say I am surprised that people have still made comments since I launched the book 10 years ago and people have shared similar thoughts. I do appreciate everyone that has come and visited the site. Anyways, I never imagine by 2020 there would a global pandemic. I am sure everyone will remember where they were when the shutdown happened for their location. For me, it was the day after my birthday in March when the shutdown all began. At first, everyone was extremely scared, but over time society has developed pandemic fatigue. We can see in the numbers that are being published that cases are climbing for the second wave at time of this blog post. Of course, there is a lot of sadness that has occurred with the deaths of over 1 Million+ globally1.

A lot of people have tried to guess when we will get back to normal. If you look back at the Spanish Flu2, it took 2 years from 1918-1920. That would be my best guess for normalcy because history tends to repeat itself. We anticipate we will have vaccines for COVID-19 by December, but it won’t reach the population until the middle of 2021 at the earliest due to the requirements of the vaccine. That’s why it’s important to keep your Fitness up (health) because if you get sick there might not be a full-proof way to treat you.

Where do we go from here?

There is only one place we can go…. forward. It’s going to be hard for many people if they have lost a loved one, but I am sure their loved ones would want them to move forward. I wish I can say things will be ok, but I really don’t know and that’s where Faith comes in. Faith that things will get better even though there is hurt, pain, and suffering from this pandemic. But you have to keep going. We have to remember our ancestor’s survival The Black Plague, Spanish Flu, and many other things throughout history. We will too survive!

Remember to hug your Family and Friends

Remember to hug your family and friends if even virtually.

What I realized I missed the most during 2020 was simply getting a chance to really spend quality time with my Family and Friends. We really don’t know when it will be our last time seeing them or spending time. If you are able to safely, remember to give them a hug. I think there are many benefits from hugging ranging from distressing to regenerating muscles3.

Thoughts on finances for 2020

During the past year, it’s been a struggle for many families since they could not work because of the restrictions. I have put together some links for us here:

https://www.usa.gov/help-with-bills
https://www.usa.gov/disaster-help-food-housing-bills

But you can do a quick google search to see if there are locate programs available in your area. Don’t be shy asking for help financially. The worst that can happen is that people will say no. But remember you got to put food on the table for yourself and family and people out there will help!

Last Thoughts to close out 2020

Again I know 2020 was not easy for many and myself, but we must keep on going. I will try to write more post as time permits.

References:

(1)Current MORTALITY ANALYSES:
https://coronavirus.jhu.edu/data/mortality

(2)Spanish Flu Info:
https://www.cdc.gov/flu/pandemic-resources/1918-commemoration/1918-pandemic-history.htm

(3) https://www.happify.com/hd/8-reasons-why-you-need-at-least-8-hugs-a-day/

]]>
It’s about the quality of your life not the quantity, but why not have both? https://fivefoflife.com/?p=295&utm_source=rss&utm_medium=rss&utm_campaign=its-about-the-quality-of-your-life-not-the-quantity-but-why-not-have-both https://fivefoflife.com/?p=295#comments Wed, 26 Jun 2013 04:47:16 +0000 http://fivefoflife.com/?p=295 3 Things I am happy about:

  • Air conditioning on a hot summer day
  • Swimming in the Pool
  • Company actually honoring warranty

I was watching this TED talk about how to live 100+.  It’s pretty good. Basically, you have 3 of the 5 F’s in it (Fitness, Family, & Friends).  I know the age old saying it’s all about the quality of life, but if you can have both quantity and quality why not go for it?

I would encourage people to watch it.

On a side note, I am going to start upgrading the site  =)

]]>
https://fivefoflife.com/?feed=rss2&p=295 4
F: Fitness => Just Do It https://fivefoflife.com/?p=290&utm_source=rss&utm_medium=rss&utm_campaign=f-fitness-just-do-it https://fivefoflife.com/?p=290#respond Mon, 17 Jun 2013 23:12:32 +0000 http://fivefoflife.com/?p=290 3 Things I am happy about:

  • Opportunity to grow and challenge myself
  • Amazon Kindle to deliver e-books wirelessly
  • Technology to make my life easier (I hope)

Short blog today. I saw an inspiring video about weight lost. If someone can loose 370 lbs (see video), I can sure loose just 20 lbs! I am looking for ways to reduce my sweet tooth now!

 

]]>
https://fivefoflife.com/?feed=rss2&p=290 0
Spring 2013 https://fivefoflife.com/?p=272&utm_source=rss&utm_medium=rss&utm_campaign=spring-2013 https://fivefoflife.com/?p=272#respond Sat, 13 Apr 2013 04:37:06 +0000 http://fivefoflife.com/?p=272 3 Things I am happy about:

  • Dodgeball Trampoline
  • Movies
  • Internet

Spring has finally arrived in Nashville. Every Spring reminds me of Spring outings,  outdoor activities, and trips.

Not a lot to write today, but found this quote:

The beauty of life is, while we can’t undo what is done, we can see it, understand it, learn from it and CHANGE! =)

Thought this post was interesting too….

]]>
https://fivefoflife.com/?feed=rss2&p=272 0
Having problems keeping your 2013 Resolutions? https://fivefoflife.com/?p=260&utm_source=rss&utm_medium=rss&utm_campaign=having-problems-keeping-your-2013-resolutions https://fivefoflife.com/?p=260#respond Wed, 02 Jan 2013 07:06:00 +0000 http://fivefoflife.com/?p=260 3 Things I am happy about:

  • Amazon – I get to buy gifts and send them directly and track it for presents
  • Friends to celebrate the New Years with =)
  • Heating inside my house; AC during summer time of course!

A lot of people including myself have challenges with keeping their NYE resolutions. We have the best intent, but are horrible at the execution. The easy answer is try harder, but the truth is we must convince ourselves that our goals are doable and let ourselves fail in order to get back up. I know my readers out there needs some steps….

Here is an article that I found and will use…

http://www.cbsnews.com/8301-505144_162-57349898/7-ways-to-keep-your-new-years-resolutions/

Best of Luck to Everyone for 2013 and their resolutions!

]]>
https://fivefoflife.com/?feed=rss2&p=260 0
Caught the Common Cold https://fivefoflife.com/?p=206&utm_source=rss&utm_medium=rss&utm_campaign=caught-the-common-cold https://fivefoflife.com/?p=206#respond Thu, 08 Nov 2012 19:59:53 +0000 http://fivefoflife.com/?p=206 3 Things I am happy about

  • Chicken Noodle Soup
  • Sleep
  • WordPress

I am definitely sick this week. I am so glad there chicken soup. As I am sick, it always reminds me of the importance of having a health life.  I also, got my first customer this week. It’s a great feeling!

]]>
https://fivefoflife.com/?feed=rss2&p=206 0
Lack of Time https://fivefoflife.com/?p=190&utm_source=rss&utm_medium=rss&utm_campaign=lack-of-time https://fivefoflife.com/?p=190#respond Wed, 17 Oct 2012 14:58:37 +0000 http://fivefoflife.com/?p=190 3 Things I am happy about:

  • Ability to travel
  • New iPhone 5
  • Fellowship

I have been challenge for the last few weeks for time. I argued that I don’t have time, but the truth is that perhaps I am not organizing my time correctly. I have failed to utilize my crossfit opportunities.  I will have to make it more of a priority.

]]>
https://fivefoflife.com/?feed=rss2&p=190 0
Cross Fit https://fivefoflife.com/?p=184&utm_source=rss&utm_medium=rss&utm_campaign=cross-fit https://fivefoflife.com/?p=184#respond Tue, 09 Oct 2012 04:07:00 +0000 http://fivefoflife.com/?p=184 3 Things I am happy about today:

  • Ability to do Cross Fit
  • Watching movies with Friends
  • $100 Startup

I started my road back to a health living today thru my 1st cross fit. I have not had soda for over two weeks. I have been drinking coconut juice and working out more thru dancing, volleyball, and tennis.  I am happy to report that I feel great about myself and I have started to implement the $100 start up with a few friends.

Cross Fit 1st Workout

]]>
https://fivefoflife.com/?feed=rss2&p=184 0
Thriving Under Uncontrollable Circumstances https://fivefoflife.com/?p=169&utm_source=rss&utm_medium=rss&utm_campaign=thriving-under-uncontrollable-circumstances https://fivefoflife.com/?p=169#respond Mon, 01 Oct 2012 22:53:50 +0000 http://fivefoflife.com/?p=169 3 Things I am happy about:

  • Learning to play the piano
  • Running 3.5 Miles Again
  • My friends wedding past Saturday

I have been M.I.A. for the past several months because summer break, school, and work.  I have recently been challenge with a sleep condition that effects millions of people that I can’t really control =P. But luckily there are treatments available. One treatment is simply loosing weight. As part of my Five F’s of Life, Fitness is critical because if you can’t take care of yourself, how can you take care of others.  Go watch Folks Over Knives. It will really challenge you on what you eat.

I am happy to comment that I am about to help challenge and keep my friends accountable to their dreams and commitments. I am meeting with one of my friends tonight to help her start a path to victory on her life.

 

]]>
https://fivefoflife.com/?feed=rss2&p=169 0
Elections & Jobs https://fivefoflife.com/?p=149&utm_source=rss&utm_medium=rss&utm_campaign=elections-jobs https://fivefoflife.com/?p=149#respond Wed, 11 Apr 2012 04:37:21 +0000 http://fivefoflife.com/?p=149 3 Things I am happy about:

  • Being able to help friends find jobs
  • Ability to create my own cloud
  • Beautiful Weather to run in

Quick post today. I have been busy working and just got a new roommate. Life is really busy with school and balancing life in general. I have been to two weddings and help a friend get engage in the last three weeks!

]]>
https://fivefoflife.com/?feed=rss2&p=149 0