diff --git a/images/icons/10/lock.png b/images/icons/10/lock.png index ad8079c231..2ddf98d081 100644 Binary files a/images/icons/10/lock.png and b/images/icons/10/lock.png differ diff --git a/images/icons/10/unlock.png b/images/icons/10/unlock.png new file mode 100644 index 0000000000..d18088416b Binary files /dev/null and b/images/icons/10/unlock.png differ diff --git a/images/icons/16/lock.png b/images/icons/16/lock.png index f4432bbe4e..189bfd29e1 100644 Binary files a/images/icons/16/lock.png and b/images/icons/16/lock.png differ diff --git a/images/icons/16/unlock.png b/images/icons/16/unlock.png new file mode 100644 index 0000000000..c56495d020 Binary files /dev/null and b/images/icons/16/unlock.png differ diff --git a/images/icons/22/lock.png b/images/icons/22/lock.png index 92c8c49059..13b755810a 100644 Binary files a/images/icons/22/lock.png and b/images/icons/22/lock.png differ diff --git a/images/icons/22/unlock.png b/images/icons/22/unlock.png new file mode 100644 index 0000000000..9be196f554 Binary files /dev/null and b/images/icons/22/unlock.png differ diff --git a/images/icons/48/lock.png b/images/icons/48/lock.png index 9943bb17d2..b9db282ac9 100644 Binary files a/images/icons/48/lock.png and b/images/icons/48/lock.png differ diff --git a/images/icons/48/unlock.png b/images/icons/48/unlock.png new file mode 100644 index 0000000000..9bf72a4c64 Binary files /dev/null and b/images/icons/48/unlock.png differ diff --git a/images/icons/Makefile b/images/icons/Makefile index ec57b943e9..00c4fa4c20 100644 --- a/images/icons/Makefile +++ b/images/icons/Makefile @@ -2,7 +2,7 @@ IMAGES=add.png edit.png gear.png info.png menu.png \ notify_off.png star.png delete.png feed.png group.png \ lock.png notice.png notify_on.png user.png link.png \ - play.png plugin.png + play.png plugin.png unlock.png DESTS=10/ 16/ 22/ 48/ \ $(addprefix 10/, $(IMAGES)) \ diff --git a/images/icons/lock.png b/images/icons/lock.png index 7e58ead2eb..91a8f3ef2f 100644 Binary files a/images/icons/lock.png and b/images/icons/lock.png differ diff --git a/images/icons/lock.png.tmp b/images/icons/lock.png.tmp new file mode 100644 index 0000000000..7e58ead2eb Binary files /dev/null and b/images/icons/lock.png.tmp differ diff --git a/images/icons/unlock.png b/images/icons/unlock.png new file mode 100644 index 0000000000..4bf7e7eae1 Binary files /dev/null and b/images/icons/unlock.png differ diff --git a/include/config.php b/include/config.php index f565ab1178..92694f5193 100644 --- a/include/config.php +++ b/include/config.php @@ -145,8 +145,9 @@ function get_pconfig($uid,$family, $key, $instore = false) { ); if(count($ret)) { - $a->config[$uid][$family][$key] = $ret[0]['v']; - return $ret[0]['v']; + $val = (preg_match("|^a:[0-9]+:{.*}$|", $ret[0]['v'])?unserialize( $ret[0]['v']):$ret[0]['v']); + $a->config[$uid][$family][$key] = $val; + return $val; } else { $a->config[$uid][$family][$key] = '!!'; @@ -177,20 +178,23 @@ function set_pconfig($uid,$family,$key,$value) { global $a; + // manage array value + $dbvalue = (is_array($value)?serialize($value):$value); + if(get_pconfig($uid,$family,$key,true) === false) { $a->config[$uid][$family][$key] = $value; $ret = q("INSERT INTO `pconfig` ( `uid`, `cat`, `k`, `v` ) VALUES ( %d, '%s', '%s', '%s' ) ", intval($uid), dbesc($family), dbesc($key), - dbesc($value) + dbesc($dbvalue) ); if($ret) return $value; return $ret; } $ret = q("UPDATE `pconfig` SET `v` = '%s' WHERE `uid` = %d AND `cat` = '%s' AND `k` = '%s' LIMIT 1", - dbesc($value), + dbesc($dbvalue), intval($uid), dbesc($family), dbesc($key) diff --git a/include/conversation.php b/include/conversation.php index fae57c5655..f4dd01ddeb 100644 --- a/include/conversation.php +++ b/include/conversation.php @@ -856,13 +856,21 @@ function status_editor($a,$x, $notes_cid = 0) { '$action' => 'item', '$share' => (($x['button']) ? $x['button'] : t('Share')), '$upload' => t('Upload photo'), + '$shortupload' => t('upload photo'), '$attach' => t('Attach file'), + '$shortattach' => t('attach file'), '$weblink' => t('Insert web link'), + '$shortweblink' => t('web link'), '$video' => t('Insert video link'), + '$shortvideo' => t('video link'), '$audio' => t('Insert audio link'), + '$shortaudio' => t('audio link'), '$setloc' => t('Set your location'), + '$shortsetloc' => t('set location'), '$noloc' => t('Clear browser location'), - '$title' => t('Set title'), + '$shortnoloc' => t('clear location'), + '$title' => "", + '$placeholdertitle' => t('Set title'), '$wait' => t('Please wait'), '$permset' => t('Permission settings'), '$ptyp' => (($notes_cid) ? 'note' : 'wall'), diff --git a/mod/photos.php b/mod/photos.php index bf3299de07..12225b5c5a 100644 --- a/mod/photos.php +++ b/mod/photos.php @@ -1367,30 +1367,36 @@ function photos_content(&$a) { intval($a->pager['itemspage']) ); - $o .= '

' . t('Recent Photos') . '

'; - if($can_post) { - $o .= ''; - } - $tpl = get_markup_template('photo_top.tpl'); + $photos = array(); if(count($r)) { foreach($r as $rr) { - $o .= replace_macros($tpl,array( - '$id' => $rr['id'], - '$photolink' => $a->get_baseurl() . '/photos/' . $a->data['user']['nickname'] . '/image/' . $rr['resource-id'], - '$phototitle' => t('View Photo'), - '$imgsrc' => $a->get_baseurl() . '/photo/' . $rr['resource-id'] . '-' . ((($rr['scale']) == 6) ? 4 : $rr['scale']) . '.jpg', - '$albumlink' => $a->get_baseurl() . '/photos/' . $a->data['user']['nickname'] . '/album/' . bin2hex($rr['album']), - '$albumname' => template_escape($rr['album']), - '$albumalt' => t('View Album'), - '$imgalt' => template_escape($rr['filename']) - )); - + $photos[] = array( + 'id' => $rr['id'], + 'link' => $a->get_baseurl() . '/photos/' . $a->data['user']['nickname'] . '/image/' . $rr['resource-id'], + 'title' => t('View Photo'), + 'src' => $a->get_baseurl() . '/photo/' . $rr['resource-id'] . '-' . ((($rr['scale']) == 6) ? 4 : $rr['scale']) . '.jpg', + 'alt' => template_escape($rr['filename']), + 'album' => array( + 'link' => $a->get_baseurl() . '/photos/' . $a->data['user']['nickname'] . '/album/' . bin2hex($rr['album']), + 'name' => template_escape($rr['album']), + 'alt' => t('View Album'), + ), + + ); } - $o .= '
'; } + + $tpl = get_markup_template('photos_recent.tpl'); + $o .= replace_macros($tpl,array( + '$title' => t('Recent Photos'), + '$can_post' => $can_post, + '$upload' => array(t('Upload New Photos'), $a->get_baseurl().'/photos/'.$a->data['user']['nickname'].'/upload'), + '$photos' => $photos, + )); + + $o .= paginate($a); return $o; } diff --git a/view/contact_template.tpl b/view/contact_template.tpl index e1a080b675..f2749656a2 100644 --- a/view/contact_template.tpl +++ b/view/contact_template.tpl @@ -1,23 +1,21 @@ -
-
-
+
+
$name - menu -
-
    - $contact_photo_menu -
-
+ menu +
-
-
$name
+
$name
+ -
+ diff --git a/view/directory_item.tpl b/view/directory_item.tpl index 031f4ff229..b45da4465e 100644 --- a/view/directory_item.tpl +++ b/view/directory_item.tpl @@ -1,14 +1,11 @@
-
-
$alt-text +
+
+ $alt-text +
+
+ +
$name
+
$details
-
-
-
-
$name
-
-
-
$details
-
-
\ No newline at end of file diff --git a/view/jot-header.tpl b/view/jot-header.tpl index ecfed6c423..4186ef78e2 100644 --- a/view/jot-header.tpl +++ b/view/jot-header.tpl @@ -81,7 +81,7 @@ function initEditor(cb){ ed.onInit.add(function(ed) { ed.pasteAsPlainText = true; $("#profile-jot-text-loading").hide(); - $("#profile-jot-submit-wrapper").show(); + $(".jothidden").show(); if (typeof cb!="undefined") cb(); }); @@ -98,19 +98,21 @@ function initEditor(cb){ } } +function enableOnUser(){ + if (editor) return; + $(this).val(""); + initEditor(); +} + {{ endif }} + + +
- -
- -
-
- $bang -
-
-
-
- $acl -
-
$emailcc
-
- $jotnets -
-
- -
- -
- + +
+
+ $acl +
+
$emailcc
+
+ $jotnets +
+
+ + + + diff --git a/view/photo_top.tpl b/view/photo_top.tpl index ab88c5ff52..04a054b520 100644 --- a/view/photo_top.tpl +++ b/view/photo_top.tpl @@ -1,6 +1,8 @@
- $imgalt - + + $photo.alt + +
-
+ diff --git a/view/photos_recent.tpl b/view/photos_recent.tpl new file mode 100644 index 0000000000..b8cb924b79 --- /dev/null +++ b/view/photos_recent.tpl @@ -0,0 +1,10 @@ +

$title

+{{ if $can_post }} +$upload.0 +{{ endif }} + +
+{{ for $photos as $photo }} + {{ inc photo_top.tpl }}{{ endinc }} +{{ endfor }} +
diff --git a/view/settings_oauth.tpl b/view/settings_oauth.tpl index bc5866bec9..0de0dbe98a 100644 --- a/view/settings_oauth.tpl +++ b/view/settings_oauth.tpl @@ -23,8 +23,8 @@ $tabs {{ endif }} {{ endif }} {{ if $app.my }} -   -   +   +   {{ endif }} {{ endfor }} diff --git a/view/theme/quattro/jot.tpl b/view/theme/duepuntozero/jot.tpl similarity index 72% rename from view/theme/quattro/jot.tpl rename to view/theme/duepuntozero/jot.tpl index d65ac8b17d..78cbecea81 100644 --- a/view/theme/quattro/jot.tpl +++ b/view/theme/duepuntozero/jot.tpl @@ -20,37 +20,33 @@ {{ if $content }}{{ endif }} -