2011-04-08 08:40:04 +00:00
|
|
|
<?php
|
2017-01-09 12:14:25 +00:00
|
|
|
|
2017-04-30 04:07:00 +00:00
|
|
|
use Friendica\App;
|
2018-10-31 14:35:50 +00:00
|
|
|
use Friendica\Core\Renderer;
|
2017-08-26 06:04:21 +00:00
|
|
|
use Friendica\Core\System;
|
2017-01-09 12:14:25 +00:00
|
|
|
|
2017-04-30 04:01:26 +00:00
|
|
|
function opensearch_content(App $a) {
|
2017-01-09 12:14:25 +00:00
|
|
|
|
2018-10-31 14:44:06 +00:00
|
|
|
$tpl = Renderer::getMarkupTemplate('opensearch.tpl');
|
2017-01-09 12:14:25 +00:00
|
|
|
|
2017-04-30 04:01:26 +00:00
|
|
|
header("Content-type: application/opensearchdescription+xml");
|
2017-01-09 12:14:25 +00:00
|
|
|
|
2018-10-31 14:35:50 +00:00
|
|
|
$o = Renderer::replaceMacros($tpl, [
|
2017-08-26 07:32:10 +00:00
|
|
|
'$baseurl' => System::baseUrl(),
|
2018-10-09 17:58:58 +00:00
|
|
|
'$nodename' => $a->getHostName(),
|
2018-01-15 13:05:12 +00:00
|
|
|
]);
|
2017-01-09 12:14:25 +00:00
|
|
|
|
2017-04-30 04:01:26 +00:00
|
|
|
echo $o;
|
|
|
|
|
2018-12-26 05:40:12 +00:00
|
|
|
exit();
|
2017-04-30 04:01:26 +00:00
|
|
|
}
|