Sha256: 91cbbc17c25c766198ebfdaa2424ea241ca5373471894a173cda42c01444c414

Contents?: true

Size: 433 Bytes

Versions: 4

Compression:

Stored size: 433 Bytes

Contents

xml.instruct!
xml.urlset "xmlns" => "http://www.sitemaps.org/schemas/sitemap/0.9" do
  @urls.each do |url|
    xml.url do
      xml.loc url.loc
      
      if url.last_mod
        xml.lastmod url.last_mod.to_datetime.strftime("%Y-%m-%dT%H:%M:%S%:z")
      end
      
      if url.change_freq
        xml.changefreq url.change_freq
      end
      
      if url.priority
        xml.priority url.priority
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
dynamic_sitemaps-1.0.8 app/views/sitemaps/sitemap.builder
dynamic_sitemaps-1.0.7 app/views/sitemaps/sitemap.builder
dynamic_sitemaps-1.0.6 app/views/sitemaps/sitemap.builder
dynamic_sitemaps-1.0.5 app/views/sitemaps/sitemap.builder