samdark/sitemap

how i run it

vahidalvandi opened this issue · 2 comments

hi dear

i download sitemap and update with composer update command line

i am amator and need help you for run this script

for example i create index.php and set this code
////////////////

addItem(new SitemapItem( 'http://rmcreative.ru/', // URL time(), // last modifcation timestamp Item::DAILY, // update frequency 0.7 // priority )); // add more pages foreach ($pages as $page){ $sitemap->addItem(new SitemapItem( 'http://rmcreative.ru/' . $page->url, $page->updatedOn, Item::MONTHLY )); } // generate sitemap.xml $sitemap->writeToFile('sitemap.xml'); // or get it as string $sitemapString = $sitemap->render(); //////////////////////////////////////////// after run have more error Fatal error: Class 'samdark\sitemap' not found in C:\xampp\htdocs\samdark\index.php on line 9 how i run it????

i now correct it

addItem(new Item( 'http://rmcreative.ru/' . 'sdfsf.htm', '201', Item::MONTHLY )); ``` // generate sitemap.xml $sitemap->writeToFile('sitemap.xml');