| @@ 586-603 (lines=18) @@ | ||
| 583 | return apply_filters( 'jetpack_idc_second_step_header_lead', $string ); |
|
| 584 | } |
|
| 585 | ||
| 586 | function get_migrate_site_action_explanation() { |
|
| 587 | $html = wp_kses( |
|
| 588 | sprintf( |
|
| 589 | __( |
|
| 590 | 'Yes. <a href="%1$s">%2$s</a> is replacing <a href="%3$s">%4$s</a>. I would like to |
|
| 591 | migrate my stats and subscribers from <a href="%3$s">%4$s</a> to <a href="%1$s">%2$s</a>.', |
|
| 592 | 'jetpack' |
|
| 593 | ), |
|
| 594 | esc_url( get_home_url() ), |
|
| 595 | self::prepare_url_for_display( get_home_url() ), |
|
| 596 | esc_url( self::$wpcom_home_url ), |
|
| 597 | untrailingslashit( Jetpack::normalize_url_protocol_agnostic( esc_url_raw( self::$wpcom_home_url ) ) ) |
|
| 598 | ), |
|
| 599 | array( 'a' => array( 'href' => array() ) ) |
|
| 600 | ); |
|
| 601 | ||
| 602 | /** |
|
| 603 | * Allows overriding of the default text for explaining the migrate site action. |
|
| 604 | * |
|
| 605 | * @since 4.4.0 |
|
| 606 | * |
|
| @@ 625-642 (lines=18) @@ | ||
| 622 | return apply_filters( 'jetpack_idc_migrate_site_button_text', $string ); |
|
| 623 | } |
|
| 624 | ||
| 625 | function get_start_fresh_action_explanation() { |
|
| 626 | $html = wp_kses( |
|
| 627 | sprintf( |
|
| 628 | __( |
|
| 629 | 'No. <a href="%1$s">%2$s</a> is a new and different website that\'s separate from |
|
| 630 | <a href="%3$s">%4$s</a>. It requires a new connection to WordPress.com for new stats and subscribers.', |
|
| 631 | 'jetpack' |
|
| 632 | ), |
|
| 633 | esc_url( get_home_url() ), |
|
| 634 | self::prepare_url_for_display( get_home_url() ), |
|
| 635 | esc_url( self::$wpcom_home_url ), |
|
| 636 | untrailingslashit( Jetpack::normalize_url_protocol_agnostic( esc_url_raw( self::$wpcom_home_url ) ) ) |
|
| 637 | ), |
|
| 638 | array( 'a' => array( 'href' => array() ) ) |
|
| 639 | ); |
|
| 640 | ||
| 641 | /** |
|
| 642 | * Allows overriding of the default text for explaining the start fresh action. |
|
| 643 | * |
|
| 644 | * @since 4.4.0 |
|
| 645 | * |
|
| @@ 693-714 (lines=22) @@ | ||
| 690 | * |
|
| 691 | * @return string |
|
| 692 | */ |
|
| 693 | public function get_migrate_site_action_explanation() { |
|
| 694 | $html = wp_kses( |
|
| 695 | sprintf( |
|
| 696 | /* translators: %s: Site URL. */ |
|
| 697 | __( 'Yes. <a href="%1$s">%2$s</a> is replacing <a href="%3$s">%4$s</a>. I would like to migrate my stats and subscribers from <a href="%3$s">%4$s</a> to <a href="%1$s">%2$s</a>.', 'jetpack' ), |
|
| 698 | esc_url( get_home_url() ), |
|
| 699 | self::prepare_url_for_display( get_home_url() ), |
|
| 700 | esc_url( self::$wpcom_home_url ), |
|
| 701 | untrailingslashit( Jetpack::normalize_url_protocol_agnostic( esc_url_raw( self::$wpcom_home_url ) ) ) |
|
| 702 | ), |
|
| 703 | array( 'a' => array( 'href' => array() ) ) |
|
| 704 | ); |
|
| 705 | ||
| 706 | /** |
|
| 707 | * Allows overriding of the default text for explaining the migrate site action. |
|
| 708 | * |
|
| 709 | * @param string $html The HTML to be displayed. |
|
| 710 | * |
|
| 711 | * @since 4.4.0 |
|
| 712 | */ |
|
| 713 | return apply_filters( 'jetpack_idc_migrate_site_explanation', $html ); |
|
| 714 | } |
|
| 715 | ||
| 716 | /** |
|
| 717 | * Returns the migrate site button text. |
|
| @@ 739-760 (lines=22) @@ | ||
| 736 | * |
|
| 737 | * @return string |
|
| 738 | */ |
|
| 739 | public function get_start_fresh_action_explanation() { |
|
| 740 | $html = wp_kses( |
|
| 741 | sprintf( |
|
| 742 | /* translators: %s: Site URL. */ |
|
| 743 | __( 'No. <a href="%1$s">%2$s</a> is a new and different website that\'s separate from <a href="%3$s">%4$s</a>. It requires a new connection to WordPress.com for new stats and subscribers.', 'jetpack' ), |
|
| 744 | esc_url( get_home_url() ), |
|
| 745 | self::prepare_url_for_display( get_home_url() ), |
|
| 746 | esc_url( self::$wpcom_home_url ), |
|
| 747 | untrailingslashit( Jetpack::normalize_url_protocol_agnostic( esc_url_raw( self::$wpcom_home_url ) ) ) |
|
| 748 | ), |
|
| 749 | array( 'a' => array( 'href' => array() ) ) |
|
| 750 | ); |
|
| 751 | ||
| 752 | /** |
|
| 753 | * Allows overriding of the default text for explaining the start fresh action. |
|
| 754 | * |
|
| 755 | * @param string $html The HTML to be displayed. |
|
| 756 | * |
|
| 757 | * @since 4.4.0 |
|
| 758 | */ |
|
| 759 | return apply_filters( 'jetpack_idc_start_fresh_explanation', $html ); |
|
| 760 | } |
|
| 761 | ||
| 762 | /** |
|
| 763 | * Returns the start fresh button text. |
|