summaryrefslogtreecommitdiff
path: root/index.php
blob: b4a98e7d8e3bc6a755fe104168226e1bd3f9231d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
<?php
require_once __DIR__ . '/lib/bbcnext.php';

stream_context_set_default(['http' => [
	'user_agent' => 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/142.0.0.0 Safari/537.36',
]]);
?>
<!doctype html>
<html lang="en-GB">
	<head>
		<meta charset="UTF-8"/>
		<meta name="viewport" content="width=device-width,initial-scale=1"/>
		<title></title>
		<?php foreach (array_diff(scandir(__DIR__ . '/theme'), ['.', '..']) as $theme): ?>
			<link rel="<?=$theme=='Default'?'':'alternate '?>stylesheet"
				href="theme/<?=$theme?>/main.css"
				title="<?=$theme?>"/>
		<?php endforeach; ?>
	</head>

	<body>
		<header>
			<a href="."><frontend-name>RMS Frontend</frontend-name></a>
			<form id="search-form" action="search.php">
				<input name="q" placeholder="Query…"/>
				<input type="submit" value="Search"/>
			</form>
		</header>

		<main>
			<?php
			next_renderFromRms($_GET['path'] ?? RMS_SOUNDS_HOME);
			?>
		</main>
	</body>
</html>