Googles New Sitelink Searchbox
-
Hey there people,
how can I add a json script to wp. Can I handle this a a normal javascript file and include the key values in a .js file? And can I add this with enqueue and register script in the child theme? I would like to add it in the functions.php. So any recommendations are welcome on how to implement this properly.
This is the script I neet do add:
<script type=”application/ld+json”>
{
“@context”: “http://schema.org”,
“@type”: “WebSite”,
“url”: “https://www.example-petstore.com/”,
“potentialAction”: {
“@type”: “SearchAction”,
“target”: “https://host.example-petstore.com/search?q={search_term}”,
“query-input”: “required name=search_term”
}
}
</script>in order to get this running:
https://developers.google.com/webmasters/richsnippets/sitelinkssearch
(of course when google wants it to be running;)hehe
thanks a lot guys!
Malte
- The topic ‘Googles New Sitelink Searchbox’ is closed to new replies.