diff options
| author | czaks <marcin@6irc.net> | 2013-07-17 22:17:37 -0400 |
|---|---|---|
| committer | czaks <marcin@6irc.net> | 2013-07-17 22:17:37 -0400 |
| commit | 8c72c8a43232f137256fa170c889ba330ebba7af (patch) | |
| tree | 3e91b94489627a774971dbb09f84bfaaa1465a75 /templates/themes/sitemap/info.php | |
| parent | dd4aea54312b288dbfe885be87148f8df116047a (diff) | |
| parent | 7e95e80c25e2f35b8a49ebd73f95671b0233be6f (diff) | |
Merge branch 'master' of https://github.com/savetheinternet/Tinyboard
Diffstat (limited to 'templates/themes/sitemap/info.php')
| -rw-r--r-- | templates/themes/sitemap/info.php | 53 |
1 files changed, 53 insertions, 0 deletions
diff --git a/templates/themes/sitemap/info.php b/templates/themes/sitemap/info.php new file mode 100644 index 00000000..e16448ee --- /dev/null +++ b/templates/themes/sitemap/info.php @@ -0,0 +1,53 @@ +<?php + $theme = Array(); + + // Theme name + $theme['name'] = 'Sitemap Generator'; + // Description (you can use Tinyboard markup here) + $theme['description'] = 'Generates an XML sitemap to help search engines find all threads and pages.'; + $theme['version'] = 'v1.0'; + + // Theme configuration + $theme['config'] = Array(); + + $theme['config'][] = Array( + 'title' => 'Sitemap Path', + 'name' => 'path', + 'type' => 'text', + 'default' => 'sitemap.xml', + 'size' => '20' + ); + + $theme['config'][] = Array( + 'title' => 'URL prefix', + 'name' => 'url', + 'type' => 'text', + 'comment' => '(with trailing slash)', + 'default' => 'http://' . $_SERVER['HTTP_HOST'] . $config['root'], + 'size' => '20' + ); + + $theme['config'][] = Array( + 'title' => 'Thread change frequency', + 'name' => 'changefreq', + 'type' => 'text', + 'comment' => '(eg. "hourly", "daily", etc.)', + 'default' => 'hourly', + 'size' => '20' + ); + + $__boards = listBoards(); + $__default_boards = Array(); + foreach ($__boards as $__board) + $__default_boards[] = $__board['uri']; + + $theme['config'][] = Array( + 'title' => 'Boards', + 'name' => 'boards', + 'type' => 'text', + 'comment' => '(boards to include; space seperated)', + 'size' => 24, + 'default' => implode(' ', $__default_boards) + ); + + $theme['build_function'] = 'sitemap_build'; |
