aboutsummaryrefslogtreecommitdiffstats
path: root/mod/oep.php
diff options
context:
space:
mode:
authorredmatrix <git@macgirvin.com>2016-02-03 15:23:24 -0800
committerredmatrix <git@macgirvin.com>2016-02-03 15:23:24 -0800
commit28386d747115598ccd4851e049084219b2f99fef (patch)
tree8fc15cccf8cadebfc78c8653478de95add18dc5c /mod/oep.php
parenta7ed50ecd4b4defbc1d5fdf0bb4fd7d65d08a0fd (diff)
downloadvolse-hubzilla-28386d747115598ccd4851e049084219b2f99fef.tar.gz
volse-hubzilla-28386d747115598ccd4851e049084219b2f99fef.tar.bz2
volse-hubzilla-28386d747115598ccd4851e049084219b2f99fef.zip
admin security page for configuring white and black lists and other security options.
Diffstat (limited to 'mod/oep.php')
-rw-r--r--mod/oep.php13
1 files changed, 11 insertions, 2 deletions
diff --git a/mod/oep.php b/mod/oep.php
index 3855a1b4a..42535c069 100644
--- a/mod/oep.php
+++ b/mod/oep.php
@@ -8,6 +8,7 @@ function oep_init(&$a) {
logger('oep: ' . print_r($_REQUEST,true), LOGGER_DEBUG, LOG_INFO);
+ $html = ((argc() > 1 && argv(1) === 'html') ? true : false);
if($_REQUEST['url']) {
$_REQUEST['url'] = strip_zids($_REQUEST['url']);
$url = $_REQUEST['url'];
@@ -38,8 +39,16 @@ function oep_init(&$a) {
$arr = oep_profile_reply($_REQUEST);
if($arr) {
- header('Content-Type: application/json+oembed');
- echo json_encode($arr);
+ if($html) {
+ if($arr['type'] === 'rich') {
+ header('Content-Type: text/html');
+ echo $arr['html'];
+ }
+ }
+ else {
+ header('Content-Type: application/json+oembed');
+ echo json_encode($arr);
+ }
killme();
}