镜像站点 · 本页由第三方 GitHub 只读镜像提供,非 GitHub 官方站点,不接受任何登录或凭据输入。前往 github.com
Skip to content

About

A library for generating sitemap content

Resources

Code of conduct

Contributing

Security policy

Accessibility

Stars

0 stars

Watchers

1 watching

Forks

Latest commit

 

History

44 Commits

Folders and files

Repository files navigation

8fold Sitemap for PHP

Generates valid XML document and sitemap elements based on the Sitemap protocol.

Schema Version
0.9 Latest

Installation

composer require 8fold/php-sitemap

Usage

You have received the required metadata in an array; could be the results of a database query.

use Eigthfold\Sitemap\Sitemap;

$sitemap = Sitemap::create('http://yourdomain.com');

$items = // your array of items

foreach ($items as $item) {
  $sitemap = $sitemap->addUrl(
    $item->path
  );
}

(string) $sitemap;

Details

Designed to fit within a loop.

Other

{links or descriptions or license, versioning, and governance}

About

A library for generating sitemap content

Resources

Code of conduct

Contributing

Security policy

Accessibility

Stars

0 stars

Watchers

1 watching

Forks

Releases

Sponsor this project

Packages

Used by

Contributors

Languages