Syntax error sitelinks searchbox

New Member
3 0 0

BRIAN,

I have read all the threads and topic in regard to this error i am incurring. PLEASE HELP ME ! as no one else can. i have been stuck with this for th elast 2 days now.

My website is www.jjtechnologies.com.au

Shopify URL JJTECHNOLOGIES.myshopify.com


@BrianAtWork wrote:

Hi @Moonglowattrac,

 

Welcome to the Shopify Community!

 

I understand that you're having an issue with Google Webmaster. When it crawls your page, you are getting an error "Syntax error in sitelinks searchbox".

 

This is often caused by a third-party app conflicting with your theme's default sitelink code.

 

I may be able to hep you with this. Will you send me a link to your store?

 

Cheers!


 

0 Likes
New Member
1 0 0

hi i need the same help please as im getting the same error and not sure how to fix it 

 

https://bright-technology.net

0 Likes
New Member
1 0 0

@BrianAtWorkI've looked everywhere on how to send you a private message and can't figure it out.  I too have this error and would like for you to take a look at my site to see if I've fixed it.  My site is www.maddiejoy.com

 

Thank you.

0 Likes
Shopify Partner
239 59 70

Hi @maddiejoy,

 

Welcome to the Shopify Community.

 

I've taken a look at your site and can confirm that you've fixed it. Good job!

 

Keep in mind that it may take a few days before the error disappears from Google Search Console.

 

 

For future readers:

 

Please send me a private message for support with this issue.

Brian | Shopify Partner | Ecommerce Consultant
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Click Accept as Solution  
 - Need further assistance? Visit www.BrianAtWork.com

0 Likes
New Member
2 0 0

Hey Brain Ive been having the same issue! 

0 Likes
New Member
2 0 0

Hey @BrianAtWork I've been having the same issue. Could you please help me out?

0 Likes
New Member
2 0 2

Brian - Your help  and time - is very much appreciated.

 

Made changes as per your suggestion and am just going to wait a couple of days!

 

(2nd one below)

 

<script type="application/ld+json">
{
"@context": "http://schema.org",
"@type": "Organization",
"name": {{ shop.name | json }},
{% if section.settings.logo %}
{% assign image_size = section.settings.logo.width | append:'x' %}
"logo": {{ section.settings.logo | img_url: image_size | prepend: "https:" | json }},
{% endif %}
"sameAs": [
{{ settings.social_twitter_link | json }},
{{ settings.social_facebook_link | json }},
{{ settings.social_pinterest_link | json }},
{{ settings.social_instagram_link | json }},
{{ settings.social_tumblr_link | json }},
{{ settings.social_snapchat_link | json }},
{{ settings.social_youtube_link | json }},
{{ settings.social_vimeo_link | json }}
],
"url": {{ shop.url | append: page.url | json }}
}
</script>

 

 

{% if template.name == 'index' %}
{% assign potential_action_target = shop.url | append: "{{ routes.search_url }}?q={search_term_string}" %}


<!--<script type="application/ld+json">
{
"@context": "http://schema.org",
"@type": "WebSite",
"name": {{ shop.name | json }},
"potentialAction": {
"@type": "SearchAction",
"target": {{ potential_action_target | json }},
"query-input": "required name=search_term_string"
},
"url": {{ shop.url | append: page.url | json }}
}
</script>-->

1 Like
New Member
2 0 2

Well! Patience was rewarded (after 2 days) :)

 

No more errors during GSC's "URL Inspection" :)

 

Brian's solution (editing-out redundant) script (per header.liquid) worked!

 

Thanks again!google crawl.JPG

 

 

1 Like
New Member
2 0 0

Hi,

I have the same issue and fixed it in the code. Google search console crawled my site again, it took some days, but found the same issue. Could you please help? My site is https://sunnysidecrystals.co.uk.

sunnyside-crystal.myshopify.com

 

Thank you!
Nia

0 Likes
Shopify Partner
239 59 70

Hi @Sunnyside,

 

It looks like you may have commented out the wrong code.

 

Comment out this code instead:

<script type="application/ld+json">
    {
      "@context": "http://schema.org",
      "@type": "WebSite",
      "name": "Sunnyside Crystals",
      "potentialAction": {
        "@type": "SearchAction",
        "target": "https:\/\/sunnysidecrystals.co.uk{{ routes.search_url }}?q={search_term_string}",
        "query-input": "required name=search_term_string"
      },
      "url": "https:\/\/sunnysidecrystals.co.uk"
    }
  </script>

 

Let me know how it goes!

 

For future readers:

 

Please send me a private message for support with this issue.

Brian | Shopify Partner | Ecommerce Consultant
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Click Accept as Solution  
 - Need further assistance? Visit www.BrianAtWork.com

0 Likes