if($this->cmd === '.well-known/host-meta')
require_once('include/hostxrd.php');
+
$this->pager['page'] = ((x($_GET,'page')) ? $_GET['page'] : 1);
$this->pager['itemspage'] = 50;
$this->pager['start'] = ($this->pager['page'] * $this->pager['itemspage']) - $this->pager['itemspage'];
$_SESSION['cid'] = $a->cid;
}
+ header('X-Account-Management-Status: active; name="' . $a->user['username'] . '"; id="' . $a->user['nickname'] .'"');
}
}
else {
$a->cid = $r[0]['id'];
$_SESSION['cid'] = $a->cid;
}
+
+ header('X-Account-Management-Status: active; name="' . $a->user['username'] . '"; id="' . $a->user['nickname'] .'"');
if(($a->module !== 'home') && isset($_SESSION['return_url']))
goaway($a->get_baseurl() . '/' . $_SESSION['return_url']);
}
session_start();
-if((x($_SESSION,'authenticated')) || (x($_POST,'auth-params')))
+if((x($_SESSION,'authenticated')) || (x($_POST,'auth-params')) || ($a->module === 'login'))
require("auth.php");
+if(! x($_SESSION,'authenticated'))
+ header('X-Account-Management-Status: none');
+
if(! x($_SESSION,'sysmsg'))
$_SESSION['sysmsg'] = '';
--- /dev/null
+<?php
+
+function amcd_content(&$a) {
+header("Content-type: text/json");
+echo <<< EOT
+{
+ "methods": {
+ "username-password-form": {
+ "connect": {
+ "method":"POST",
+ "path":"/login",
+ "params": {
+ "username":"login-name",
+ "password":"password"
+ }
+ },
+ "disconnect": {
+ "method":"GET",
+ "path":"/logout"
+ }
+ }
+ }
+}
+EOT;
+killme();
+}
\ No newline at end of file
$a->page['htmlhead'] .= '<link rel="alternate" type="application/atom+xml" href="' . $a->get_baseurl() . '/dfrn_poll/' . $which .'" />' . "\r\n" ;
$uri = urlencode('acct:' . $a->profile['nickname'] . '@' . $a->get_hostname() . (($a->path) ? '/' . $a->path : ''));
$a->page['htmlhead'] .= '<link rel="lrdd" type="application/xrd+xml" href="' . $a->get_baseurl() . '/xrd/?uri=' . $uri . '" />' . "\r\n";
- header('Link: <' . $a->get_baseurl() . '/xrd/?uri=' . $uri . '>; rel="lrdd"; type="application/xrd+xml"');
+ header('Link: <' . $a->get_baseurl() . '/xrd/?uri=' . $uri . '>; rel="lrdd"; type="application/xrd+xml"', false);
$dfrn_pages = array('request', 'confirm', 'notify', 'poll');
--- /dev/null
+<?php
+
+function session_content(&$a) {
+
+}
<hm:Host>$domain</hm:Host>
- <Link rel='lrdd'
- template='http://$domain/xrd/?uri={uri}'>
- <Title>Resource Descriptor</Title>
- </Link>
+ <Link rel='lrdd' template='http://$domain/xrd/?uri={uri}' />
+ <Link rel='acct-mgmt' href='http://$domain/amcd' />
+ <Link rel='http://services.mozilla.com/amcd/0.1' href='http://$domain/amcd' />
+
</XRD>