Roland Häder
4dce3d8224
--------------------- function bla (App &$a) { $a->bla = 'stuff'; } --------------------- Signed-off-by: Roland Häder <roland@mxchange.org>
49 lines
910 B
PHP
49 lines
910 B
PHP
<?php
|
|
|
|
function amcd_content(App &$a) {
|
|
//header("Content-type: text/json");
|
|
echo <<< EOT
|
|
{
|
|
"version":1,
|
|
"sessionstatus":{
|
|
"method":"GET",
|
|
"path":"/session"
|
|
},
|
|
"auth-methods": {
|
|
"username-password-form": {
|
|
"connect": {
|
|
"method":"POST",
|
|
"path":"/login",
|
|
"params": {
|
|
"username":"login-name",
|
|
"password":"password"
|
|
},
|
|
"onsuccess": { "action":"reload" }
|
|
},
|
|
"disconnect": {
|
|
"method":"GET",
|
|
"path":"\/logout"
|
|
}
|
|
}
|
|
}
|
|
"methods": {
|
|
"username-password-form": {
|
|
"connect": {
|
|
"method":"POST",
|
|
"path":"\/login",
|
|
"params": {
|
|
"username":"login-name",
|
|
"password":"password"
|
|
},
|
|
"onsuccess": { "action":"reload" }
|
|
},
|
|
"disconnect": {
|
|
"method":"GET",
|
|
"path":"\/logout"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
EOT;
|
|
killme();
|
|
} |