| @@ -1,10 +1,10 @@ | ||
| 1 | 1 | <?php |
| 2 | 2 | /** |
| 3 | - * Plugin Name: WpStream - Live Streaming, Video on Demand, Pay Per View | |
| 3 | + * Plugin Name: WpStream | |
| 4 | 4 | * Plugin URI: http://wpstream.net |
| 5 | - * Description: WpStream is a platform that allows you to live stream, create Video-on-Demand, and offer Pay-Per-View videos. We provide an affordable and user-friendly way for businesses, non-profits, and public institutions to broadcast their content and monetize their work. | |
| 6 | - * Version: 4.4.4 | |
| 5 | + * Description: WpStream is a WordPress plugin to help you stream & monetize media content. | |
| 6 | + * Version: 3.8 | |
| 7 | 7 | * Author: wpstream |
| 8 | 8 | * Author URI: http://wpstream.net |
| 9 | 9 | * Text Domain: wpstream |
| 10 | 10 | * Domain Path: /languages |
| @@ -13,9 +13,9 @@ | ||
| 13 | 13 | // If this file is called directly, abort. |
| 14 | 14 | if ( ! defined( 'WPINC' ) ) { |
| 15 | 15 | die; |
| 16 | 16 | } |
| 17 | -define('WPSTREAM_PLUGIN_VERSION', '4.4.4'); | |
| 17 | +define('WPSTREAM_PLUGIN_VERSION', '3.8.1'); | |
| 18 | 18 | define('WPSTREAM_CLUBLINK', 'wpstream.net'); |
| 19 | 19 | define('WPSTREAM_CLUBLINKSSL', 'https'); |
| 20 | 20 | define('WPSTREAM_PLUGIN_URL', plugins_url() ); |
| 21 | 21 | define('WPSTREAM_PLUGIN_DIR_URL', plugin_dir_url(__FILE__) ); |
| @@ -20,15 +20,15 @@ | ||
| 20 | 20 | define('WPSTREAM_PLUGIN_URL', plugins_url() ); |
| 21 | 21 | define('WPSTREAM_PLUGIN_DIR_URL', plugin_dir_url(__FILE__) ); |
| 22 | 22 | define('WPSTREAM_PLUGIN_PATH', plugin_dir_path(__FILE__) ); |
| 23 | 23 | define('WPSTREAM_PLUGIN_BASE', plugin_basename(__FILE__) ); |
| 24 | -define('WPSTREAM_API', 'https://baker.wpstream.net'); | |
| 24 | +/** | |
| 25 | + * Currently plugin version. | |
| 26 | + * Start at version 3.0.1 and use SemVer - https://semver.org | |
| 27 | + * Rename this for your plugin and update it as you release new versions. | |
| 28 | + */ | |
| 29 | +define( 'WPSTREAM_VERSION', '3.8.0.0' ); | |
| 25 | 30 | |
| 26 | - | |
| 27 | - | |
| 28 | - | |
| 29 | - | |
| 30 | - | |
| 31 | 31 | /** |
| 32 | 32 | * The code that runs during plugin activation. |
| 33 | 33 | * This action is documented in includes/class-wpstream-activator.php |
| 34 | 34 | */ |
| @@ -69,66 +69,5 @@ | ||
| 69 | 69 | */ |
| 70 | 70 | |
| 71 | 71 | global $wpstream_plugin; |
| 72 | 72 | $wpstream_plugin = new Wpstream(); |
| 73 | -$wpstream_plugin->run(); | |
| 74 | - | |
| 75 | -add_action( 'upgrader_process_complete', 'wpstream_my_upgrate_function',10, 2); | |
| 76 | - | |
| 77 | -function wpstream_my_upgrate_function( $upgrader_object, $options ) { | |
| 78 | - | |
| 79 | - | |
| 80 | - $current_plugin_path_name = plugin_basename( __FILE__ ); | |
| 81 | - | |
| 82 | - if ($options['action'] == 'update' && $options['type'] == 'plugin' ) { | |
| 83 | - if(is_array($options)): | |
| 84 | - foreach($options['plugins'] as $each_plugin) { | |
| 85 | - if ($each_plugin==$current_plugin_path_name) { | |
| 86 | - delete_transient('wpstream_token_api'); | |
| 87 | - update_option('wp_estate_token_expire',0); | |
| 88 | - update_option('wp_estate_curent_token',' '); | |
| 89 | - | |
| 90 | - } | |
| 91 | - } | |
| 92 | - endif; | |
| 93 | - } | |
| 94 | - | |
| 95 | - | |
| 96 | -} | |
| 97 | - | |
| 98 | - | |
| 99 | - | |
| 100 | -add_action('wp_head', 'wpstream_add_custom_meta_to_header'); | |
| 101 | - | |
| 102 | -function wpstream_add_custom_meta_to_header(){ | |
| 103 | - global $post; | |
| 104 | - | |
| 105 | - | |
| 106 | - if ( is_singular('product') || is_singular('wpstream_product') || is_singular('wpstream_product_vod') ){ | |
| 107 | - $image_id = get_post_thumbnail_id(); | |
| 108 | - $share_img = wp_get_attachment_image_src( $image_id, 'full'); | |
| 109 | - $the_post = get_post($post->ID); ?> | |
| 110 | - | |
| 111 | - <meta property='og:title' content="<?php print esc_html(get_the_title($post->ID)); ?>"/> | |
| 112 | - <?php if(isset($share_img[0])){ ?> | |
| 113 | - <meta property="og:image" content="<?php print esc_url($share_img[0]); ?>"/> | |
| 114 | - <meta property="og:image:secure_url" content="<?php print esc_url($share_img[0]); ?>" /> | |
| 115 | - <?php }?> | |
| 116 | - | |
| 117 | - <meta property="og:description" content=" <?php print wp_strip_all_tags( $the_post->post_content);?>" /> | |
| 118 | - <?php } | |
| 119 | - | |
| 120 | - | |
| 121 | -} | |
| 122 | - | |
| 123 | -/* | |
| 124 | -* | |
| 125 | -* Redirect on plugin activation | |
| 126 | -* | |
| 127 | -*/ | |
| 128 | - | |
| 129 | -function wpstream_activation_redirect( $plugin ) { | |
| 130 | - if( $plugin == plugin_basename( __FILE__ ) ) { | |
| 131 | - exit( wp_redirect( admin_url( 'admin.php?page=wpstream_onboard' ) ) ); | |
| 132 | - } | |
| 133 | -} | |
| 134 | -add_action( 'activated_plugin', 'wpstream_activation_redirect' ); | |
| 73 | +$wpstream_plugin->run(); | |