PluginProbe
Yoast SEO – Advanced SEO with real-time guidance and built-in AI / 28.5
Yoast SEO – Advanced SEO with real-time guidance and built-in AI v28.5
28.5 28.4 28.3 28.2 28.1 28.0 27.9 27.8 27.7 27.6 27.5 trunk 18.0 18.1 18.2 18.3 18.4 18.4.1 18.5 18.5.1 18.6 18.7 18.8 18.9 19.0 All 129 releases
← All changes | src/generators/schema/website.php +9 -6 18.228.5 View file →
@@ -50,11 +50,10 @@
50 50 *
51 51 * @return array
52 52 */
53 53 private function add_alternate_name( $data ) {
54 - $alternate_name = $this->helpers->options->get( 'alternate_website_name', '' );
55 - if ( $alternate_name !== '' ) {
56 - $data['alternateName'] = $this->helpers->schema->html->smart_strip_tags( $alternate_name );
54 + if ( $this->context->alternate_site_name !== '' ) {
55 + $data['alternateName'] = $this->helpers->schema->html->smart_strip_tags( $this->context->alternate_site_name );
57 56 }
58 57
59 58 return $data;
60 59 }
@@ -71,9 +70,9 @@
71 70 private function internal_search_section( $data ) {
72 71 /**
73 72 * Filter: 'disable_wpseo_json_ld_search' - Allow disabling of the json+ld output.
74 73 *
75 - * @api bool $display_search Whether or not to display json+ld search on the frontend.
74 + * @param bool $display_search Whether or not to display json+ld search on the frontend.
76 75 */
77 76 if ( \apply_filters( 'disable_wpseo_json_ld_search', false ) ) {
78 77 return $data;
79 78 }
@@ -80,9 +79,9 @@
80 79
81 80 /**
82 81 * Filter: 'wpseo_json_ld_search_url' - Allows filtering of the search URL for Yoast SEO.
83 82 *
84 - * @api string $search_url The search URL for this site with a `{search_term_string}` variable.
83 + * @param string $search_url The search URL for this site with a `{search_term_string}` variable.
85 84 */
86 85 $search_url = \apply_filters( 'wpseo_json_ld_search_url', $this->context->site_url . '?s={search_term_string}' );
87 86
88 87 $data['potentialAction'][] = [
@@ -90,9 +89,13 @@
90 89 'target' => [
91 90 '@type' => 'EntryPoint',
92 91 'urlTemplate' => $search_url,
93 92 ],
94 - 'query-input' => 'required name=search_term_string',
93 + 'query-input' => [
94 + '@type' => 'PropertyValueSpecification',
95 + 'valueRequired' => true,
96 + 'valueName' => 'search_term_string',
97 + ],
95 98 ];
96 99
97 100 return $data;
98 101 }