Comments (9)
Can you paste in your sitemap config? And what version of sitemap generator are you running?
I can't think of any reason why your default_host would be ignored...
from sitemap_generator.
The only way I can think of is if you are passing in full URLs to the add() method e.g.
add root_url
When it should be: add root_path.
from sitemap_generator.
I am not adding anything in the "create"
from sitemap_generator.
Sorry, I have the following entry in the "create" node.
SitemapGenerator::Sitemap.default_host = "http://cheapr.me"
SitemapGenerator::Sitemap.create do
add "/view"
end
from sitemap_generator.
Your config looks good. When I run it in a test Rails app it generates URLs with the correct hostname.
The sitemap you link to doesn't look like it matches the one you are generating. I would suggest deleting the sitemaps in public/ and then running your sitemap gen again.
Finally to be absolutely sure that you are seeing the correct sitemaps, you can call add like so:
add '/view', :host => 'http://anotherhost.com'
This forces the host for that URL. If you don't see anotherhost.com then you're not seeing the right sitemaps.
from sitemap_generator.
I removed the earlier sitemap files, modified the "add" line with
add '/view', :host =>"http://cheapr.me"
and regenerated the sitemaps. Now, there are two files generated (no sitemap.xml is generated)
sitemap1.xml.gz
sitemap_index.xml.gz
When I try to check http://cheapr.me/sitemap.xml I see 404
from sitemap_generator.
The sitemaps are compressed using GZip. You can uncompress them using WinZip, 7Zip or other tools. Then you can see the xml.
Note that the URL for your sitemap is: http://cheapr.me/sitemap_index.xml.gz
from sitemap_generator.
Thanks, I tried to expand the sitemap_index.xml.gz file - this file
contains - sitemap_index.xml
sitemap_index.xml file looks like :
http://cheapr.me/sitemap1.xml.gz
2011-11-24T04:12:27+00:00
Is the "loc" element pointing correctly ?
Thanks,
On Fri, Nov 25, 2011 at 1:05 AM, Karl Varga <
[email protected]
wrote:
The sitemaps are compressed using GZip. You can uncompress them using
WinZip, 7Zip or other tools. Then you can see the xml.Note that the URL for your sitemap is:
http://cheapr.me/sitemap_index.xml.gz
Reply to this email directly or view it on GitHub:
#51 (comment)
from sitemap_generator.
Yes it's correct. http://cheapr.me/sitemap1.xml.gz is the sitemap file with your '/view' URL in it. You can remove the :host option from your call to add() now because everything is working correctly.
from sitemap_generator.
Related Issues (20)
- Feature Request: Remove unwanted options HOT 6
- Is it possible to override the default link options? HOT 3
- How to remove default priority, lastmod and changefreq from all urls HOT 1
- GoogleStorageAdapter - Can't create sitemap on buckets with uniform bucket-level access enabled HOT 3
- Allow disable acl for S3 bucket HOT 1
- Rails on Heroku with S3 sitemap hosting - google didn't like it HOT 2
- 【Worked】Ping failed for Bing: #<OpenURI::HTTPError: 410 Gone> HOT 4
- Is it possible to add additional metadata fields to the xml HOT 5
- Feature request : Make `default_host` optional / Allow full URL instead of path HOT 2
- Entity escaping in XML output
- google search console couldn't fetch sitemap but index is ok HOT 7
- Google search correct ping url HOT 2
- Readme install instructions fail HOT 1
- [BUG] Mobile sitemap link in Readme.md is giving 404
- TimeZone is ignored
- sitemap.xml.gz file not found on server
- Testing with frozen time does not work
- should sitemap show up automatically in google search console? HOT 2
- Should we drop default `lastmod` of `Time.now` as Google says "it needs to consistently match reality"? HOT 2
- Remove deprecated Google ping HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from sitemap_generator.