turn url requests where argv[0] is something.xyz into module='something' and $_REQUEST['module_format'] = 'xyz'; But leave modules beginning with . (like .well_known) alone (convert the initial . to _ and then strip it). This really only affects Siteinfo_json at this time.
This commit is contained in:
@@ -5,14 +5,13 @@ namespace Zotlabs\Module;
|
||||
class Siteinfo extends \Zotlabs\Web\Controller {
|
||||
|
||||
function init() {
|
||||
if (argv(1) === 'json') {
|
||||
logger(print_r($_REQUEST,true));
|
||||
if (argv(1) === 'json' || $_REQUEST['module_format'] === 'json') {
|
||||
$data = get_site_info();
|
||||
json_return_and_die($data);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
function get() {
|
||||
|
||||
$siteinfo = replace_macros(get_markup_template('siteinfo.tpl'),
|
||||
|
||||
Reference in New Issue
Block a user