improve uninstalled-protection

This commit is contained in:
Michiel@unhosted 2011-09-12 14:22:48 +02:00
parent f93be510a3
commit 5685965fdb
2 changed files with 6 additions and 2 deletions

View File

@ -2,7 +2,7 @@
if($_SERVER['SCRIPT_NAME'] == '/.well-known/host-meta.php') { if($_SERVER['SCRIPT_NAME'] == '/.well-known/host-meta.php') {
header("Access-Control-Allow-Origin: *"); header("Access-Control-Allow-Origin: *");
} else { } else {
header('Please visit /apps/user_webfinger/activate.php first'); header('Please-first: activate');
} }
header("Content-Type: application/xml+xrd"); header("Content-Type: application/xml+xrd");
echo "<"; echo "<";

View File

@ -1,5 +1,9 @@
<?php <?php
header("Access-Control-Allow-Origin: *"); if($_SERVER['SCRIPT_NAME'] == '/.well-known/host-meta.php') {
header("Access-Control-Allow-Origin: *");
} else {
header('Please-first: activate');
}
header("Content-Type: application/xml+xrd"); header("Content-Type: application/xml+xrd");
if($_GET['q']) { if($_GET['q']) {