sitemap.php 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. <?php
  2. use GuzzleHttp\RequestOptions;
  3. use Spatie\Sitemap\Crawler\Profile;
  4. return [
  5. /*
  6. * These options will be passed to GuzzleHttp\Client when it is created.
  7. * For in-depth information on all options see the Guzzle docs:
  8. *
  9. * http://docs.guzzlephp.org/en/stable/request-options.html
  10. */
  11. 'guzzle_options' => [
  12. /*
  13. * Whether or not cookies are used in a request.
  14. */
  15. RequestOptions::COOKIES => true,
  16. /*
  17. * The number of seconds to wait while trying to connect to a server.
  18. * Use 0 to wait indefinitely.
  19. */
  20. RequestOptions::CONNECT_TIMEOUT => 10,
  21. /*
  22. * The timeout of the request in seconds. Use 0 to wait indefinitely.
  23. */
  24. RequestOptions::TIMEOUT => 10,
  25. /*
  26. * Describes the redirect behavior of a request.
  27. */
  28. RequestOptions::ALLOW_REDIRECTS => false,
  29. ],
  30. /*
  31. * The sitemap generator can execute JavaScript on each page so it will
  32. * discover links that are generated by your JS scripts. This feature
  33. * is powered by headless Chrome.
  34. */
  35. 'execute_javascript' => false,
  36. /*
  37. * The package will make an educated guess as to where Google Chrome is installed.
  38. * You can also manually pass its location here.
  39. */
  40. 'chrome_binary_path' => null,
  41. /*
  42. * The sitemap generator uses a CrawlProfile implementation to determine
  43. * which urls should be crawled for the sitemap.
  44. */
  45. 'crawl_profile' => Profile::class,
  46. ];