I'm creating a company site in which we show some client testimonials in a modal.
The testimonials are stored in a folder in the root and shown on all pages.
So I ran the page through Googlebot and a problem appeared, since the hidden testimonials are rendered by Googlebot, even though the content is actually not visible until a jQuery function is executed.
So it got me thinking, that instead of having this content on all pages on load, would it perhaps be possible to run a macro which injects the code when an element is clicked?
My structure is
Root
-Frontpage
--Textpage1
--Textpage2
--Textpage3
-Testimonials
--Testimonial1
--Testimonial2
--Testimonial3
Hope you guys can help me out, cus I know this would be a better solution SEO-wise.
So I ran the page through Googlebot and a problem appeared, since the
hidden testimonials are rendered by Googlebot, even though the content
is actually not visible until a jQuery function is executed.
Testimonials are rendered by Googlebot?
Do you mean testimonials are rendered at page load but not visible for users until click?
The best way to fix it is to use UmbracoApiControllers for getting data from Umbraco and render it after click via js.
Do you have any experience in this?
Should testimonials be indexed by google somewhere on the site?
To answer your question first. Yes. Googlebot renders the testimonials, though they are hidden on load. I have an "overlay" which is mirrored and placed behind the actual content of the page.
When a button is clicked the whole page flips and the testimonials are shown instead of the main page content. I'm guessing it could have something to do with me using backface-visibility:hidden only and not display:none.
Sadly I have no experience with ApiControllers, but then again, there's only one way to get that :)
Yea the testimonials should be indexed, but preferably only on one page I created in which this "overlay" is placed as the main content, since having the same testimonials on every page isn't good for SEO.
Than of course you have to remove hidden content from each page - it will have few positive effects for your site:
pages will be smaller
rendering will be faster
Next you have to create functionality of getting data just after pressing click button. If you haven't experience community can help you just ask with code examples of your existing system
Yea. I'm aware of the benefits of limiting the amount of HTML on each page, which is also why I'd rather handle it by getting the content on click instead of on load.
Fetch content on click
Hi there
I'm creating a company site in which we show some client testimonials in a modal.
The testimonials are stored in a folder in the root and shown on all pages.
So I ran the page through Googlebot and a problem appeared, since the hidden testimonials are rendered by Googlebot, even though the content is actually not visible until a jQuery function is executed.
So it got me thinking, that instead of having this content on all pages on load, would it perhaps be possible to run a macro which injects the code when an element is clicked?
My structure is
Root
-Frontpage
--Textpage1
--Textpage2
--Textpage3
-Testimonials
--Testimonial1
--Testimonial2
--Testimonial3
Hope you guys can help me out, cus I know this would be a better solution SEO-wise.
Thank you in advance
Best
Henrik
Hi Henrik,
I'm not sure that understood you right -
Testimonials are rendered by Googlebot?
Do you mean testimonials are rendered at page load but not visible for users until click?
The best way to fix it is to use UmbracoApiControllers for getting data from Umbraco and render it after click via js.
Do you have any experience in this?
Should testimonials be indexed by google somewhere on the site?
Thanks,
Alex
Hi Alex
Thanks alot for taking the time to help me out.
To answer your question first. Yes. Googlebot renders the testimonials, though they are hidden on load. I have an "overlay" which is mirrored and placed behind the actual content of the page.
When a button is clicked the whole page flips and the testimonials are shown instead of the main page content. I'm guessing it could have something to do with me using backface-visibility:hidden only and not display:none.
Sadly I have no experience with ApiControllers, but then again, there's only one way to get that :)
Yea the testimonials should be indexed, but preferably only on one page I created in which this "overlay" is placed as the main content, since having the same testimonials on every page isn't good for SEO.
Best
Henrik
Hi Henrik,
Than of course you have to remove hidden content from each page - it will have few positive effects for your site:
pages will be smaller
rendering will be faster
Next you have to create functionality of getting data just after pressing click button. If you haven't experience community can help you just ask with code examples of your existing system
What js libraries are you using for ajax?
Thanks,
Alex
Thank you very much again Alex
Yea. I'm aware of the benefits of limiting the amount of HTML on each page, which is also why I'd rather handle it by getting the content on click instead of on load.
I'm using jQuery as my only JS lib.
Best
Henrik
So your suggestions, got me thinking the solution over.
First off, I created a new doctype in which I inserted the macro which lists all the testimonials.
After this I made a simple Ajax call, in which I fetched the content of that page.
So ended up being pretty simple compared to what I expected.
Thanks for your help, Alex
/Henrik
is working on a reply...