aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorfriendica <info@friendica.com>2014-08-27 22:56:24 -0700
committerfriendica <info@friendica.com>2014-08-27 22:56:24 -0700
commita4f734e37c2092b91d3915b5f4bb90eba6a4b605 (patch)
treeab1353b6da9609dcacf3fe1c50615997187e1a86
parent2d210db1b85e5893afe285fc7b32f9987f1ae565 (diff)
downloadvolse-hubzilla-a4f734e37c2092b91d3915b5f4bb90eba6a4b605.tar.gz
volse-hubzilla-a4f734e37c2092b91d3915b5f4bb90eba6a4b605.tar.bz2
volse-hubzilla-a4f734e37c2092b91d3915b5f4bb90eba6a4b605.zip
begin embeddable/shareable design elements (blocks, webpages, layouts, menus, etc.)
-rw-r--r--include/apps.php34
-rw-r--r--mod/admin.php2
2 files changed, 34 insertions, 2 deletions
diff --git a/include/apps.php b/include/apps.php
index bd50b953a..7cfa07868 100644
--- a/include/apps.php
+++ b/include/apps.php
@@ -467,4 +467,36 @@ function app_encode($app,$embed = false) {
function papp_encode($papp) {
return chunk_split(base64_encode(json_encode($papp)),72,"\n");
-} \ No newline at end of file
+}
+
+
+/**
+ * install a shared design element (layout, webpage, block, menu, whatever)
+ *
+ */
+
+function element_install($channel,$s) {
+
+ $ret = array('success' => false);
+
+ $s = str_replace(array('[element]','[/element]'),array('',''),$s);
+ $s = base64url_decode($s);
+ if(! $s)
+ return $ret;
+ $x = json_decode($s,true);
+ if(! $x)
+ return $ret;
+
+ $d = array();
+
+
+
+
+
+
+
+
+ $result = item_store($d);
+
+}
+
diff --git a/mod/admin.php b/mod/admin.php
index e54163c62..82d199a9b 100644
--- a/mod/admin.php
+++ b/mod/admin.php
@@ -1351,7 +1351,7 @@ function admin_page_profs(&$a) {
return replace_macros(get_markup_template('profdef_edit.tpl'),array(
'$id' => intval($r[0]['id']),
- '$header' => t('New Profile Field'),
+ '$header' => t('Edit Profile Field'),
'$field_name' => array('field_name',t('Field nickname'),$r[0]['field_name'],t('System name of field')),
'$field_type' => array('field_type',t('Input type'),$r[0]['field_type'],''),
'$field_desc' => array('field_desc',t('Field Name'),$r[0]['field_desc'],t('Label on profile pages')),