partials
5 years ago
custom-logo.php
5 years ago
elements.php
5 years ago
general.php
5 years ago
go-premium.php
5 years ago
license.php
5 years ago
main-template.php
5 years ago
twitch.php
5 years ago
vimeo.php
5 years ago
wistia.php
5 years ago
youtube.php
5 years ago
vimeo.php
153 lines
| 1 | <?php |
| 2 | /* |
| 3 | * Vimeo Settings page |
| 4 | * All undefined vars comes from 'render_settings_page' method |
| 5 | * */ |
| 6 | $vm_settings = get_option( EMBEDPRESS_PLG_NAME.':vimeo' ); |
| 7 | $autoplay = isset( $vm_settings['autoplay']) ? $vm_settings['autoplay'] : ''; |
| 8 | $loop = isset( $vm_settings['loop']) ? $vm_settings['loop'] : ''; |
| 9 | $autopause = isset( $vm_settings['autopause']) ? $vm_settings['autopause'] : ''; |
| 10 | $vimeo_dnt = isset( $vm_settings['vimeo_dnt']) ? $vm_settings['vimeo_dnt'] : 1; |
| 11 | $color = isset( $vm_settings['color']) ? $vm_settings['color'] : '#5b4e96';//@TODO; ask to confirm #00adef. |
| 12 | $display_title = isset( $vm_settings['display_title']) ? $vm_settings['display_title'] : 1; |
| 13 | $display_author = isset( $vm_settings['display_author']) ? $vm_settings['display_author'] : 1; |
| 14 | $display_avatar = isset( $vm_settings['display_avatar']) ? $vm_settings['display_avatar'] : 1; |
| 15 | ?> |
| 16 | <div class="embedpress__settings background__white radius-25 p40"> |
| 17 | <h3><?php esc_html_e( "Vimeo Settings", "embedpress" ); ?></h3> |
| 18 | <div class="embedpress__settings__form"> |
| 19 | <form action="" method="post" class="embedpress-settings-form" > |
| 20 | <?php |
| 21 | do_action( 'embedpress_before_vimeo_settings_fields'); |
| 22 | echo $nonce_field ; ?> |
| 23 | <div class="form__group"> |
| 24 | <p class="form__label"><?php esc_html_e( "Auto Play", "embedpress" ); ?></p> |
| 25 | <div class="form__control__wrap"> |
| 26 | <div data-default="<?php echo esc_attr( $autoplay ); ?>" data-value="<?php echo esc_attr( $autoplay ); ?>" class="input__flex input__radio_wrap"> |
| 27 | <label class="input__radio"> |
| 28 | <input type="radio" name="autoplay" value="" <?php checked( '', $autoplay); ?>> |
| 29 | <span><?php esc_html_e( "No", "embedpress" ); ?></span> |
| 30 | </label> |
| 31 | <label class="input__radio"> |
| 32 | <input type="radio" name="autoplay" value="1" <?php checked( '1', $autoplay); ?>> |
| 33 | <span><?php esc_html_e( "Yes", "embedpress" ); ?></span> |
| 34 | </label> |
| 35 | </div> |
| 36 | <p><?php esc_html_e( "Automatically start to play the videos when the player loads.", "embedpress" ); ?></p> |
| 37 | </div> |
| 38 | </div> |
| 39 | <div class="form__group"> |
| 40 | <p class="form__label"><?php esc_html_e( "Loop", "embedpress" ); echo $pro_active ? '': ' <span class="isPro">PRO</span>'; ?></p> |
| 41 | <div class="form__control__wrap"> |
| 42 | <div data-default="<?php echo esc_attr( $loop ); ?>" data-value="<?php echo esc_attr( $loop ); ?>" class="input__flex input__radio_wrap <?php echo $pro_active ? '': 'isPro'; ?>"> |
| 43 | <label class="input__radio"> |
| 44 | <input type="radio" name="loop" value="" <?php echo !$pro_active ? 'disabled ' : ''; checked( '', $loop); ?>> |
| 45 | <span><?php esc_html_e( "No", "embedpress" ); ?></span> |
| 46 | </label> |
| 47 | <label class="input__radio"> |
| 48 | <input type="radio" name="loop" value="1" <?php echo !$pro_active ? 'disabled ' : ''; checked( '1', $loop); ?>> |
| 49 | <span><?php esc_html_e( "Yes", "embedpress" ); ?></span> |
| 50 | </label> |
| 51 | </div> |
| 52 | <?php if ( !$pro_active ) { include EMBEDPRESS_SETTINGS_PATH . 'templates/partials/alert-pro.php'; } ?> |
| 53 | <p><?php esc_html_e( "Play the video again automatically when it reaches the end.", "embedpress" ); ?></p> |
| 54 | </div> |
| 55 | </div> |
| 56 | <div class="form__group"> |
| 57 | <p class="form__label"><?php esc_html_e( "Auto Pause", "embedpress" ); echo $pro_active ? '': ' <span class="isPro">PRO</span>'; ?></p> |
| 58 | <div class="form__control__wrap"> |
| 59 | <div data-default="<?php echo esc_attr( $autopause ); ?>" data-value="<?php echo esc_attr( $autopause ); ?>" class="input__flex input__radio_wrap <?php echo $pro_active ? '': 'isPro'; ?>"> |
| 60 | <label class="input__radio"> |
| 61 | <input type="radio" name="autopause" value="" <?php echo !$pro_active ? 'disabled ' : ''; checked( '', $autopause); ?>> |
| 62 | <span><?php esc_html_e( "No", "embedpress" ); ?></span> |
| 63 | </label> |
| 64 | <label class="input__radio"> |
| 65 | <input type="radio" name="autopause" value="1" <?php echo !$pro_active ? 'disabled ' : ''; checked( '1', $autopause); ?>> |
| 66 | <span><?php esc_html_e( "Yes", "embedpress" ); ?></span> |
| 67 | </label> |
| 68 | </div> |
| 69 | <?php if ( !$pro_active ) { include EMBEDPRESS_SETTINGS_PATH . 'templates/partials/alert-pro.php'; } ?> |
| 70 | <p><?php esc_html_e( "Pause this video automatically when another one plays.", "embedpress" ); ?></p> |
| 71 | </div> |
| 72 | </div> |
| 73 | <div class="form__group"> |
| 74 | <p class="form__label"><?php esc_html_e( "DNT", "embedpress" ); echo $pro_active ? '': ' <span class="isPro">PRO</span>'; ?></p> |
| 75 | <div class="form__control__wrap"> |
| 76 | <div data-default="<?php echo esc_attr( $vimeo_dnt ); ?>" data-value="<?php echo esc_attr( $vimeo_dnt ); ?>" class="input__flex input__radio_wrap <?php echo $pro_active ? '': 'isPro'; ?>"> |
| 77 | <label class="input__radio"> |
| 78 | <input type="radio" name="vimeo_dnt" value="" <?php echo !$pro_active ? 'disabled ' : ''; checked( '', $vimeo_dnt); ?>> |
| 79 | <span><?php esc_html_e( "No", "embedpress" ); ?></span> |
| 80 | </label> |
| 81 | <label class="input__radio"> |
| 82 | <input type="radio" name="vimeo_dnt" value="1" <?php echo !$pro_active ? 'disabled ' : ''; checked( '1', $vimeo_dnt); ?>> |
| 83 | <span><?php esc_html_e( "Yes", "embedpress" ); ?></span> |
| 84 | </label> |
| 85 | </div> |
| 86 | <?php if ( !$pro_active ) { include EMBEDPRESS_SETTINGS_PATH . 'templates/partials/alert-pro.php'; } ?> |
| 87 | <p><?php esc_html_e( 'Setting this parameter to "yes" will block the player from tracking any session data, including all cookies.', "embedpress" ); ?></p> |
| 88 | </div> |
| 89 | </div> |
| 90 | <div class="form__group"> |
| 91 | <p class="form__label"><?php esc_html_e( "Color", "embedpress" ); ?></p> |
| 92 | <div class="form__control__wrap"> |
| 93 | <input type="text" class="form__control ep-color-picker" name="color" value="<?php echo esc_attr( $color); ?>" data-default="<?php echo esc_attr( $color ); ?>"> |
| 94 | |
| 95 | <p><?php esc_html_e( "Specify the color of the video controls.", "embedpress" ); ?></p> |
| 96 | </div> |
| 97 | </div> |
| 98 | <div class="form__group"> |
| 99 | <p class="form__label"><?php esc_html_e( "Display Title", "embedpress" ); ?></p> |
| 100 | <div class="form__control__wrap"> |
| 101 | <div data-default="<?php echo esc_attr( $display_title ); ?>" data-value="<?php echo esc_attr( $display_title ); ?>" class="input__flex input__radio_wrap"> |
| 102 | <label class="input__radio"> |
| 103 | <input type="radio" name="display_title" value="" <?php checked( '', $display_title); ?>> |
| 104 | <span><?php esc_html_e( "No", "embedpress" ); ?></span> |
| 105 | </label> |
| 106 | <label class="input__radio"> |
| 107 | <input type="radio" name="display_title" value="1" <?php checked( '1', $display_title); ?>> |
| 108 | <span><?php esc_html_e( "Yes", "embedpress" ); ?></span> |
| 109 | </label> |
| 110 | </div> |
| 111 | <p><?php esc_html_e( "Indicates whether the title is displayed.", "embedpress" ); ?></p> |
| 112 | </div> |
| 113 | </div> |
| 114 | <div class="form__group"> |
| 115 | <p class="form__label"><?php esc_html_e( "Display Author", "embedpress" ); echo $pro_active ? '': ' <span class="isPro">PRO</span>'; ?></p> |
| 116 | <div class="form__control__wrap"> |
| 117 | <div data-default="<?php echo esc_attr( $display_author ); ?>" data-value="<?php echo esc_attr( $display_author ); ?>" class="input__flex input__radio_wrap <?php echo $pro_active ? '': 'isPro'; ?>"> |
| 118 | <label class="input__radio"> |
| 119 | <input type="radio" name="display_author" value="" <?php echo !$pro_active ? 'disabled ' : ''; checked( '', $display_author); ?>> |
| 120 | <span><?php esc_html_e( "No", "embedpress" ); ?></span> |
| 121 | </label> |
| 122 | <label class="input__radio"> |
| 123 | <input type="radio" name="display_author" value="1" <?php echo !$pro_active ? 'disabled ' : ''; checked( '1', $display_author); ?>> |
| 124 | <span><?php esc_html_e( "Yes", "embedpress" ); ?></span> |
| 125 | </label> |
| 126 | </div> |
| 127 | <?php if ( !$pro_active ) { include EMBEDPRESS_SETTINGS_PATH . 'templates/partials/alert-pro.php'; } ?> |
| 128 | <p><?php esc_html_e( "Indicates whether the author is displayed.", "embedpress" ); ?></p> |
| 129 | </div> |
| 130 | </div> |
| 131 | <div class="form__group"> |
| 132 | <p class="form__label"><?php esc_html_e( "Display Avatar", "embedpress" ); echo $pro_active ? '': ' <span class="isPro">PRO</span>'; ?></p> |
| 133 | <div class="form__control__wrap"> |
| 134 | <div data-default="<?php echo esc_attr( $display_avatar ); ?>" data-value="<?php echo esc_attr( $display_avatar ); ?>" class="input__flex input__radio_wrap <?php echo $pro_active ? '': 'isPro'; ?>"> |
| 135 | <label class="input__radio"> |
| 136 | <input type="radio" name="display_avatar" value="" <?php echo !$pro_active ? 'disabled ' : ''; checked( '', $display_avatar); ?>> |
| 137 | <span><?php esc_html_e( "No", "embedpress" ); ?></span> |
| 138 | </label> |
| 139 | <label class="input__radio"> |
| 140 | <input type="radio" name="display_avatar" value="1" <?php echo !$pro_active ? 'disabled ' : ''; checked( '1', $display_avatar); ?>> |
| 141 | <span><?php esc_html_e( "Yes", "embedpress" ); ?></span> |
| 142 | </label> |
| 143 | </div> |
| 144 | <?php if ( !$pro_active ) { include EMBEDPRESS_SETTINGS_PATH . 'templates/partials/alert-pro.php'; } ?> |
| 145 | <p><?php esc_html_e( "Indicates whether the avatar is displayed.", "embedpress" ); ?></p> |
| 146 | </div> |
| 147 | </div> |
| 148 | <?php do_action( 'embedpress_after_vimeo_settings_fields'); ?> |
| 149 | <button class="button button__themeColor radius-10 embedpress-submit-btn" name="submit" value="vimeo"><?php esc_html_e( 'Save Changes', 'embedpress'); ?></button> |
| 150 | </form> |
| 151 | </div> |
| 152 | </div> |
| 153 |