sitemap problem

In this board you can talk about general questions about phpMyFAQ

Moderator: Thorsten

pmfuser
Posts: 106
Joined: Tue Apr 01, 2014 7:00 am

sitemap problem

Post by pmfuser »

Recently I saw Google dropping out my FAQ pages from its index. I just looked into the sitemap, and saw this:

http://www.mysite.com/faq/http://www.mysite.com/faq/ ... and then it continues with the url, whatever is the page.

Now I'm not sure if I should delete the full path from configuration, or if this is coming from somewhere else. I do have friendly URLs enabled.

It's interesting that the first page (FAQ home page) in the sitemap is correct, just http://www.mysite.com/faq/

Thanks
Thorsten
Posts: 15560
Joined: Tue Sep 25, 2001 11:14 am
Location: #phpmyfaq
Contact:

Re: sitemap problem

Post by Thorsten »

Hi,

you're right, I found the issue: https://github.com/thorsten/phpMyFAQ/co ... 5f70b805d7

bye
Thorsten
phpMyFAQ Maintainer and Lead Developer
amazon.de Wishlist
pmfuser
Posts: 106
Joined: Tue Apr 01, 2014 7:00 am

Re: sitemap problem

Post by pmfuser »

Thanks.

Is this for 2.9.3 or for later?
Thorsten
Posts: 15560
Joined: Tue Sep 25, 2001 11:14 am
Location: #phpmyfaq
Contact:

Re: sitemap problem

Post by Thorsten »

Hi,

will be included in 2.9.3, planned for the end of this month.

bye
Thorsten
phpMyFAQ Maintainer and Lead Developer
amazon.de Wishlist
pmfuser
Posts: 106
Joined: Tue Apr 01, 2014 7:00 am

Re: sitemap problem

Post by pmfuser »

Additional question:

Google has started reporting duplicated content issues because it has already picked "doubled" URLs. I'm trying to fix it by implementing 301 redirects, but having a hard time.
It looks like something from the existing FAQ configuration (.htaccess I guess) is preventing it. For example:

http://www.example.com/faq/some-faq.html is a correct URL.

http://www.example.com/faq/http://www.e ... e-faq.html is the one that was published in the sitemap, and which Google has picked.

The wrong one returns content while it should be 404. Why is that, please? My guess is that it's something from .htaccess but I cannot figure it out.

If I try to do this with any other part of the website, I get 404 - as it should be.

Thanks

P.S.
Let me add, I just tested it further by entering an additional string to an existing URL, and the FAQ has returned the page instead of 404. There's something fundamentally wrong in the URL rewrites here.
Thorsten
Posts: 15560
Joined: Tue Sep 25, 2001 11:14 am
Location: #phpmyfaq
Contact:

Re: sitemap problem

Post by Thorsten »

Hi,

what's returned for the wrong URLs?

bye
Thorsten
phpMyFAQ Maintainer and Lead Developer
amazon.de Wishlist
pmfuser
Posts: 106
Joined: Tue Apr 01, 2014 7:00 am

Re: sitemap problem

Post by pmfuser »

Well, I just realized that the canonical tag is wrong as well, so the URL system is simply broken. The canonical itself does the same what was in the sitemap, it puts the FAQ root URL twice. That's really wrong. I did disable the sitemap manually, and put my own I created manually, but now when all pages are returning different canonical URLs, not sure what are my options.

Thanks
Thorsten
Posts: 15560
Joined: Tue Sep 25, 2001 11:14 am
Location: #phpmyfaq
Contact:

Re: sitemap problem

Post by Thorsten »

Hi,

if I check this demo at http://denholm.demo.phpmyfaq.de/ I don't see wrong canonical URLs.

bye
Thorsten
phpMyFAQ Maintainer and Lead Developer
amazon.de Wishlist
pmfuser
Posts: 106
Joined: Tue Apr 01, 2014 7:00 am

Re: sitemap problem

Post by pmfuser »

Yeah, but that one does not have friendly URLs turned on.
Thorsten
Posts: 15560
Joined: Tue Sep 25, 2001 11:14 am
Location: #phpmyfaq
Contact:

Re: sitemap problem

Post by Thorsten »

Hi,

I have on my local machine:

Code: Select all

<link rel="canonical" href="http://macbookpro.local/phpMyFAQ-2.9/phpmyfaq/addcontent.html">
bye
Thorsten
phpMyFAQ Maintainer and Lead Developer
amazon.de Wishlist
pmfuser
Posts: 106
Joined: Tue Apr 01, 2014 7:00 am

Re: sitemap problem

Post by pmfuser »

Well, however the {currentPageUrl} is created, here it comes back with the double root of FAQ.

But please note, this all started by sitemap listing those URLs. If I visit the FAQ normally, URLs are fine. But if I enter additional string, the canonical changes. That's why I stated that there was something fundamentally wrong with how the rewrite works.

Here is live example I picked from Who uses phpMyFAQ:

This is a correct URL: https://www.intogres.com/faqs/content/4 ... panel.html
Here is altered URL (I added "stringxyz" into URL): https://www.intogres.com/faqs/stringxyz ... panel.html

Check the source code and see what is for canonical tag for each. That is wrong.

In short, if the URL for whatever reason gets "spelled" wrongly, and gets picked up by search engines or people link to the page by using that "wrong" URL, the site is in trouble until it fixes the URL in question (by 301 redirect) as the "wrong" URL will be requested forever.

Thanks
Thorsten
Posts: 15560
Joined: Tue Sep 25, 2001 11:14 am
Location: #phpmyfaq
Contact:

Re: sitemap problem

Post by Thorsten »

Hi,

ah, you're talking about a 2.8 installation. I fixed that in 2.9 only. 2.8 only gets security fixes.

bye
Thorsten
phpMyFAQ Maintainer and Lead Developer
amazon.de Wishlist
pmfuser
Posts: 106
Joined: Tue Apr 01, 2014 7:00 am

Re: sitemap problem

Post by pmfuser »

I have 2.9.
Thorsten
Posts: 15560
Joined: Tue Sep 25, 2001 11:14 am
Location: #phpmyfaq
Contact:

Re: sitemap problem

Post by Thorsten »

Hi,

will try to reproduce it.

bye
Thorsten
phpMyFAQ Maintainer and Lead Developer
amazon.de Wishlist
pmfuser
Posts: 106
Joined: Tue Apr 01, 2014 7:00 am

Re: sitemap problem

Post by pmfuser »

Here is an example running 2.9.2:

http://video-insight.com/kb/stringxyz/c ... nager.html

The original URL is without "stringxyz"

Thanks
Post Reply