]> git.mxchange.org Git - friendica.git/blob - mod/robots_txt.php
Merge pull request #3398 from tobiasd/20170427-blockdocde
[friendica.git] / mod / robots_txt.php
1 <?php
2 /**
3  * @file mod/robots_text.php
4  * @brief Module which returns the default robots.txt
5  * @version 0.1.2
6  */
7
8
9 /**
10  * @brief Return default robots.txt when init
11  * @param App $a
12  * @return void
13  */
14 function robots_txt_init(App $a)
15 {
16
17         $allDisalloweds = array(
18                 '/settings/',
19                 '/admin/',
20                 '/message/',
21         );
22
23         header('Content-Type: text/plain');
24         echo 'User-agent: *'.PHP_EOL;
25         foreach ($allDisalloweds as $disallowed) {
26                 echo 'Disallow: '.$disallowed.PHP_EOL;
27         }
28         killme();
29 }