Movatterモバイル変換


[0]ホーム

URL:


MediaWiki master
opensearch_desc.php
Go to the documentation of this file.
1<?php
15// This endpoint is supposed to be independent of request cookies and other
16// details of the session. Enforce this constraint with respect to session use.
17define('MW_NO_SESSION', 1 );
18
19define('MW_ENTRY_POINT','opensearch_desc' );
20
21require_once __DIR__ .'/includes/WebStart.php';
22
23$url =wfScript('rest' ) .'/v1/search';
24$ctype =$wgRequest->getRawVal('ctype' );
25
26if ($ctype !==null ) {
27$url =wfAppendQuery($url, ['ctype' =>$ctype ] );
28}
29
30$wgRequest->response()->header('Location: ' .$url,true, 308 );
31$wgRequest->response()->header('Cache-control: max-age=600' );
wfAppendQuery
wfAppendQuery( $url, $query)
Append a query string to an existing URL, which may or may not already have query string parameters a...
DefinitionGlobalFunctions.php:428
wfScript
wfScript( $script='index')
Get the URL path to a MediaWiki entry point.
DefinitionGlobalFunctions.php:1779
$wgRequest
global $wgRequest
DefinitionSetup.php:434
$ctype
$ctype
Definitionopensearch_desc.php:24
$url
$url
Definitionopensearch_desc.php:23

[8]ページ先頭

©2009-2025 Movatter.jp