__( 'Close' ), ), array( 'label' => __( 'Learn more', 'polylang' ), 'link' => admin_url( 'admin.php?page=mlang&tab=lingotek' ), ), ); if ( $link = $this->get_activate_link() ) { $content .= ' ' . __( 'Click on Activate Lingotek to start translating.', 'polylang' ); $buttons[] = array( 'label' => __( 'Activate Lingotek', 'polylang' ), 'link' => str_replace( '&', '&', $link ), // wp_nonce_url escapes the url for html display. Here we want it for js ); } $args = array( 'pointer' => 'pll_lgt', 'id' => empty( $options['previous_version'] ) ? 'nav-tab-lingotek' : 'wp-admin-bar-languages', 'position' => array( 'edge' => 'top', 'align' => 'left', ), 'width' => 400, 'title' => __( 'Congratulations!', 'polylang' ), 'content' => $content, 'buttons' => $buttons, ); new PLL_Pointer( $args ); } /** * Adds the Lingotek tab in Polylang settings * * @since 1.7.7 * * @param array $tabs list of tabs * @return array modified liste of tabs */ public function add_tab( $tabs ) { $tabs['lingotek'] = 'Lingotek'; return $tabs; } /** * Displays the content in the Lingotek tab * * @since 1.7.7 */ public function display_tab() { $activate_link = $this->get_activate_link(); $links = array( 'activate' => array( 'label' => is_plugin_active( self::LINGOTEK ) ? __( 'Activated', 'polylang' ) : __( 'Activate', 'polylang' ), 'link' => $activate_link, 'classes' => 'button button-primary' . ( $activate_link ? '' : ' disabled' ), ), 'translation' => array( 'label' => __( 'Request Translation', 'polylang' ), 'link' => 'http://www.lingotek.com/wordpress/translation_bid', 'new_tab' => true, 'classes' => 'button button-primary', ), 'services' => array( 'label' => __( 'Request Services', 'polylang' ), 'link' => 'http://www.lingotek.com/wordpress/extra_services', 'new_tab' => true, 'classes' => 'button button-primary', ) ); printf( '
%s
', esc_html__( 'Polylang is now fully integrated with Lingotek, a professional translation management system!', 'polylang' ) ); $this->box( __( 'Automatically Translate My Site', 'polylang' ), __( 'Polylang is now fully integrated with Lingotek!', 'polylang' ), array( __( 'Access free machine translation for your site for up to 100,000 characters.', 'polylang' ), __( 'Machine translation is an excellent option if you\'re on a tight budget, looking for near-instant results, and are okay with less-than-perfect quality.', 'polylang' ), ), array_intersect_key( $links, array_flip( array( 'activate' ) ) ), 'image01.gif' ); $this->box( __( 'Translation Management System', 'polylang' ), __( 'Do you need to connect to a professional translation management system?', 'polylang' ), array( __( 'Access free machine translation for your site for up to 100,000 characters.', 'polylang' ), __( 'Access an online translator workbench.', 'polylang' ), __( 'Have linguists compare side-by-side versions of original and translated text.', 'polylang' ), __( 'Save and re-use previously translated material (leverage translation memory (TM)).', 'polylang' ), ), array_intersect_key( $links, array_flip( array( 'activate' ) ) ), 'image02.png' ); $this->box( __( 'Professionally Translate My Site', 'polylang' ), __( 'Do you need to professionally translate your site?', 'polylang' ), array( __( 'Start the process of getting a professional translation bid.', 'polylang' ), __( 'Activate account so Lingotek can get an accurate count of how many words you have on your site and which languages you wish to translate into.', 'polylang' ), __( 'Once activated click on the request translation bid and a certified translation project manager will contact you to give a no obligations translation bid.', 'polylang' ), ), array_intersect_key( $links, array_flip( array( 'activate', 'translation' ) ) ), 'image03.png' ); $this->box( __( 'Need Extra Services?', 'polylang' ), __( 'Do you need help translating your site?', 'polylang' ), array( __( 'Start the process of getting extra services.', 'polylang' ), __( 'Do you need someone to run your localization project?', 'polylang' ), __( 'Do you need customized workflows?', 'polylang' ), __( 'Do you have existing Translation Memories you would like to use?', 'polylang' ), __( 'Do you need help creating glossaries and terminologies?', 'polylang' ), ), array_intersect_key( $links, array_flip( array( 'activate', 'services' ) ) ), 'image04.png' ); } /** * Styles the content of the Lingotek tab * * @since 1.7.7 */ public function print_css() { ?>