Plugin Directory

Changeset 1494496


Ignore:
Timestamp:
09/12/2016 12:29:28 PM (10 years ago)
Author:
nathanbru
Message:

Updates

Location:
wibbitz
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • wibbitz/tags/0.1/readme.txt

    r1494452 r1494496  
    2323Next Clip - auto or manual.
    2424
    25 
    2625== Installation ==
    2726
     
    3130== Usage ==
    3231
    33 Clip id - wibbitz-clip-id="b8a8ff52014cd408ea8a3b219b428d084"
     32Clip id - wibbitz-clip-id=b8a8ff52014cd408ea8a3b219b428d084
    3433Autoplay options - wibbitz-autoplay="false" | wibbitz-autoplay="true" | wibbitz-autoplay="scroll"
    3534Sound options - wibbitz-mute="true" | wibbitz-mute="false"
    3635Clip next options - wibbitz-next="auto" | wibbitz-next="manual" | wibbitz-next="auto-delay"
     36Hover to unmute - wibbitz-hovertounmute="true" (Only when autoplay and mute are enabled).
    3737
    3838== Example Usage ==
  • wibbitz/tags/0.1/wibbitz.php

    r1494452 r1494496  
    2020            'wibbitz-autoplay' => 'wibbitz-autoplay',
    2121            'wibbitz-mute' => 'wibbitz-mute',
    22             'wibbitz-next' => 'wibbitz-next'
     22            'wibbitz-next' => 'wibbitz-next',
     23            'wibbitz-hovertounmute' => 'wibbitz-hovertounmute'
    2324        ), $atts);
    2425
     
    2627        wp_enqueue_script('script', plugin_dir_url(__FILE__) . 'script.js');
    2728
    28         // Create player div with parameters
    29         return '<div wibbitz="wbtz-static-embed" wibbitz-clip-id="' . $atts['wibbitz-clip-id'] . '" wibbitz-autoplay="' . $atts['wibbitz-autoplay']  . '" wibbitz-mute="' . $atts['wibbitz-mute'] . '" wibbitz-next="' . $atts['wibbitz-next'] . '"></div>';
     29        // Handle autoplay mute
     30        if ($atts['wibbitz-autoplay'] === "true" && $atts['wibbitz-mute'] === "true") {
     31            return '<div wibbitz="wbtz-static-embed" wibbitz-clip-id="' . $atts['wibbitz-clip-id'] . '" wibbitz-autoplay="' . $atts['wibbitz-autoplay']  . '" wibbitz-mute="' . $atts['wibbitz-mute'] . '" wibbitz-next="' . $atts['wibbitz-next'] . '" wibbitz-hovertounmute="' . $atts['wibbitz-hovertounmute'] . '"></div>';
     32        } else {
     33            return '<div wibbitz="wbtz-static-embed" wibbitz-clip-id="' . $atts['wibbitz-clip-id'] . '" wibbitz-autoplay="' . $atts['wibbitz-autoplay']  . '" wibbitz-mute="' . $atts['wibbitz-mute'] . '" wibbitz-next="' . $atts['wibbitz-next'] . '"></div>';
     34        }
    3035    }
    3136?>
  • wibbitz/trunk/readme.txt

    r1494452 r1494496  
    2323Next Clip - auto or manual.
    2424
    25 
    2625== Installation ==
    2726
     
    3130== Usage ==
    3231
    33 Clip id - wibbitz-clip-id="b8a8ff52014cd408ea8a3b219b428d084"
     32Clip id - wibbitz-clip-id=b8a8ff52014cd408ea8a3b219b428d084
    3433Autoplay options - wibbitz-autoplay="false" | wibbitz-autoplay="true" | wibbitz-autoplay="scroll"
    3534Sound options - wibbitz-mute="true" | wibbitz-mute="false"
    3635Clip next options - wibbitz-next="auto" | wibbitz-next="manual" | wibbitz-next="auto-delay"
     36Hover to unmute - wibbitz-hovertounmute="true" (Only when autoplay and mute are enabled).
    3737
    3838== Example Usage ==
  • wibbitz/trunk/wibbitz.php

    r1494452 r1494496  
    2020            'wibbitz-autoplay' => 'wibbitz-autoplay',
    2121            'wibbitz-mute' => 'wibbitz-mute',
    22             'wibbitz-next' => 'wibbitz-next'
     22            'wibbitz-next' => 'wibbitz-next',
     23            'wibbitz-hovertounmute' => 'wibbitz-hovertounmute'
    2324        ), $atts);
    2425
     
    2627        wp_enqueue_script('script', plugin_dir_url(__FILE__) . 'script.js');
    2728
    28         // Create player div with parameters
    29         return '<div wibbitz="wbtz-static-embed" wibbitz-clip-id="' . $atts['wibbitz-clip-id'] . '" wibbitz-autoplay="' . $atts['wibbitz-autoplay']  . '" wibbitz-mute="' . $atts['wibbitz-mute'] . '" wibbitz-next="' . $atts['wibbitz-next'] . '"></div>';
     29        // Handle autoplay mute
     30        if ($atts['wibbitz-autoplay'] === "true" && $atts['wibbitz-mute'] === "true") {
     31            return '<div wibbitz="wbtz-static-embed" wibbitz-clip-id="' . $atts['wibbitz-clip-id'] . '" wibbitz-autoplay="' . $atts['wibbitz-autoplay']  . '" wibbitz-mute="' . $atts['wibbitz-mute'] . '" wibbitz-next="' . $atts['wibbitz-next'] . '" wibbitz-hovertounmute="' . $atts['wibbitz-hovertounmute'] . '"></div>';
     32        } else {
     33            return '<div wibbitz="wbtz-static-embed" wibbitz-clip-id="' . $atts['wibbitz-clip-id'] . '" wibbitz-autoplay="' . $atts['wibbitz-autoplay']  . '" wibbitz-mute="' . $atts['wibbitz-mute'] . '" wibbitz-next="' . $atts['wibbitz-next'] . '"></div>';
     34        }
    3035    }
    3136?>
Note: See TracChangeset for help on using the changeset viewer.