plugins.php
61 lines
| 1 | <?php global $woocommerce_wpml, $sitepress; ?> |
| 2 | <div class="wrap"> |
| 3 | <div id="icon-wpml" class="icon32"><br /></div> |
| 4 | <h2><?php _e('WooCommerce Multilingual', 'wpml-wcml') ?></h2> |
| 5 | <a class="nav-tab nav-tab-active" href="admin.php?page=wpml-wcml"><?php _e('Required plugins', 'wpml-wcml') ?></a> |
| 6 | <div class="wcml_wrap"> |
| 7 | <div class="wcml-section"> |
| 8 | <div class="wcml-section-header"> |
| 9 | <h3> |
| 10 | <?php _e('Plugins Status','wpml-wcml'); ?> |
| 11 | <i class="icon-question-sign js-display-tooltip" data-header="<?php _e('Check required plugins', 'wpml-wcml') ?>" data-content="<?php _e('WooCommerce Multilingual depends on several plugins to work. If any required plugin is missing, you should install and activate it.', 'wpml-wcml') ?>"></i> |
| 12 | </h3> |
| 13 | </div> |
| 14 | <div class="wcml-section-content"> |
| 15 | <ul> |
| 16 | <?php if (defined('ICL_SITEPRESS_VERSION') && version_compare(ICL_SITEPRESS_VERSION, '2.0.5', '<')) : ?> |
| 17 | <li><i class="icon-warning-sign"></i> <?php printf(__('WooCommerce Multilingual is enabled but not effective. It is not compatible with <a href="%s">WPML</a> versions prior 2.0.5.', 'wpml-wcml'), $woocommerce_wpml->generate_tracking_link('http://wpml.org/')); ?> <a href="<?php echo $woocommerce_wpml->generate_tracking_link('http://wpml.org/shop/account/',false,'account') ?>" target="_blank"><?php _e('Update WPML', 'wpml-wcml'); ?></a></li> |
| 18 | <?php elseif (defined('ICL_SITEPRESS_VERSION')) : ?> |
| 19 | <li><i class="icon-ok"></i> <?php printf(__('%s plugin is installed and active.', 'wpml-wcml'), '<strong>WPML</strong>'); ?></li> |
| 20 | <?php if($sitepress->setup()): ?> |
| 21 | <li><i class="icon-ok"></i> <?php printf(__('%s is set up.', 'wpml-wcml'), '<strong>WPML</strong>'); ?></li> |
| 22 | <?php else: ?> |
| 23 | <li><i class="icon-warning-sign"></i> <?php printf(__('%s is not set up.', 'wpml-wcml'), '<strong>WPML</strong>'); ?></li> |
| 24 | <?php endif; ?> |
| 25 | <?php else : ?> |
| 26 | <li><i class="icon-warning-sign"></i> <?php printf(__('%s plugin is either not installed or not active.', 'wpml-wcml'), '<strong>WPML</strong>'); ?> <a href="<?php echo $woocommerce_wpml->generate_tracking_link('http://wpml.org/') ?>" target="_blank"><?php _e('Get WPML', 'wpml-wcml'); ?></a></li> |
| 27 | <?php endif; ?> |
| 28 | <?php if (defined('WPML_MEDIA_VERSION')) : ?> |
| 29 | <li><i class="icon-ok"></i> <?php printf(__('%s plugin is installed and active.', 'wpml-wcml'), '<strong>WPML Media</strong>'); ?></li> |
| 30 | <?php else : ?> |
| 31 | <li><i class="icon-warning-sign"></i> <?php printf(__('%s plugin is either not installed or not active.', 'wpml-wcml'), '<strong>WPML Media</strong>'); ?> <a href="<?php echo $woocommerce_wpml->generate_tracking_link('http://wpml.org/') ?>" target="_blank"><?php _e('Get WPML Media', 'wpml-wcml'); ?></a></li> |
| 32 | <?php endif; ?> |
| 33 | <?php if (defined('WPML_TM_VERSION')) : ?> |
| 34 | <li><i class="icon-ok"></i> <?php printf(__('%s plugin is installed and active.', 'wpml-wcml'), '<strong>WPML Translation Management</strong>'); ?></li> |
| 35 | <?php else : ?> |
| 36 | <li><i class="icon-warning-sign"></i> <?php printf(__('%s plugin is either not installed or not active.', 'wpml-wcml'), '<strong>WPML Translation Management</strong>'); ?> <a href="<?php echo $woocommerce_wpml->generate_tracking_link('http://wpml.org/') ?>" target="_blank"><?php _e('Get WPML Translation Management', 'wpml-wcml'); ?></a></li> |
| 37 | <?php endif; ?> |
| 38 | <?php if (defined('WPML_ST_VERSION')) : ?> |
| 39 | <li><i class="icon-ok"></i> <?php printf(__('%s plugin is installed and active.', 'wpml-wcml'), '<strong>WPML String Translation</strong>'); ?></li> |
| 40 | <?php else : ?> |
| 41 | <li><i class="icon-warning-sign"></i> <?php printf(__('%s plugin is either not installed or not active.', 'wpml-wcml'), '<strong>WPML String Translation</strong>'); ?> <a href="<?php echo $woocommerce_wpml->generate_tracking_link('http://wpml.org/') ?>" target="_blank"><?php _e('Get WPML String Translation', 'wpml-wcml'); ?></a></li> |
| 42 | <?php endif; ?> |
| 43 | <?php |
| 44 | global $woocommerce; |
| 45 | if (class_exists('Woocommerce') && $woocommerce && isset($woocommerce->version) && version_compare($woocommerce->version, '2.0', '<')) : |
| 46 | ?> |
| 47 | <li><i class="icon-warning-sign"></i> <?php printf(__('%1$s is installed, but with incorrect version. You need %1$s %2$s or higher. ', 'wpml-wcml'), '<strong>WooCommerce</strong>', '2.0'); ?> <a href="http://wordpress.org/extend/plugins/woocommerce/" target="_blank"><?php _e('Download WooCommerce', 'wpml-wcml'); ?></a></li> |
| 48 | <?php elseif (class_exists('Woocommerce')) : ?> |
| 49 | <li><i class="icon-ok"></i> <?php printf(__('%s plugin is installed and active.', 'wpml-wcml'), '<strong>WooCommerce</strong>'); ?></li> |
| 50 | <?php else : ?> |
| 51 | <li><i class="icon-warning-sign"></i> <?php printf(__('%s plugin is either not installed or not active.', 'wpml-wcml'), '<strong>WooCommerce</strong>'); ?> <a href="http://wordpress.org/extend/plugins/woocommerce/" target="_blank"><?php _e('Download WooCommerce', 'wpml-wcml'); ?></a></li> |
| 52 | <?php endif; ?> |
| 53 | </ul> |
| 54 | </div> <!-- .wcml-section-content --> |
| 55 | |
| 56 | </div> <!-- .wcml-section --> |
| 57 | </div> |
| 58 | |
| 59 | </div> |
| 60 | |
| 61 |