スキップしてメイン コンテンツに移動

投稿

6月, 2015の投稿を表示しています

sitemap.xml の lastmod で日付のエラーがでた。ファイルのタイムスタンプにも注意!

sitemap.xmlに記載しているlastmodに「 日付の値が無効です。 日付または書式設定を修正してから、再送信してください。」というエラーが出ていた。 lastmodはファイルの更新日を標記するタグ フォーマットはW3C Datetime形式で記述する必要があるそうだ。省略してYYYY-MM-DDでも標記できるとある。 W3Cではこう書いてある。 Formats Different standards may need different levels of granularity in the date and time, so this profile defines six levels. Standards that reference this profile should specify one or more of these granularities. If a given standard allows more than one granularity, it should specify the meaning of the dates and times with reduced precision, for example, the result of comparing two dates with different precisions. The formats are as follows. Exactly the components shown here must be present, with exactly this punctuation. Note that the "T" appears literally in the string, to indicate the beginning of the time element, as specified in ISO 8601. Year: YYYY (eg 1997) Year and month: YYYY-MM (eg 1997-07) Complete date: YYYY-MM-DD (eg 1997-07-16) Complete date