Elgg
Version master
Main Page
Related Pages
Namespaces
Classes
Files
Examples
File List
File Members
views
default
resources
robots.txt.php
Go to the documentation of this file.
1
<?php
2
3
$site
=
elgg_get_site_entity
();
4
header(
'Content-type: text/plain; charset=utf-8'
);
5
6
$content
=
$site
->getMetadata(
'robots.txt'
);
7
$plugin_content
=
elgg_trigger_event_results
(
'robots.txt'
,
'site'
, [
'site'
=>
$site
],
''
);
8
if
(!empty(
$plugin_content
) && is_string(
$plugin_content
)) {
9
$content
.= PHP_EOL . PHP_EOL .
$plugin_content
;
10
}
11
12
echo
$content
;
elgg_trigger_event_results
elgg_trigger_event_results(string $event, string $type, array $params=[], $returnvalue=null)
Triggers an event where it is expected that the mixed return value could be manipulated by event call...
Definition:
events.php:117
$plugin_content
$plugin_content
Definition:
robots.txt.php:7
elgg_get_site_entity
elgg_get_site_entity()
Get the current site entity.
Definition:
entities.php:101
$site
$site
Definition:
robots.txt.php:3
$content
$content
Definition:
robots.txt.php:6
Generated on Sat Dec 21 2024 00:02:54 for Elgg by
1.8.11