diff --git a/.gitignore b/.gitignore index 34675be90..5fe71a7a8 100644 --- a/.gitignore +++ b/.gitignore @@ -21,5 +21,6 @@ report/ .buildpath .externalToolBuilders .settings +#ignore OSX .DS_Store files +.DS_Store -view/theme/smoothly \ No newline at end of file diff --git a/boot.php b/boot.php index 7ae4ca315..93c7a3b9c 100644 --- a/boot.php +++ b/boot.php @@ -11,9 +11,9 @@ require_once('include/cache.php'); require_once('library/Mobile_Detect/Mobile_Detect.php'); define ( 'FRIENDICA_PLATFORM', 'Friendica'); -define ( 'FRIENDICA_VERSION', '3.0.1461' ); +define ( 'FRIENDICA_VERSION', '3.0.1471' ); define ( 'DFRN_PROTOCOL_VERSION', '2.23' ); -define ( 'DB_UPDATE_VERSION', 1154 ); +define ( 'DB_UPDATE_VERSION', 1156 ); define ( 'EOL', "
\r\n" ); define ( 'ATOM_TIME', 'Y-m-d\TH:i:s\Z' ); @@ -1511,14 +1511,20 @@ if(! function_exists('current_theme')) { $is_mobile = $mobile_detect->isMobile() || $mobile_detect->isTablet(); if($is_mobile) { - $system_theme = ((isset($a->config['system']['mobile-theme'])) ? $a->config['system']['mobile-theme'] : ''); - $theme_name = ((isset($_SESSION) && x($_SESSION,'mobile-theme')) ? $_SESSION['mobile-theme'] : $system_theme); - - if($theme_name === '---') { - // user has selected to have the mobile theme be the same as the normal one + if(isset($_SESSION['show-mobile']) && !$_SESSION['show-mobile']) { $system_theme = ''; $theme_name = ''; } + else { + $system_theme = ((isset($a->config['system']['mobile-theme'])) ? $a->config['system']['mobile-theme'] : ''); + $theme_name = ((isset($_SESSION) && x($_SESSION,'mobile-theme')) ? $_SESSION['mobile-theme'] : $system_theme); + + if($theme_name === '---') { + // user has selected to have the mobile theme be the same as the normal one + $system_theme = ''; + $theme_name = ''; + } + } } if(!$is_mobile || ($system_theme === '' && $theme_name === '')) { $system_theme = ((isset($a->config['system']['theme'])) ? $a->config['system']['theme'] : ''); @@ -1760,3 +1766,20 @@ function build_querystring($params, $name=null) { } return $ret; } + +/** +* Returns the complete URL of the current page, e.g.: http(s)://something.com/network +* +* Taken from http://webcheatsheet.com/php/get_current_page_url.php +*/ +function curPageURL() { + $pageURL = 'http'; + if ($_SERVER["HTTPS"] == "on") {$pageURL .= "s";} + $pageURL .= "://"; + if ($_SERVER["SERVER_PORT"] != "80" && $_SERVER["SERVER_PORT"] != "443") { + $pageURL .= $_SERVER["SERVER_NAME"].":".$_SERVER["SERVER_PORT"].$_SERVER["REQUEST_URI"]; + } else { + $pageURL .= $_SERVER["SERVER_NAME"].$_SERVER["REQUEST_URI"]; + } + return $pageURL; +} diff --git a/database.sql b/database.sql index 6ba4921cb..0f82616f7 100644 --- a/database.sql +++ b/database.sql @@ -260,6 +260,7 @@ CREATE TABLE IF NOT EXISTS `event` ( `type` char(255) NOT NULL, `nofinish` tinyint(1) NOT NULL DEFAULT '0', `adjust` tinyint(1) NOT NULL DEFAULT '1', + `ignore` tinyint(1) NOT NULL DEFAULT '0', `allow_cid` mediumtext NOT NULL, `allow_gid` mediumtext NOT NULL, `deny_cid` mediumtext NOT NULL, @@ -271,7 +272,8 @@ CREATE TABLE IF NOT EXISTS `event` ( KEY `type` ( `type` ), KEY `start` ( `start` ), KEY `finish` ( `finish` ), - KEY `adjust` ( `adjust` ) + KEY `adjust` ( `adjust` ), + KEY `ignore` ( `ignore` ) ) ENGINE=MyISAM DEFAULT CHARSET=utf8; -- -------------------------------------------------------- @@ -590,11 +592,13 @@ CREATE TABLE IF NOT EXISTS `item` ( -- CREATE TABLE IF NOT EXISTS `item_id` ( + `id` int(11) NOT NULL AUTO_INCREMENT, `iid` int(11) NOT NULL, `uid` int(11) NOT NULL, `sid` char(255) NOT NULL, `service` char(255) NOT NULL, - PRIMARY KEY (`iid`), + PRIMARY KEY (`id`), + KEY `iid` (`iid`), KEY `uid` (`uid`), KEY `sid` (`sid`), KEY `service` (`service`) diff --git a/images/smiley-beard.png b/images/smiley-beard.png deleted file mode 100644 index 5d4b28463..000000000 Binary files a/images/smiley-beard.png and /dev/null differ diff --git a/images/smiley-whitebeard.png b/images/smiley-whitebeard.png deleted file mode 100644 index 2a1fccbb7..000000000 Binary files a/images/smiley-whitebeard.png and /dev/null differ diff --git a/include/Photo.php b/include/Photo.php index 5b6e6d846..00c424c64 100644 --- a/include/Photo.php +++ b/include/Photo.php @@ -46,9 +46,52 @@ class Photo { } $this->type = $type; - if($this->is_imagick()) { - $this->image = new Imagick(); - $this->image->readImageBlob($data); + if($this->is_imagick() && $this->load_data($data)) { + return true; + } else { + // Failed to load with Imagick, fallback + $this->imagick = false; + } + return $this->load_data($data); + } + + public function __destruct() { + if($this->image) { + if($this->is_imagick()) { + $this->image->clear(); + $this->image->destroy(); + return; + } + imagedestroy($this->image); + } + } + + public function is_imagick() { + return $this->imagick; + } + + /** + * Maps Mime types to Imagick formats + */ + public function get_FormatsMap() { + $m = array( + 'image/jpeg' => 'JPG', + 'image/png' => 'PNG', + 'image/gif' => 'GIF' + ); + return $m; + } + + private function load_data($data) { + if($this->is_imagick()) { + $this->image = new Imagick(); + try { + $this->image->readImageBlob($data); + } + catch (Exception $e) { + // Imagick couldn't use the data + return false; + } /** * Setup the image to the format it will be saved to @@ -85,45 +128,28 @@ class Photo { $quality = JPEG_QUALITY; $this->image->setCompressionQuality($quality); } - } else { - $this->valid = false; - $this->image = @imagecreatefromstring($data); - if($this->image !== FALSE) { - $this->width = imagesx($this->image); - $this->height = imagesy($this->image); - $this->valid = true; - imagealphablending($this->image, false); - imagesavealpha($this->image, true); - } - } - } - public function __destruct() { - if($this->image) { - if($this->is_imagick()) { - $this->image->clear(); - $this->image->destroy(); - return; - } - imagedestroy($this->image); - } - } + $this->width = $this->image->getImageWidth(); + $this->height = $this->image->getImageHeight(); + $this->valid = true; - public function is_imagick() { - return $this->imagick; - } + return true; + } - /** - * Maps Mime types to Imagick formats - */ - public function get_FormatsMap() { - $m = array( - 'image/jpeg' => 'JPG', - 'image/png' => 'PNG', - 'image/gif' => 'GIF' - ); - return $m; - } + $this->valid = false; + $this->image = @imagecreatefromstring($data); + if($this->image !== FALSE) { + $this->width = imagesx($this->image); + $this->height = imagesy($this->image); + $this->valid = true; + imagealphablending($this->image, false); + imagesavealpha($this->image, true); + + return true; + } + + return false; + } public function is_valid() { if($this->is_imagick()) @@ -637,7 +663,7 @@ function import_profile_photo($photo,$uid,$cid) { intval($uid), intval($cid) ); - if(count($r)) { + if(count($r) && strlen($r[0]['resource-id'])) { $hash = $r[0]['resource-id']; } else { diff --git a/include/bbcode.php b/include/bbcode.php index 5a6505740..d83fe6c12 100644 --- a/include/bbcode.php +++ b/include/bbcode.php @@ -215,10 +215,6 @@ function bbcode($Text,$preserve_nl = false, $tryoembed = true) { $a = get_app(); - // Move all spaces out of the tags - $Text = preg_replace("/\[(\w*)\](\s*)/ism", '$2[$1]', $Text); - $Text = preg_replace("/(\s*)\[\/(\w*)\]/ism", '[/$2]$1', $Text); - // Hide all [noparse] contained bbtags by spacefying them // POSSIBLE BUG --> Will the 'preg' functions crash if there's an embedded image? @@ -227,6 +223,10 @@ function bbcode($Text,$preserve_nl = false, $tryoembed = true) { $Text = preg_replace_callback("/\[pre\](.*?)\[\/pre\]/ism", 'bb_spacefy',$Text); + // Move all spaces out of the tags + $Text = preg_replace("/\[(\w*)\](\s*)/ism", '$2[$1]', $Text); + $Text = preg_replace("/(\s*)\[\/(\w*)\]/ism", '[/$2]$1', $Text); + // Extract the private images which use data url's since preg has issues with // large data sizes. Stash them away while we do bbcode conversion, and then put them back // in after we've done all the regex matching. We cannot use any preg functions to do this. diff --git a/include/conversation.php b/include/conversation.php index ceef63a99..cf5b0fe08 100644 --- a/include/conversation.php +++ b/include/conversation.php @@ -59,8 +59,8 @@ function item_redir_and_replace_images($body, $images, $cid) { while($pos !== false && $cnt < 1000) { $search = '/\[url\=(.*?)\]\[!#saved_image([0-9]*)#!\]\[\/url\]' . '/is'; - $replace = '[url=' . z_path() . '/redir/' . $cid - . '?f=1&url=' . '$1' . '][!#saved_image' . '$2' .'#!][/url]'; + $replace = '[url=' . z_path() . '/redir/' . $cid + . '?f=1&url=' . '$1' . '][!#saved_image' . '$2' .'#!][/url]'; $newbody .= substr($origbody, 0, $pos['start']['open']); $subject = substr($origbody, $pos['start']['open'], $pos['end']['close'] - $pos['start']['open']); @@ -99,17 +99,17 @@ function localize_item(&$item){ $item['body'] = item_redir_and_replace_images($extracted['body'], $extracted['images'], $item['contact-id']); $xmlhead="<"."?xml version='1.0' encoding='UTF-8' ?".">"; - if ($item['verb']=== ACTIVITY_LIKE || $item['verb']=== ACTIVITY_DISLIKE){ + if (activity_match($item['verb'],ACTIVITY_LIKE) || activity_match($item['verb'],ACTIVITY_DISLIKE)){ - $r = q("SELECT * from `item`,`contact` WHERE + $r = q("SELECT * from `item`,`contact` WHERE `item`.`contact-id`=`contact`.`id` AND `item`.`uri`='%s';", dbesc($item['parent-uri'])); if(count($r)==0) return; $obj=$r[0]; - - $author = '[url=' . $item['author-link'] . ']' . $item['author-name'] . '[/url]'; + + $author = '[url=' . $item['author-link'] . ']' . $item['author-name'] . '[/url]'; $objauthor = '[url=' . $obj['author-link'] . ']' . $obj['author-name'] . '[/url]'; - + switch($obj['verb']){ case ACTIVITY_POST: switch ($obj['object-type']){ @@ -123,38 +123,36 @@ function localize_item(&$item){ default: if($obj['resource-id']){ $post_type = t('photo'); - $m=array(); preg_match("/\[url=([^]]*)\]/", $obj['body'], $m); + $m=array(); preg_match("/\[url=([^]]*)\]/", $obj['body'], $m); $rr['plink'] = $m[1]; } else { $post_type = t('status'); } } - + $plink = '[url=' . $obj['plink'] . ']' . $post_type . '[/url]'; - - switch($item['verb']){ - case ACTIVITY_LIKE : - $bodyverb = t('%1$s likes %2$s\'s %3$s'); - break; - case ACTIVITY_DISLIKE: - $bodyverb = t('%1$s doesn\'t like %2$s\'s %3$s'); - break; + + if(activity_match($item['verb'],ACTIVITY_LIKE)) { + $bodyverb = t('%1$s likes %2$s\'s %3$s'); + } + elseif(activity_match($item['verb'],ACTIVITY_DISLIKE)) { + $bodyverb = t('%1$s doesn\'t like %2$s\'s %3$s'); } $item['body'] = sprintf($bodyverb, $author, $objauthor, $plink); - + } - if ($item['verb']=== ACTIVITY_FRIEND){ + if (activity_match($item['verb'],ACTIVITY_FRIEND)) { if ($item['object-type']=="" || $item['object-type']!== ACTIVITY_OBJ_PERSON) return; $Aname = $item['author-name']; $Alink = $item['author-link']; - + $xmlhead="<"."?xml version='1.0' encoding='UTF-8' ?".">"; - + $obj = parse_xml_string($xmlhead.$item['object']); $links = parse_xml_string($xmlhead."".unxmlify($obj->link).""); - + $Bname = $obj->title; $Blink = ""; $Bphoto = ""; foreach ($links->link as $l){ @@ -163,9 +161,9 @@ function localize_item(&$item){ case "alternate": $Blink = $atts['href']; case "photo": $Bphoto = $atts['href']; } - + } - + $A = '[url=' . zrl($Alink) . ']' . $Aname . '[/url]'; $B = '[url=' . zrl($Blink) . ']' . $Bname . '[/url]'; if ($Bphoto!="") $Bphoto = '[url=' . zrl($Blink) . '][img]' . $Bphoto . '[/img][/url]'; @@ -181,12 +179,12 @@ function localize_item(&$item){ $Aname = $item['author-name']; $Alink = $item['author-link']; - + $xmlhead="<"."?xml version='1.0' encoding='UTF-8' ?".">"; - + $obj = parse_xml_string($xmlhead.$item['object']); $links = parse_xml_string($xmlhead."".unxmlify($obj->link).""); - + $Bname = $obj->title; $Blink = ""; $Bphoto = ""; foreach ($links->link as $l){ @@ -195,9 +193,9 @@ function localize_item(&$item){ case "alternate": $Blink = $atts['href']; case "photo": $Bphoto = $atts['href']; } - + } - + $A = '[url=' . zrl($Alink) . ']' . $Aname . '[/url]'; $B = '[url=' . zrl($Blink) . ']' . $Bname . '[/url]'; if ($Bphoto!="") $Bphoto = '[url=' . zrl($Blink) . '][img=80x80]' . $Bphoto . '[/img][/url]'; @@ -224,22 +222,22 @@ function localize_item(&$item){ $Aname = $item['author-name']; $Alink = $item['author-link']; $A = '[url=' . zrl($Alink) . ']' . $Aname . '[/url]'; - + $txt = t('%1$s is currently %2$s'); $item['body'] = sprintf($txt, $A, t($verb)); } - if ($item['verb']===ACTIVITY_TAG){ - $r = q("SELECT * from `item`,`contact` WHERE + if (activity_match($item['verb'],ACTIVITY_TAG)) { + $r = q("SELECT * from `item`,`contact` WHERE `item`.`contact-id`=`contact`.`id` AND `item`.`uri`='%s';", dbesc($item['parent-uri'])); if(count($r)==0) return; $obj=$r[0]; - - $author = '[url=' . zrl($item['author-link']) . ']' . $item['author-name'] . '[/url]'; + + $author = '[url=' . zrl($item['author-link']) . ']' . $item['author-name'] . '[/url]'; $objauthor = '[url=' . zrl($obj['author-link']) . ']' . $obj['author-name'] . '[/url]'; - + switch($obj['verb']){ case ACTIVITY_POST: switch ($obj['object-type']){ @@ -253,30 +251,30 @@ function localize_item(&$item){ default: if($obj['resource-id']){ $post_type = t('photo'); - $m=array(); preg_match("/\[url=([^]]*)\]/", $obj['body'], $m); + $m=array(); preg_match("/\[url=([^]]*)\]/", $obj['body'], $m); $rr['plink'] = $m[1]; } else { $post_type = t('status'); } } $plink = '[url=' . $obj['plink'] . ']' . $post_type . '[/url]'; - + $parsedobj = parse_xml_string($xmlhead.$item['object']); - + $tag = sprintf('#[url=%s]%s[/url]', $parsedobj->id, $parsedobj->content); $item['body'] = sprintf( t('%1$s tagged %2$s\'s %3$s with %4$s'), $author, $objauthor, $plink, $tag ); - + } - if ($item['verb']=== ACTIVITY_FAVORITE){ + if (activity_match($item['verb'],ACTIVITY_FAVORITE)){ if ($item['object-type']== "") return; $Aname = $item['author-name']; $Alink = $item['author-link']; - + $xmlhead="<"."?xml version='1.0' encoding='UTF-8' ?".">"; - + $obj = parse_xml_string($xmlhead.$item['object']); if(strlen($obj->id)) { $r = q("select * from item where uri = '%s' and uid = %d limit 1", @@ -318,7 +316,7 @@ function localize_item(&$item){ $y = best_link_url($item,$sparkle,true); if(strstr($y,'/redir/')) $item['plink'] = $y . '?f=&url=' . $item['plink']; - } + } @@ -332,9 +330,8 @@ function count_descendants($item) { if($total > 0) { foreach($item['children'] as $child) { - if($child['verb'] === ACTIVITY_LIKE || $child['verb'] === ACTIVITY_DISLIKE) { + if(! visible_activity($child)) $total --; - } $total += count_descendants($child); } } @@ -342,6 +339,17 @@ function count_descendants($item) { return $total; } +function visible_activity($item) { + + if(activity_match($child['verb'],ACTIVITY_LIKE) || activity_match($child['verb'],ACTIVITY_DISLIKE)) + return false; + + if(activity_match($item['verb'],ACTIVITY_FOLLOW) && $item['object-type'] === ACTIVITY_OBJ_NOTE && $item['uid'] != local_user()) + return false; + + return true; +} + /** * Recursively prepare a thread for HTML */ @@ -353,19 +361,18 @@ function prepare_threads_body($a, $items, $cmnt_tpl, $page_writeable, $mode, $pr $wallwall_template = 'wallwall_thread.tpl'; $items_seen = 0; $nb_items = count($items); - + $total_children = $nb_items; - + foreach($items as $item) { if($item['network'] === NETWORK_MAIL && local_user() != $item['uid']) { // Don't count it as a visible item $nb_items--; $total_children --; } - if($item['verb'] === ACTIVITY_LIKE || $item['verb'] === ACTIVITY_DISLIKE) { + if(! visible_activity($item)) { $nb_items --; $total_children --; - } } @@ -375,12 +382,12 @@ function prepare_threads_body($a, $items, $cmnt_tpl, $page_writeable, $mode, $pr continue; } - if($item['verb'] === ACTIVITY_LIKE || $item['verb'] === ACTIVITY_DISLIKE) { + if(! visible_activity($item)) { continue; } - + $items_seen++; - + $comment = ''; $template = $wall_template; $commentww = ''; @@ -417,13 +424,13 @@ function prepare_threads_body($a, $items, $cmnt_tpl, $page_writeable, $mode, $pr $item_writeable = (($item['writable'] || $item['self']) ? true : false); // This will allow us to comment on wall-to-wall items owned by our friends - // and community forums even if somebody else wrote the post. + // and community forums even if somebody else wrote the post. if($visiting && $mode == 'profile') $item_writeable = true; $show_comment_box = ((($page_writeable) && ($item_writeable)) ? true : false); - $lock = ((($item['private'] == 1) || (($item['uid'] == local_user()) && (strlen($item['allow_cid']) || strlen($item['allow_gid']) + $lock = ((($item['private'] == 1) || (($item['uid'] == local_user()) && (strlen($item['allow_cid']) || strlen($item['allow_gid']) || strlen($item['deny_cid']) || strlen($item['deny_gid'])))) ? t('Private Message') : false); @@ -436,10 +443,10 @@ function prepare_threads_body($a, $items, $cmnt_tpl, $page_writeable, $mode, $pr $drop = array( 'dropping' => $dropping, - 'select' => t('Select'), + 'select' => t('Select'), 'delete' => t('Delete'), ); - + $filer = (($profile_owner == local_user()) ? t("save to folder") : false); $diff_author = ((link_compare($item['url'],$item['author-link'])) ? false : true); @@ -454,7 +461,7 @@ function prepare_threads_body($a, $items, $cmnt_tpl, $page_writeable, $mode, $pr if($sp) $sparkle = ' sparkle'; else - $profile_link = zrl($profile_link); + $profile_link = zrl($profile_link); $normalised = normalise_link((strlen($item['author-link'])) ? $item['author-link'] : $item['url']); if(($normalised != 'mailbox') && (x($a->contacts,$normalised))) @@ -467,9 +474,19 @@ function prepare_threads_body($a, $items, $cmnt_tpl, $page_writeable, $mode, $pr $location = ((strlen($locate['html'])) ? $locate['html'] : render_location_google($locate)); $tags=array(); + $hashtags = array(); + $mentions = array(); foreach(explode(',',$item['tag']) as $tag){ $tag = trim($tag); - if ($tag!="") $tags[] = bbcode($tag); + if ($tag!="") { + $t = bbcode($tag); + $tags[] = $t; + if($t[0] == '#') + $hashtags[] = $t; + elseif($t[0] == '@') + $mentions[] = $t; + } + } $like = ((x($alike,$item['uri'])) ? format_like($alike[$item['uri']],$alike[$item['uri'] . '-l'],'like',$item['uri']) : ''); @@ -487,7 +504,7 @@ function prepare_threads_body($a, $items, $cmnt_tpl, $page_writeable, $mode, $pr $owner_photo = $a->page_contact['thumb']; $owner_name = $a->page_contact['name']; $template = $wallwall_template; - $commentww = 'ww'; + $commentww = 'ww'; } else if($item['owner-link']) { @@ -497,14 +514,14 @@ function prepare_threads_body($a, $items, $cmnt_tpl, $page_writeable, $mode, $pr if((! $owner_linkmatch) && (! $alias_linkmatch) && (! $owner_namematch)) { // The author url doesn't match the owner (typically the contact) - // and also doesn't match the contact alias. - // The name match is a hack to catch several weird cases where URLs are + // and also doesn't match the contact alias. + // The name match is a hack to catch several weird cases where URLs are // all over the park. It can be tricked, but this prevents you from // seeing "Bob Smith to Bob Smith via Wall-to-wall" and you know darn - // well that it's the same Bob Smith. + // well that it's the same Bob Smith. + + // But it could be somebody else with the same name. It just isn't highly likely. - // But it could be somebody else with the same name. It just isn't highly likely. - $owner_url = $item['owner-link']; $owner_photo = $item['owner-avatar']; @@ -512,7 +529,7 @@ function prepare_threads_body($a, $items, $cmnt_tpl, $page_writeable, $mode, $pr $template = $wallwall_template; $commentww = 'ww'; // If it is our contact, use a friendly redirect link - if((link_compare($item['owner-link'],$item['url'])) + if((link_compare($item['owner-link'],$item['url'])) && ($item['network'] === NETWORK_DFRN)) { $owner_url = $redirect_url; $osparkle = ' sparkle'; @@ -577,7 +594,7 @@ function prepare_threads_body($a, $items, $cmnt_tpl, $page_writeable, $mode, $pr } $comment = replace_macros($cmnt_tpl,array( '$return_path' => '', - '$threaded' => $comments_threaded, + '$threaded' => $comments_threaded, '$jsreload' => (($mode === 'display') ? $_SESSION['return_url'] : ''), '$type' => (($mode === 'profile') ? 'wall-comment' : 'net-comment'), '$id' => $item['item_id'], @@ -618,9 +635,11 @@ function prepare_threads_body($a, $items, $cmnt_tpl, $page_writeable, $mode, $pr 'comment_lastcollapsed' => $lastcollapsed, // template to use to render item (wall, walltowall, search) 'template' => $template, - + 'type' => implode("",array_slice(explode("/",$item['verb']),-1)), - 'tags' => $tags, + 'tags' => template_escape($tags), + 'hashtags' => template_escape($hashtags), + 'mentions' => template_escape($mentions), 'body' => template_escape($body), 'text' => strip_tags(template_escape($body)), 'id' => $item['item_id'], @@ -666,6 +685,8 @@ function prepare_threads_body($a, $items, $cmnt_tpl, $page_writeable, $mode, $pr $item_result = $arr['output']; if($firstcollapsed) { $item_result['num_comments'] = sprintf( tt('%d comment','%d comments',$total_children),$total_children ); + $item_result['hidden_comments_num'] = $total_children; + $item_result['hidden_comments_text'] = tt('comment', 'comments', $total_children); $item_result['hide_text'] = t('show more'); } @@ -690,7 +711,7 @@ function prepare_threads_body($a, $items, $cmnt_tpl, $page_writeable, $mode, $pr $item_result['comment'] = false; } } - + $result[] = $item_result; } @@ -703,7 +724,7 @@ function prepare_threads_body($a, $items, $cmnt_tpl, $page_writeable, $mode, $pr * - Sequential or unthreaded ("New Item View" or search results) * - conversation view * The $mode parameter decides between the various renderings and also - * figures out how to determine page owner and other contextual items + * figures out how to determine page owner and other contextual items * that are based on unique features of the calling module. * */ @@ -768,19 +789,19 @@ function conversation(&$a, $items, $mode, $update, $preview = false) { $alike = array(); $dlike = array(); - - + + // array with html for each thread (parent+comments) $threads = array(); $threadsid = -1; $page_template = get_markup_template("conversation.tpl"); - + if($items && count($items)) { if($mode === 'network-new' || $mode === 'search' || $mode === 'community') { - // "New Item View" on network page or search page results + // "New Item View" on network page or search page results // - just loop through the items and format them minimally for display //$tpl = get_markup_template('search_item.tpl'); @@ -796,24 +817,39 @@ function conversation(&$a, $items, $mode, $update, $preview = false) { $sparkle = ''; if($mode === 'search' || $mode === 'community') { - if(((activity_match($item['verb'],ACTIVITY_LIKE)) || (activity_match($item['verb'],ACTIVITY_DISLIKE))) + if(((activity_match($item['verb'],ACTIVITY_LIKE)) || (activity_match($item['verb'],ACTIVITY_DISLIKE))) && ($item['id'] != $item['parent'])) continue; $nickname = $item['nickname']; } else $nickname = $a->user['nickname']; - + // prevent private email from leaking. if($item['network'] === NETWORK_MAIL && local_user() != $item['uid']) continue; - + $profile_name = ((strlen($item['author-name'])) ? $item['author-name'] : $item['name']); if($item['author-link'] && (! $item['author-name'])) $profile_name = $item['author-link']; + $tags=array(); + $hashtags = array(); + $mentions = array(); + foreach(explode(',',$item['tag']) as $tag){ + $tag = trim($tag); + if ($tag!="") { + $t = bbcode($tag); + $tags[] = $t; + if($t[0] == '#') + $hashtags[] = $t; + elseif($t[0] == '@') + $mentions[] = $t; + } + } + $sp = false; $profile_link = best_link_url($item,$sp); if($profile_link === 'mailbox') @@ -821,7 +857,7 @@ function conversation(&$a, $items, $mode, $update, $preview = false) { if($sp) $sparkle = ' sparkle'; else - $profile_link = zrl($profile_link); + $profile_link = zrl($profile_link); $normalised = normalise_link((strlen($item['author-link'])) ? $item['author-link'] : $item['url']); if(($normalised != 'mailbox') && (x($a->contacts[$normalised]))) @@ -843,19 +879,19 @@ function conversation(&$a, $items, $mode, $update, $preview = false) { $drop = array( 'dropping' => $dropping, - 'select' => t('Select'), + 'select' => t('Select'), 'delete' => t('Delete'), ); $star = false; $isstarred = "unstarred"; - + $lock = false; $likebuttons = false; $shareable = false; $body = prepare_body($item,true); - + //$tmp_item = replace_macros($tpl,array( $tmp_item = array( 'template' => $tpl, @@ -869,6 +905,9 @@ function conversation(&$a, $items, $mode, $update, $preview = false) { 'thumb' => $profile_avatar, 'title' => template_escape($item['title']), 'body' => template_escape($body), + 'tags' => template_escape($tags), + 'hashtags' => template_escape($hashtags), + 'mentions' => template_escape($mentions), 'text' => strip_tags(template_escape($body)), 'localtime' => datetime_convert('UTC', date_default_timezone_get(), $item['created'], 'r'), 'ago' => (($item['app']) ? sprintf( t('%s from %s'),relative_date($item['created']),$item['app']) : relative_date($item['created'])), @@ -906,25 +945,44 @@ function conversation(&$a, $items, $mode, $update, $preview = false) { // Normal View $page_template = get_markup_template("threaded_conversation.tpl"); + require_once('object/Conversation.php'); + require_once('object/Item.php'); + + $conv = new Conversation($mode, $preview); + // get all the topmost parents - // this shouldn't be needed, as we should have only them in ou array + // this shouldn't be needed, as we should have only them in our array // But for now, this array respects the old style, just in case $threads = array(); foreach($items as $item) { + // Can we put this after the visibility check? like_puller($a,$item,$alike,'like'); like_puller($a,$item,$dlike,'dislike'); + // Only add what is visible + if($item['network'] === NETWORK_MAIL && local_user() != $item['uid']) { + continue; + } + if(! visible_activity($item)) { + continue; + } + if($item['id'] == $item['parent']) { - $threads[] = $item; + $item_object = new Item($item); + $conv->add_thread($item_object); } } - $threads = prepare_threads_body($a, $threads, $cmnt_tpl, $page_writeable, $mode, $profile_owner, $alike, $dlike, $previewing); + $threads = $conv->get_template_data($alike, $dlike); + if(!$threads) { + logger('[ERROR] conversation : Failed to get template data.', LOGGER_DEBUG); + $threads = array(); + } } } - + $o = replace_macros($page_template, array( '$baseurl' => $a->get_baseurl($ssl_state), '$mode' => $mode, @@ -985,7 +1043,7 @@ function item_photo_menu($item){ $posts_link=""; $sparkle = false; - $profile_link = best_link_url($item,$sparkle,$ssl_state); + $profile_link = best_link_url($item,$sparkle,$ssl_state); if($profile_link === 'mailbox') $profile_link = ''; @@ -1001,7 +1059,7 @@ function item_photo_menu($item){ $profile_link = zrl($profile_link); if(local_user() && local_user() == $item['uid'] && link_compare($item['url'],$item['author-link'])) { $cid = $item['contact-id']; - } + } else { $cid = 0; } @@ -1027,18 +1085,18 @@ function item_photo_menu($item){ t("View Status") => $status_link, t("View Profile") => $profile_link, t("View Photos") => $photos_link, - t("Network Posts") => $posts_link, + t("Network Posts") => $posts_link, t("Edit Contact") => $contact_url, t("Send PM") => $pm_url, t("Poke") => $poke_link ); - - + + $args = array('item' => $item, 'menu' => $menu); - + call_hooks('item_photo_menu', $args); - $menu = $args['menu']; + $menu = $args['menu']; $o = ""; foreach($menu as $k=>$v){ @@ -1070,7 +1128,7 @@ function like_puller($a,$item,&$arr,$mode) { $arr[$item['thr-parent'] . '-l'] = array(); if(! isset($arr[$item['thr-parent']])) $arr[$item['thr-parent']] = 1; - else + else $arr[$item['thr-parent']] ++; $arr[$item['thr-parent'] . '-l'][] = '' . $item['author-name'] . ''; } @@ -1091,10 +1149,10 @@ function format_like($cnt,$arr,$type,$id) { $o .= (($type === 'like') ? sprintf( t('%s likes this.'), $arr[0]) : sprintf( t('%s doesn\'t like this.'), $arr[0])) . EOL ; else { $spanatts = 'class="fakelink" onclick="openClose(\'' . $type . 'list-' . $id . '\');"'; - $o .= (($type === 'like') ? + $o .= (($type === 'like') ? sprintf( t('%2$d people like this.'), $spanatts, $cnt) - : - sprintf( t('%2$d people don\'t like this.'), $spanatts, $cnt) ); + : + sprintf( t('%2$d people don\'t like this.'), $spanatts, $cnt) ); $o .= EOL ; $total = count($arr); if($total >= MAX_LIKERS) @@ -1114,7 +1172,7 @@ function format_like($cnt,$arr,$type,$id) { function status_editor($a,$x, $notes_cid = 0, $popup=false) { $o = ''; - + $geotag = (($x['allow_location']) ? get_markup_template('jot_geotag.tpl') : ''); $plaintext = false; @@ -1156,7 +1214,7 @@ function status_editor($a,$x, $notes_cid = 0, $popup=false) { $tpl = get_markup_template("jot.tpl"); - + $jotplugins = ''; $jotnets = ''; @@ -1187,7 +1245,7 @@ function status_editor($a,$x, $notes_cid = 0, $popup=false) { if($notes_cid) $jotnets .= ''; - $tpl = replace_macros($tpl,array('$jotplugins' => $jotplugins)); + $tpl = replace_macros($tpl,array('$jotplugins' => $jotplugins)); $o .= replace_macros($tpl,array( '$return_path' => $a->query_string, @@ -1231,12 +1289,13 @@ function status_editor($a,$x, $notes_cid = 0, $popup=false) { '$profile_uid' => $x['profile_uid'], '$preview' => t('Preview'), '$sourceapp' => t($a->sourcename), + '$cancel' => t('Cancel') )); if ($popup==true){ $o = ''; - + } return $o; @@ -1252,7 +1311,7 @@ function get_item_children($arr, $parent) { $thr_parent = $item['thr-parent']; if($thr_parent == '') $thr_parent = $item['parent-uri']; - + if($thr_parent == $parent['uri']) { $item['children'] = get_item_children($arr, $item); $children[] = $item; @@ -1303,7 +1362,7 @@ function conv_sort($arr,$order) { usort($parents,'sort_thr_commented'); if(count($parents)) - foreach($parents as $i=>$_x) + foreach($parents as $i=>$_x) $parents[$i]['children'] = get_item_children($arr, $_x); /*foreach($arr as $x) { @@ -1321,7 +1380,7 @@ function conv_sort($arr,$order) { usort($y,'sort_thr_created_rev'); $parents[$k]['children'] = $y;*/ } - } + } } $ret = array(); diff --git a/include/diaspora.php b/include/diaspora.php index baee0420b..497bc7f39 100755 --- a/include/diaspora.php +++ b/include/diaspora.php @@ -2061,11 +2061,20 @@ function diaspora_profile($importer,$xml,$msg) { $image_url = unxmlify($xml->image_url); $birthday = unxmlify($xml->birthday); - $r = q("SELECT DISTINCT ( `resource-id` ) FROM `photo` WHERE `uid` = %d AND `contact-id` = %d AND `album` = 'Contact Photos' ", + + $handle_parts = explode("@", $diaspora_handle); + if($name === '') { + $name = $handle_parts[0]; + } + if(strpos($image_url, $handle_parts[1]) === false) { + $image_url = "http://" . $handle_parts[1] . $image_url; + } + +/* $r = q("SELECT DISTINCT ( `resource-id` ) FROM `photo` WHERE `uid` = %d AND `contact-id` = %d AND `album` = 'Contact Photos' ", intval($importer['uid']), intval($contact['id']) ); - $oldphotos = ((count($r)) ? $r : null); + $oldphotos = ((count($r)) ? $r : null);*/ require_once('include/Photo.php'); @@ -2098,7 +2107,7 @@ function diaspora_profile($importer,$xml,$msg) { intval($importer['uid']) ); - if($r) { +/* if($r) { if($oldphotos) { foreach($oldphotos as $ph) { q("DELETE FROM `photo` WHERE `uid` = %d AND `contact-id` = %d AND `album` = 'Contact Photos' AND `resource-id` = '%s' ", @@ -2108,7 +2117,7 @@ function diaspora_profile($importer,$xml,$msg) { ); } } - } + } */ return; diff --git a/include/items.php b/include/items.php index 206458b19..631a9725c 100755 --- a/include/items.php +++ b/include/items.php @@ -1190,6 +1190,15 @@ function tag_deliver($uid,$item_id) { // send a notification + // use a local photo if we have one + + $r = q("select thumb from contact where uid = %d and nurl = '%s' limit 1", + intval($u[0]['uid']), + dbesc(normalise_link($item['author-link'])) + ); + $photo = (($r && count($r)) ? $r[0]['thumb'] : $item['author-avatar']); + + require_once('include/enotify.php'); notification(array( 'type' => NOTIFY_TAGSELF, @@ -1202,7 +1211,7 @@ function tag_deliver($uid,$item_id) { 'link' => $a->get_baseurl() . '/display/' . $u[0]['nickname'] . '/' . $item['id'], 'source_name' => $item['author-name'], 'source_link' => $item['author-link'], - 'source_photo' => $item['author-avatar'], + 'source_photo' => $photo, 'verb' => ACTIVITY_TAG, 'otype' => 'item' )); @@ -1253,6 +1262,59 @@ function tag_deliver($uid,$item_id) { +function tgroup_check($uid,$item) { + + $a = get_app(); + + $mention = false; + + // check that the message originated elsewhere and is a top-level post + + if(($item['wall']) || ($item['origin']) || ($item['uri'] != $item['parent-uri'])) + return false; + + + $u = q("select * from user where uid = %d limit 1", + intval($uid) + ); + if(! count($u)) + return false; + + $community_page = (($u[0]['page-flags'] == PAGE_COMMUNITY) ? true : false); + $prvgroup = (($u[0]['page-flags'] == PAGE_PRVGROUP) ? true : false); + + + $link = normalise_link($a->get_baseurl() . '/profile/' . $u[0]['nickname']); + + // Diaspora uses their own hardwired link URL in @-tags + // instead of the one we supply with webfinger + + $dlink = normalise_link($a->get_baseurl() . '/u/' . $u[0]['nickname']); + + $cnt = preg_match_all('/[\@\!]\[url\=(.*?)\](.*?)\[\/url\]/ism',$item['body'],$matches,PREG_SET_ORDER); + if($cnt) { + foreach($matches as $mtch) { + if(link_compare($link,$mtch[1]) || link_compare($dlink,$mtch[1])) { + $mention = true; + logger('tgroup_check: mention found: ' . $mtch[2]); + } + } + } + + if(! $mention) + return false; + + if((! $community_page) && (! $prvgroup)) + return false; + + + + return true; + +} + + + @@ -1809,6 +1871,12 @@ function consume_feed($xml,$importer,&$contact, &$hub, $datedir = 0, $pass = 0) if($pass == 1) continue; + // not allowed to post + + if($contact['rel'] == CONTACT_IS_FOLLOWER) + continue; + + // Have we seen it? If not, import it. $item_id = $item->get_id(); @@ -2083,6 +2151,14 @@ function consume_feed($xml,$importer,&$contact, &$hub, $datedir = 0, $pass = 0) $datarray['owner-avatar'] = $contact['thumb']; } + // We've allowed "followers" to reach this point so we can decide if they are + // posting an @-tag delivery, which followers are allowed to do for certain + // page types. Now that we've parsed the post, let's check if it is legit. Otherwise ignore it. + + if(($contact['rel'] == CONTACT_IS_FOLLOWER) && (! tgroup_check($importer['uid'],$datarray))) + continue; + + $r = item_store($datarray); continue; @@ -2626,22 +2702,32 @@ function local_delivery($importer,$data) { // Specifically, the recipient? $is_a_remote_comment = false; - - // POSSIBLE CLEANUP --> Why select so many fields when only forum_mode and wall are used? - $r = q("select `item`.`id`, `item`.`uri`, `item`.`tag`, `item`.`forum_mode`,`item`.`origin`,`item`.`wall`, - `contact`.`name`, `contact`.`url`, `contact`.`thumb` from `item` - LEFT JOIN `contact` ON `contact`.`id` = `item`.`contact-id` - WHERE `item`.`uri` = '%s' AND (`item`.`parent-uri` = '%s' or `item`.`thr-parent` = '%s') - AND `item`.`uid` = %d - $sql_extra + $top_uri = $parent_uri; + + $r = q("select `item`.`parent-uri` from `item` + WHERE `item`.`uri` = '%s' LIMIT 1", - dbesc($parent_uri), - dbesc($parent_uri), - dbesc($parent_uri), - intval($importer['importer_uid']) + dbesc($parent_uri) ); - if($r && count($r)) - $is_a_remote_comment = true; + if($r && count($r)) { + $top_uri = $r[0]['parent-uri']; + + // POSSIBLE CLEANUP --> Why select so many fields when only forum_mode and wall are used? + $r = q("select `item`.`id`, `item`.`uri`, `item`.`tag`, `item`.`forum_mode`,`item`.`origin`,`item`.`wall`, + `contact`.`name`, `contact`.`url`, `contact`.`thumb` from `item` + LEFT JOIN `contact` ON `contact`.`id` = `item`.`contact-id` + WHERE `item`.`uri` = '%s' AND (`item`.`parent-uri` = '%s' or `item`.`thr-parent` = '%s') + AND `item`.`uid` = %d + $sql_extra + LIMIT 1", + dbesc($top_uri), + dbesc($top_uri), + dbesc($top_uri), + intval($importer['importer_uid']) + ); + if($r && count($r)) + $is_a_remote_comment = true; + } // Does this have the characteristics of a community or private group comment? // If it's a reply to a wall post on a community/prvgroup page it's a @@ -2695,15 +2781,6 @@ function local_delivery($importer,$data) { } - // TODO: make this next part work against both delivery threads of a community post - -// if((! link_compare($datarray['author-link'],$importer['url'])) && (! $community)) { -// logger('local_delivery: received relay claiming to be from ' . $importer['url'] . ' however comment author url is ' . $datarray['author-link'] ); - // they won't know what to do so don't report an error. Just quietly die. -// return 0; -// } - - // our user with $importer['importer_uid'] is the owner $own = q("select name,url,thumb from contact where uid = %d and self = 1 limit 1", intval($importer['importer_uid']) @@ -2773,15 +2850,6 @@ function local_delivery($importer,$data) { } } -// if($community) { -// $newtag = '@[url=' . $a->get_baseurl() . '/profile/' . $importer['nickname'] . ']' . $importer['username'] . '[/url]'; -// if(! stristr($datarray['tag'],$newtag)) { -// if(strlen($datarray['tag'])) -// $datarray['tag'] .= ','; -// $datarray['tag'] .= $newtag; -// } -// } - $posted_id = item_store($datarray); $parent = 0; @@ -2851,6 +2919,9 @@ function local_delivery($importer,$data) { $item_id = $item->get_id(); $datarray = get_atom_elements($feed,$item); + if($importer['rel'] == CONTACT_IS_FOLLOWER) + continue; + $r = q("SELECT `uid`, `last-child`, `edited`, `body` FROM `item` WHERE `uri` = '%s' AND `uid` = %d LIMIT 1", dbesc($item_id), intval($importer['importer_uid']) @@ -2945,7 +3016,7 @@ function local_delivery($importer,$data) { if(!x($datarray['type']) || $datarray['type'] != 'activity') { $myconv = q("SELECT `author-link`, `author-avatar`, `parent` FROM `item` WHERE `parent-uri` = '%s' AND `uid` = %d AND `parent` != 0 AND `deleted` = 0", - dbesc($parent_uri), + dbesc($top_uri), intval($importer['importer_uid']) ); @@ -3085,6 +3156,9 @@ function local_delivery($importer,$data) { $datarray['owner-avatar'] = $importer['thumb']; } + if(($importer['rel'] == CONTACT_IS_FOLLOWER) && (! tgroup_check($importer['importer_uid'],$datarray))) + continue; + $posted_id = item_store($datarray); if(stristr($datarray['verb'],ACTIVITY_POKE)) { diff --git a/include/onepoll.php b/include/onepoll.php index 09e7bb763..4ca60a2fd 100644 --- a/include/onepoll.php +++ b/include/onepoll.php @@ -275,7 +275,7 @@ function onepoll_run($argv, $argc){ openssl_private_decrypt(hex2bin($mailconf[0]['pass']),$password,$x[0]['prvkey']); $mbox = email_connect($mailbox,$mailconf[0]['user'],$password); unset($password); - logger("Mail: Connect"); + logger("Mail: Connect to " . $mailconf[0]['user']); if($mbox) { q("UPDATE `mailacct` SET `last_check` = '%s' WHERE `id` = %d AND `uid` = %d LIMIT 1", dbesc(datetime_convert()), @@ -289,7 +289,7 @@ function onepoll_run($argv, $argc){ $msgs = email_poll($mbox,$contact['addr']); if(count($msgs)) { - logger("Mail: Parsing ".count($msgs)." mails.", LOGGER_DEBUG); + logger("Mail: Parsing ".count($msgs)." mails for ".$mailconf[0]['user'], LOGGER_DEBUG); foreach($msgs as $msg_uid) { logger("Mail: Parsing mail ".$msg_uid, LOGGER_DATA); @@ -339,15 +339,15 @@ function onepoll_run($argv, $argc){ case 0: break; case 1: - logger("Mail: Deleting ".$msg_uid); + logger("Mail: Deleting ".$msg_uid." for ".$mailconf[0]['user']); imap_delete($mbox, $msg_uid, FT_UID); break; case 2: - logger("Mail: Mark as seen ".$msg_uid); + logger("Mail: Mark as seen ".$msg_uid." for ".$mailconf[0]['user']); imap_setflag_full($mbox, $msg_uid, "\\Seen", ST_UID); break; case 3: - logger("Mail: Moving ".$msg_uid." to ".$mailconf[0]['movetofolder']); + logger("Mail: Moving ".$msg_uid." to ".$mailconf[0]['movetofolder']." for ".$mailconf[0]['user']); imap_setflag_full($mbox, $msg_uid, "\\Seen", ST_UID); if ($mailconf[0]['movetofolder'] != "") imap_mail_move($mbox, $msg_uid, $mailconf[0]['movetofolder'], FT_UID); @@ -377,12 +377,12 @@ function onepoll_run($argv, $argc){ $r = email_get_msg($mbox,$msg_uid, $reply); if(! $r) { - logger("Mail: can't fetch msg ".$msg_uid); + logger("Mail: can't fetch msg ".$msg_uid." for ".$mailconf[0]['user']); continue; } $datarray['body'] = escape_tags($r['body']); - logger("Mail: Importing ".$msg_uid); + logger("Mail: Importing ".$msg_uid." for ".$mailconf[0]['user']); // some mailing lists have the original author as 'from' - add this sender info to msg body. // todo: adding a gravatar for the original author would be cool @@ -423,15 +423,15 @@ function onepoll_run($argv, $argc){ case 0: break; case 1: - logger("Mail: Deleting ".$msg_uid); + logger("Mail: Deleting ".$msg_uid." for ".$mailconf[0]['user']); imap_delete($mbox, $msg_uid, FT_UID); break; case 2: - logger("Mail: Mark as seen ".$msg_uid); + logger("Mail: Mark as seen ".$msg_uid." for ".$mailconf[0]['user']); imap_setflag_full($mbox, $msg_uid, "\\Seen", ST_UID); break; case 3: - logger("Mail: Moving ".$msg_uid." to ".$mailconf[0]['movetofolder']); + logger("Mail: Moving ".$msg_uid." to ".$mailconf[0]['movetofolder']." for ".$mailconf[0]['user']); imap_setflag_full($mbox, $msg_uid, "\\Seen", ST_UID); if ($mailconf[0]['movetofolder'] != "") imap_mail_move($mbox, $msg_uid, $mailconf[0]['movetofolder'], FT_UID); diff --git a/include/user.php b/include/user.php index 2d06ef374..282bbdbba 100644 --- a/include/user.php +++ b/include/user.php @@ -277,18 +277,24 @@ function create_user($arr) { require_once('include/group.php'); group_add($newuid, t('Friends')); - if(! get_config('system', 'newuser_public')) { - $r = q("SELECT id FROM `group` WHERE uid = %d AND name = '%s'", - intval($newuid), - dbesc(t('Friends')) + $r = q("SELECT id FROM `group` WHERE uid = %d AND name = '%s'", + intval($newuid), + dbesc(t('Friends')) + ); + if($r && count($r)) { + $def_gid = $r[0]['id']; + + q("UPDATE user SET def_gid = %d WHERE uid = %d", + intval($r[0]['id']), + intval($newuid) + ); + } + + if(get_config('system', 'newuser_private') && $def_gid) { + q("UPDATE user SET allow_gid = '%s' WHERE uid = %d", + dbesc("<" . $def_gid . ">"), + intval($newuid) ); - if($r) { - q("UPDATE user SET def_gid = %d, allow_gid = '%s' WHERE uid = %d", - intval($r[0]['id']), - dbesc("<" . $r[0]['id'] . ">"), - intval($newuid) - ); - } } } diff --git a/index.php b/index.php index c9b7f34d7..eaa7295e2 100644 --- a/index.php +++ b/index.php @@ -13,8 +13,10 @@ */ require_once('boot.php'); +require_once('object/BaseObject.php'); $a = new App; +BaseObject::set_app($a); /** * diff --git a/js/country.js b/js/country.js index 1494dad2e..96165409a 100644 --- a/js/country.js +++ b/js/country.js @@ -275,7 +275,7 @@ aStates[249]="|'Adan|'Ataq|Abyan|Al Bayda'|Al Hudaydah|Al Jawf|Al Mahrah|Al Mahw aStates[250]="|Kosovo|Montenegro|Serbia|Vojvodina"; aStates[251]="|Central|Copperbelt|Eastern|Luapula|Lusaka|North-Western|Northern|Southern|Western"; aStates[252]="|Bulawayo|Harare|ManicalandMashonaland Central|Mashonaland East|Mashonaland West|Masvingo|Matabeleland North|Matabeleland South|Midlands"; -aStates[253]="|Self Hosted|Private Server|Architects Of Sleep|DFRN|Distributed Friend Network|ErrLock|Free-Beer.ch|Foojbook|Free-Haven|Friendica.eu|Friendika.me.4.it|Friendika - I Ask Questions|Frndc.com|Hikado|Hipatia|Hungerfreunde|Kaluguran Community|Kak Ste|Karl.Markx.pm|Loozah Social Club|MyFriendica.net|MyFriendNetwork|Oi!|OpenMindSpace|Optimistisch|Recolutionari.es|SilverLips|Sparkling Network|SPRACI|Styliztique|Sysfu Social Club|Trevena|theshi.re|Tumpambae|Uzmiac|Other"; +aStates[253]="|Self Hosted|Private Server|Architects Of Sleep|DFRN|Distributed Friend Network|ErrLock|Free-Beer.ch|Foojbook|Free-Haven|Friendica.eu|Friendika.me.4.it|Friendika - I Ask Questions|Frndc.com|Hikado|Hipatia|Hungerfreunde|Kaluguran Community|Kak Ste|Karl.Markx.pm|Loozah Social Club|MyFriendica.net|MyFriendNetwork|Oi!|OpenMindSpace|Optimistisch|Pplsnet|Recolutionari.es|SilverLips|Sparkling Network|SPRACI|Styliztique|Sysfu Social Club|Trevena|theshi.re|Tumpambae|Uzmiac|Other"; /* * gArCountryInfo * (0) Country name diff --git a/js/main.js b/js/main.js index 6ab574c4e..a28c8576f 100644 --- a/js/main.js +++ b/js/main.js @@ -144,6 +144,29 @@ if(mail == 0) { mail = ''; $('#mail-update-li').removeClass('show') } else { $('#mail-update-li').addClass('show') } $('#mail-update-li').html(mail); + + var allevents = $(data).find('all-events').text(); + if(allevents == 0) { allevents = ''; $('#allevents-update').removeClass('show') } else { $('#allevents-update').addClass('show') } + $('#allevents-update').html(allevents); + + var alleventstoday = $(data).find('all-events-today').text(); + if(alleventstoday == 0) { $('#allevents-update').removeClass('notif-allevents-today') } else { $('#allevents-update').addClass('notif-allevents-today') } + + var events = $(data).find('events').text(); + if(events == 0) { events = ''; $('#events-update').removeClass('show') } else { $('#events-update').addClass('show') } + $('#events-update').html(events); + + var eventstoday = $(data).find('events-today').text(); + if(eventstoday == 0) { $('#events-update').removeClass('notif-events-today') } else { $('#events-update').addClass('notif-events-today') } + + var birthdays = $(data).find('birthdays').text(); + if(birthdays == 0) {birthdays = ''; $('#birthdays-update').removeClass('show') } else { $('#birthdays-update').addClass('show') } + $('#birthdays-update').html(birthdays); + + var birthdaystoday = $(data).find('birthdays-today').text(); + if(birthdaystoday == 0) { $('#birthdays-update').removeClass('notif-birthdays-today') } else { $('#birthdays-update').addClass('notif-birthdays-today') } + + var eNotif = $(data).find('notif') if (eNotif.children("note").length==0){ diff --git a/library/HTML5/TreeBuilder.php b/library/HTML5/TreeBuilder.php index 578e73682..2a789f4df 100644 --- a/library/HTML5/TreeBuilder.php +++ b/library/HTML5/TreeBuilder.php @@ -158,6 +158,8 @@ class HTML5_TreeBuilder { if ($this->ignore_lf_token) $this->ignore_lf_token--; $this->ignored = false; + + $token['name'] = str_replace(':', '-', $token['name']); // indenting is a little wonky, this can be changed later on switch ($mode) { @@ -1429,7 +1431,7 @@ class HTML5_TreeBuilder { case 'tbody': case 'td': case 'tfoot': case 'th': case 'thead': case 'tr': // parse error break; - + /* A start tag token not covered by the previous entries */ default: /* Reconstruct the active formatting elements, if any. */ @@ -3038,7 +3040,7 @@ class HTML5_TreeBuilder { private function insertElement($token, $append = true) { $el = $this->dom->createElementNS(self::NS_HTML, $token['name']); - + if (!empty($token['attr'])) { foreach($token['attr'] as $attr) { diff --git a/mod/admin.php b/mod/admin.php index db4d4cff2..ee0483054 100644 --- a/mod/admin.php +++ b/mod/admin.php @@ -254,7 +254,7 @@ function admin_page_site_post(&$a){ $force_publish = ((x($_POST,'publish_all')) ? True : False); $global_directory = ((x($_POST,'directory_submit_url')) ? notags(trim($_POST['directory_submit_url'])) : ''); $thread_allow = ((x($_POST,'thread_allow')) ? True : False); - $newuser_public = ((x($_POST,'newuser_public')) ? True : False); + $newuser_private = ((x($_POST,'newuser_private')) ? True : False); $no_multi_reg = ((x($_POST,'no_multi_reg')) ? True : False); $no_openid = !((x($_POST,'no_openid')) ? True : False); $no_regfullname = !((x($_POST,'no_regfullname')) ? True : False); @@ -355,7 +355,7 @@ function admin_page_site_post(&$a){ set_config('system','directory_submit_url', $global_directory); } set_config('system','thread_allow', $thread_allow); - set_config('system','newuser_public', $newuser_public); + set_config('system','newuser_private', $newuser_private); set_config('system','block_extended_register', $no_multi_reg); set_config('system','no_openid', $no_openid); @@ -467,14 +467,14 @@ function admin_page_site(&$a) { '$force_publish' => array('publish_all', t("Force publish"), get_config('system','publish_all'), t("Check to force all profiles on this site to be listed in the site directory.")), '$global_directory' => array('directory_submit_url', t("Global directory update URL"), get_config('system','directory_submit_url'), t("URL to update the global directory. If this is not set, the global directory is completely unavailable to the application.")), '$thread_allow' => array('thread_allow', t("Allow threaded items"), get_config('system','thread_allow'), t("Allow infinite level threading for items on this site.")), - '$newuser_public' => array('newuser_public', t("No default permissions for new users"), get_config('system','newuser_public'), t("New users will have no private permissions set for their posts by default, making their posts public until they change it.")), + '$newuser_private' => array('newuser_private', t("Private posts by default for new users"), get_config('system','newuser_private'), t("Set default post permissions for all new members to the default privacy group rather than public.")), '$no_multi_reg' => array('no_multi_reg', t("Block multiple registrations"), get_config('system','block_extended_register'), t("Disallow users to register additional accounts for use as pages.")), '$no_openid' => array('no_openid', t("OpenID support"), !get_config('system','no_openid'), t("OpenID support for registration and logins.")), '$no_regfullname' => array('no_regfullname', t("Fullname check"), !get_config('system','no_regfullname'), t("Force users to register with a space between firstname and lastname in Full name, as an antispam measure")), '$no_utf' => array('no_utf', t("UTF-8 Regular expressions"), !get_config('system','no_utf'), t("Use PHP UTF8 regular expressions")), '$no_community_page' => array('no_community_page', t("Show Community Page"), !get_config('system','no_community_page'), t("Display a Community page showing all recent public postings on this site.")), - '$ostatus_disabled' => array('ostatus_disabled', t("Enable OStatus support"), !get_config('system','ostatus_disable'), t("Provide built-in OStatus \x28identi.ca, status.net, etc.\x29 compatibility. All communications in OStatus are public, so privacy warnings will be occasionally displayed.")), + '$ostatus_disabled' => array('ostatus_disabled', t("Enable OStatus support"), !get_config('system','ostatus_disabled'), t("Provide built-in OStatus \x28identi.ca, status.net, etc.\x29 compatibility. All communications in OStatus are public, so privacy warnings will be occasionally displayed.")), '$diaspora_enabled' => array('diaspora_enabled', t("Enable Diaspora support"), get_config('system','diaspora_enabled'), t("Provide built-in Diaspora network compatibility.")), '$dfrn_only' => array('dfrn_only', t('Only allow Friendica contacts'), get_config('system','dfrn_only'), t("All contacts must use Friendica protocols. All other built-in communication protocols disabled.")), '$verifyssl' => array('verifyssl', t("Verify SSL"), get_config('system','verifyssl'), t("If you wish, you can turn on strict certificate checking. This will mean you cannot connect (at all) to self-signed SSL sites.")), @@ -664,6 +664,7 @@ function admin_page_users(&$a){ ); function _setup_users($e){ + $a = get_app(); $accounts = Array( t('Normal Account'), t('Soapbox Account'), @@ -674,6 +675,7 @@ function admin_page_users(&$a){ $e['register_date'] = relative_date($e['register_date']); $e['login_date'] = relative_date($e['login_date']); $e['lastitem_date'] = relative_date($e['lastitem_date']); + $e['is_admin'] = ($e['email'] === $a->config['admin_email']); return $e; } $users = array_map("_setup_users", $users); @@ -694,6 +696,7 @@ function admin_page_users(&$a){ '$delete' => t('Delete'), '$block' => t('Block'), '$unblock' => t('Unblock'), + '$siteadmin' => t('Site admin'), '$h_users' => t('Users'), '$th_users' => array( t('Name'), t('Email'), t('Register date'), t('Last login'), t('Last item'), t('Account') ), diff --git a/mod/content.php b/mod/content.php index e6789860d..d827b5b57 100644 --- a/mod/content.php +++ b/mod/content.php @@ -584,6 +584,8 @@ function render_content(&$a, $items, $mode, $update, $preview = false) { if (!$comments_collapsed){ $threads[$threadsid]['num_comments'] = sprintf( tt('%d comment','%d comments',$comments[$item['parent']]),$comments[$item['parent']] ); + $threads[$threadsid]['hidden_comments_num'] = $comments[$item['parent']]; + $threads[$threadsid]['hidden_comments_text'] = tt('comment', 'comments', $comments[$item['parent']]); $threads[$threadsid]['hide_text'] = t('show more'); $comments_collapsed = true; $comment_firstcollapsed = true; diff --git a/mod/editpost.php b/mod/editpost.php index b44afe245..03d5263a1 100644 --- a/mod/editpost.php +++ b/mod/editpost.php @@ -133,6 +133,7 @@ function editpost_content(&$a) { '$preview' => t('Preview'), '$jotplugins' => $jotplugins, '$sourceapp' => t($a->sourcename), + '$cancel' => t('Cancel') )); return $o; diff --git a/mod/events.php b/mod/events.php index c448dc0f2..527e1ec3f 100755 --- a/mod/events.php +++ b/mod/events.php @@ -141,6 +141,20 @@ function events_content(&$a) { return; } + if(($a->argc > 2) && ($a->argv[1] === 'ignore') && intval($a->argv[2])) { + $r = q("update event set ignore = 1 where id = %d and uid = %d limit 1", + intval($a->argv[2]), + intval(local_user()) + ); + } + + if(($a->argc > 2) && ($a->argv[1] === 'unignore') && intval($a->argv[2])) { + $r = q("update event set ignore = 0 where id = %d and uid = %d limit 1", + intval($a->argv[2]), + intval(local_user()) + ); + } + $htpl = get_markup_template('event_head.tpl'); $a->page['htmlhead'] .= replace_macros($htpl,array('$baseurl' => $a->get_baseurl())); @@ -157,6 +171,7 @@ function events_content(&$a) { $mode = 'view'; $y = 0; $m = 0; + $ignored = ((x($_REQUEST,'ignored')) ? intval($_REQUEST['ignored']) : 0); if($a->argc > 1) { if($a->argc > 2 && $a->argv[1] == 'event') { @@ -234,10 +249,11 @@ function events_content(&$a) { } else { $r = q("SELECT `event`.*, `item`.`id` AS `itemid`,`item`.`plink`, `item`.`author-name`, `item`.`author-avatar`, `item`.`author-link` FROM `event` LEFT JOIN `item` ON `item`.`event-id` = `event`.`id` - WHERE `event`.`uid` = %d + WHERE `event`.`uid` = %d and event.ignore = %d AND (( `adjust` = 0 AND `finish` >= '%s' AND `start` <= '%s' ) OR ( `adjust` = 1 AND `finish` >= '%s' AND `start` <= '%s' )) ", intval(local_user()), + intval($ignored), dbesc($start), dbesc($finish), dbesc($adjust_start), diff --git a/mod/fbrowser.php b/mod/fbrowser.php index 3f034226e..5ee813b4d 100644 --- a/mod/fbrowser.php +++ b/mod/fbrowser.php @@ -46,7 +46,7 @@ function fbrowser_content($a){ } $r = q("SELECT `resource-id`, `id`, `filename`, type, min(`scale`) AS `hiq`,max(`scale`) AS `loq`, `desc` - FROM `photo` WHERE `uid` = %d $sql_extra + FROM `photo` WHERE `uid` = %d AND (height <= 320 AND width <= 320) $sql_extra GROUP BY `resource-id` $sql_extra2", intval(local_user()) ); diff --git a/mod/item.php b/mod/item.php index 52ea9d58c..7d36d7f70 100644 --- a/mod/item.php +++ b/mod/item.php @@ -373,8 +373,8 @@ function item_post(&$a) { $match = null; - if((! $preview) && preg_match_all("/\[img\](.*?)\[\/img\]/",$body,$match)) { - $images = $match[1]; + if((! $preview) && preg_match_all("/\[img([\=0-9x]*?)\](.*?)\[\/img\]/",$body,$match)) { + $images = $match[2]; if(count($images)) { foreach($images as $image) { if(! stristr($image,$a->get_baseurl() . '/photo/')) diff --git a/mod/network.php b/mod/network.php index 97f00eeda..d77a64412 100644 --- a/mod/network.php +++ b/mod/network.php @@ -471,7 +471,7 @@ function network_content(&$a, $update = 0) { } } - if((! $group) && (! $cid) && (! $update)) { + if((! $group) && (! $cid) && (! $update) && (! get_config('theme','hide_eventlist'))) { $o .= get_birthdays(); $o .= get_events(); } diff --git a/mod/newmember.php b/mod/newmember.php index e17a0db03..8028e7e08 100644 --- a/mod/newmember.php +++ b/mod/newmember.php @@ -69,7 +69,7 @@ function newmember_content(&$a) { $o .= '
  • ' . '' . t('Group Your Contacts') . '
    ' . t('Once you have made some friends, organize them into private conversation groups from the sidebar of your Contacts page and then you can interact with each group privately on your Network page.') . '
  • ' . EOL; - if(! get_config('system', 'newuser_public')) { + if(get_config('system', 'newuser_private')) { $o .= '
  • ' . '' . t("Why Aren't My Posts Public?") . '
    ' . t("Friendica respects your privacy. By default, your posts will only show up to people you've added as friends. For more information, see the help section from the link above.") . '
  • ' . EOL; } diff --git a/mod/parse_url.php b/mod/parse_url.php index 083a39b55..9adee8f65 100644 --- a/mod/parse_url.php +++ b/mod/parse_url.php @@ -307,16 +307,26 @@ function parse_url_content(&$a) { $image = ""; - if(sizeof($siteinfo["images"]) > 0){ - /* - Execute below code only if image is present in siteinfo - */ - foreach ($siteinfo["images"] as $imagedata) - if($textmode) - $image .= '[img='.$imagedata["width"].'x'.$imagedata["height"].']'.$imagedata["src"].'[/img]'; + if(sizeof($siteinfo["images"]) > 0){ + /* Execute below code only if image is present in siteinfo */ + + $total_images = 0; + $max_images = get_config('system','max_bookmark_images'); + if($max_images === false) + $max_images = 2; else - $image .= 'photo'; + $max_images = intval($max_images); + + foreach ($siteinfo["images"] as $imagedata) { + if($textmode) + $image .= '[img='.$imagedata["width"].'x'.$imagedata["height"].']'.$imagedata["src"].'[/img]' . "\n"; + else + $image .= 'photo
    '; + $total_images ++; + if($max_images && $max_images >= $total_images) + break; } + } if(strlen($text)) { if($textmode) diff --git a/mod/ping.php b/mod/ping.php index 55dcb26bb..2698956d7 100644 --- a/mod/ping.php +++ b/mod/ping.php @@ -55,6 +55,7 @@ function ping_init(&$a) { $dislikes = array(); $friends = array(); $posts = array(); + $home = 0; $network = 0; @@ -140,6 +141,48 @@ function ping_init(&$a) { $register = "0"; } + $all_events = 0; + $all_events_today = 0; + $events = 0; + $events_today = 0; + $birthdays = 0; + $birthdays_today = 0; + + + $ev = q("SELECT count(`event`.`id`) as total, type, start, adjust FROM `event` + WHERE `event`.`uid` = %d AND `start` < '%s' AND `finish` > '%s' and `ignore` = 0 + ORDER BY `start` ASC ", + intval(local_user()), + dbesc(datetime_convert('UTC','UTC','now + 7 days')), + dbesc(datetime_convert('UTC','UTC','now')) + ); + + if($ev && count($ev)) { + $all_events = intval($ev[0]['total']); + + if($all_events) { + $str_now = datetime_convert('UTC',$a->timezone,'now','Y-m-d'); + foreach($ev as $x) { + $bd = false; + if($x['type'] === 'birthday') { + $birthdays ++; + $bd = true; + } + else { + $events ++; + } + if(datetime_convert('UTC',((intval($x['adjust'])) ? $a->timezone : 'UTC'), $x['start'],'Y-m-d') === $str_now) { + $all_events_today ++; + if($bd) + $birthdays_today ++; + else + $events_today ++; + } + } + } + } + + function xmlize($href, $name, $url, $photo, $date, $seen, $message){ $data = array('href' => &$href, 'name' => &$name, 'url'=>&$url, 'photo'=>&$photo, 'date'=>&$date, 'seen'=>&$seen, 'messsage'=>&$message); @@ -153,8 +196,15 @@ function ping_init(&$a) { echo "$intro $mail $network - $home"; + $home\r\n"; if ($register!=0) echo "$register"; + + echo "$all_events + $all_events_today + $events + $events_today + $birthdays + $birthdays_today\r\n"; $tot = $mail+$intro+$register+count($comments)+count($likes)+count($dislikes)+count($friends)+count($posts)+count($tags); diff --git a/mod/profile.php b/mod/profile.php index a4dce7918..b33b181de 100644 --- a/mod/profile.php +++ b/mod/profile.php @@ -304,7 +304,7 @@ function profile_content(&$a, $update = 0) { $items = array(); } - if($is_owner && ! $update) { + if($is_owner && (! $update) && (! get_config('theme','hide_eventlist'))) { $o .= get_birthdays(); $o .= get_events(); } diff --git a/mod/profile_photo.php b/mod/profile_photo.php index 378353f65..d1f77a3db 100644 --- a/mod/profile_photo.php +++ b/mod/profile_photo.php @@ -24,6 +24,20 @@ function profile_photo_post(&$a) { if((x($_POST,'cropfinal')) && ($_POST['cropfinal'] == 1)) { + // unless proven otherwise + $is_default_profile = 1; + + if($_REQUEST['profile']) { + $r = q("select id, `is-default` from profile where id = %d and uid = %d limit 1", + intval($_REQUEST['profile']), + intval(local_user()) + ); + if(count($r) && (! intval($r[0]['is-default']))) + $is_default_profile = 0; + } + + + // phase 2 - we have finished cropping if($a->argc != 2) { @@ -57,31 +71,44 @@ function profile_photo_post(&$a) { if($im->is_valid()) { $im->cropImage(175,$srcX,$srcY,$srcW,$srcH); - $r = $im->store(local_user(), 0, $base_image['resource-id'],$base_image['filename'], t('Profile Photos'), 4, 1); + $r = $im->store(local_user(), 0, $base_image['resource-id'],$base_image['filename'], t('Profile Photos'), 4, $is_default_profile); if($r === false) notice ( sprintf(t('Image size reduction [%s] failed.'),"175") . EOL ); $im->scaleImage(80); - $r = $im->store(local_user(), 0, $base_image['resource-id'],$base_image['filename'], t('Profile Photos'), 5, 1); + $r = $im->store(local_user(), 0, $base_image['resource-id'],$base_image['filename'], t('Profile Photos'), 5, $is_default_profile); if($r === false) notice( sprintf(t('Image size reduction [%s] failed.'),"80") . EOL ); $im->scaleImage(48); - $r = $im->store(local_user(), 0, $base_image['resource-id'],$base_image['filename'], t('Profile Photos'), 6, 1); + $r = $im->store(local_user(), 0, $base_image['resource-id'],$base_image['filename'], t('Profile Photos'), 6, $is_default_profile); if($r === false) notice( sprintf(t('Image size reduction [%s] failed.'),"48") . EOL ); - // Unset the profile photo flag from any other photos I own + // If setting for the default profile, unset the profile photo flag from any other photos I own - $r = q("UPDATE `photo` SET `profile` = 0 WHERE `profile` = 1 AND `resource-id` != '%s' AND `uid` = %d", - dbesc($base_image['resource-id']), - intval(local_user()) - ); + if($is_default_profile) { + $r = q("UPDATE `photo` SET `profile` = 0 WHERE `profile` = 1 AND `resource-id` != '%s' AND `uid` = %d", + dbesc($base_image['resource-id']), + intval(local_user()) + ); + } + else { + $r = q("update profile set photo = '%s', thumb = '%s' where id = %d and uid = %d limit 1", + dbesc($a->get_baseurl() . '/photo/' . $base_image['resource-id'] . '-4'), + dbesc($a->get_baseurl() . '/photo/' . $base_image['resource-id'] . '-5'), + intval($_REQUEST['profile']), + intval(local_user()) + ); + } + + // we'll set the updated profile-photo timestamp even if it isn't the default profile, + // so that browsers will do a cache update unconditionally $r = q("UPDATE `contact` SET `avatar-date` = '%s' WHERE `self` = 1 AND `uid` = %d LIMIT 1", dbesc(datetime_convert()), @@ -201,6 +228,11 @@ function profile_photo_content(&$a) { // go ahead as we have jus uploaded a new photo to crop } + $profiles = q("select `id`,`profile-name` as `name`,`is-default` as `default` from profile where uid = %d", + intval(local_user()) + ); + + if(! x($a->config,'imagecrop')) { $tpl = get_markup_template('profile_photo.tpl'); @@ -208,8 +240,10 @@ function profile_photo_content(&$a) { $o .= replace_macros($tpl,array( '$user' => $a->user['nickname'], '$lbl_upfile' => t('Upload File:'), + '$lbl_profiles' => t('Select a profile:'), '$title' => t('Upload Profile Photo'), '$submit' => t('Upload'), + '$profiles' => $profiles, '$form_security_token' => get_form_security_token("profile_photo"), '$select' => sprintf('%s %s', t('or'), ($newuser) ? '' . t('skip this step') . '' : '' . t('select a photo from your photo albums') . '') )); @@ -222,6 +256,7 @@ function profile_photo_content(&$a) { $tpl = get_markup_template("cropbody.tpl"); $o .= replace_macros($tpl,array( '$filename' => $filename, + '$profile' => intval($_REQUEST['profile']), '$resource' => $a->config['imagecrop'] . '-' . $a->config['imagecrop_resolution'], '$image_url' => $a->get_baseurl() . '/photo/' . $filename, '$title' => t('Crop Image'), @@ -236,7 +271,7 @@ function profile_photo_content(&$a) { }} -if(! function_exists('_crop_ui_head')) { +if(! function_exists('profile_photo_crop_ui_head')) { function profile_photo_crop_ui_head(&$a, $ph){ $max_length = get_config('system','max_image_length'); if(! $max_length) diff --git a/mod/toggle_mobile.php b/mod/toggle_mobile.php new file mode 100644 index 000000000..00991e44c --- /dev/null +++ b/mod/toggle_mobile.php @@ -0,0 +1,17 @@ +get_baseurl(); + + goaway($address); +} + diff --git a/object/BaseObject.php b/object/BaseObject.php new file mode 100644 index 000000000..14f0d8fd0 --- /dev/null +++ b/object/BaseObject.php @@ -0,0 +1,37 @@ + diff --git a/object/Conversation.php b/object/Conversation.php new file mode 100644 index 000000000..8b838f7d0 --- /dev/null +++ b/object/Conversation.php @@ -0,0 +1,162 @@ +set_mode($mode); + $this->preview = $preview; + } + + /** + * Set the mode we'll be displayed on + */ + private function set_mode($mode) { + if($this->get_mode() == $mode) + return; + + $a = $this->get_app(); + + switch($mode) { + case 'network': + case 'notes': + $this->profile_owner = local_user(); + $this->writable = true; + break; + case 'profile': + $this->profile_owner = $a->profile['profile_uid']; + $this->writable = can_write_wall($a,$this->profile_owner); + break; + case 'display': + $this->profile_owner = $a->profile['uid']; + $this->writable = can_write_wall($a,$this->profile_owner); + break; + default: + logger('[ERROR] Conversation::set_mode : Unhandled mode ('. $mode .').', LOGGER_DEBUG); + return false; + break; + } + $this->mode = $mode; + } + + /** + * Get mode + */ + public function get_mode() { + return $this->mode; + } + + /** + * Check if page is writable + */ + public function is_writable() { + return $this->writable; + } + + /** + * Check if page is a preview + */ + public function is_preview() { + return $this->preview; + } + + /** + * Get profile owner + */ + public function get_profile_owner() { + return $this->profile_owner; + } + + /** + * Add a thread to the conversation + * + * Returns: + * _ The inserted item on success + * _ false on failure + */ + public function add_thread($item) { + $item_id = $item->get_id(); + if(!$item_id) { + logger('[ERROR] Conversation::add_thread : Item has no ID!!', LOGGER_DEBUG); + return false; + } + if($this->get_thread($item->get_id())) { + logger('[WARN] Conversation::add_thread : Thread already exists ('. $item->get_id() .').', LOGGER_DEBUG); + return false; + } + + /* + * Only add will be displayed + */ + if($item->get_data_value('network') === NETWORK_MAIL && local_user() != $item->get_data_value('uid')) { + logger('[WARN] Conversation::add_thread : Thread is a mail ('. $item->get_id() .').', LOGGER_DEBUG); + return false; + } + if($item->get_data_value('verb') === ACTIVITY_LIKE || $item->get_data_value('verb') === ACTIVITY_DISLIKE) { + logger('[WARN] Conversation::add_thread : Thread is a (dis)like ('. $item->get_id() .').', LOGGER_DEBUG); + return false; + } + $item->set_conversation($this); + $this->threads[] = $item; + return end($this->threads); + } + + /** + * Get data in a form usable by a conversation template + * + * We should find a way to avoid using those arguments (at least most of them) + * + * Returns: + * _ The data requested on success + * _ false on failure + */ + public function get_template_data($alike, $dlike) { + $result = array(); + + foreach($this->threads as $item) { + if($item->get_data_value('network') === NETWORK_MAIL && local_user() != $item->get_data_value('uid')) + continue; + $item_data = $item->get_template_data($alike, $dlike); + if(!$item_data) { + logger('[ERROR] Conversation::get_template_data : Failed to get item template data ('. $item->get_id() .').', LOGGER_DEBUG); + return false; + } + $result[] = $item_data; + } + + return $result; + } + + /** + * Get a thread based on its item id + * + * Returns: + * _ The found item on success + * _ false on failure + */ + private function get_thread($id) { + foreach($this->threads as $item) { + if($item->get_id() == $id) + return $item; + } + + return false; + } +} +?> diff --git a/object/Item.php b/object/Item.php new file mode 100644 index 000000000..d40a384f5 --- /dev/null +++ b/object/Item.php @@ -0,0 +1,640 @@ + 'wall_thread.tpl', + 'wall2wall' => 'wallwall_thread.tpl' + ); + private $comment_box_template = 'comment_item.tpl'; + private $toplevel = false; + private $writable = false; + private $children = array(); + private $parent = null; + private $conversation = null; + private $redirect_url = null; + private $owner_url = ''; + private $owner_photo = ''; + private $owner_name = ''; + private $wall_to_wall = false; + private $threaded = false; + private $visiting = false; + + public function __construct($data) { + $a = $this->get_app(); + + $this->data = $data; + $this->set_template('wall'); + $this->toplevel = ($this->get_id() == $this->get_data_value('parent')); + + if(is_array($_SESSION['remote'])) { + foreach($_SESSION['remote'] as $visitor) { + if($visitor['cid'] == $this->get_data_value('contact-id')) { + $this->visiting = true; + break; + } + } + } + + $this->writable = ($this->get_data_value('writable') || $this->get_data_value('self')); + + $ssl_state = ((local_user()) ? true : false); + $this->redirect_url = $a->get_baseurl($ssl_state) . '/redir/' . $this->get_data_value('cid') ; + + if(get_config('system','thread_allow') && $a->theme_thread_allow && !$this->is_toplevel()) + $this->threaded = true; + + // Prepare the children + if(count($data['children'])) { + foreach($data['children'] as $item) { + /* + * Only add will be displayed + */ + if($item['network'] === NETWORK_MAIL && local_user() != $item['uid']) { + continue; + } + if($item['verb'] === ACTIVITY_LIKE || $item['verb'] === ACTIVITY_DISLIKE) { + continue; + } + $child = new Item($item); + $this->add_child($child); + } + } + } + + /** + * Get data in a form usable by a conversation template + * + * Returns: + * _ The data requested on success + * _ false on failure + */ + public function get_template_data($alike, $dlike, $thread_level=1) { + $result = array(); + + $a = $this->get_app(); + + $item = $this->get_data(); + + $commentww = ''; + $sparkle = ''; + $buttons = ''; + $dropping = false; + $star = false; + $isstarred = "unstarred"; + $indent = ''; + $osparkle = ''; + $total_children = $this->count_descendants(); + + $conv = $this->get_conversation(); + + $lock = ((($item['private'] == 1) || (($item['uid'] == local_user()) && (strlen($item['allow_cid']) || strlen($item['allow_gid']) + || strlen($item['deny_cid']) || strlen($item['deny_gid'])))) + ? t('Private Message') + : false); + $shareable = ((($conv->get_profile_owner() == local_user()) && ($item['private'] != 1)) ? true : false); + if(local_user() && link_compare($a->contact['url'],$item['author-link'])) + $edpost = array($a->get_baseurl($ssl_state)."/editpost/".$item['id'], t("Edit")); + else + $edpost = false; + if(($this->get_data_value('uid') == local_user()) || $this->is_visiting()) + $dropping = true; + + $drop = array( + 'dropping' => $dropping, + 'select' => t('Select'), + 'delete' => t('Delete'), + ); + + $filer = (($conv->get_profile_owner() == local_user()) ? t("save to folder") : false); + + $diff_author = ((link_compare($item['url'],$item['author-link'])) ? false : true); + $profile_name = (((strlen($item['author-name'])) && $diff_author) ? $item['author-name'] : $item['name']); + if($item['author-link'] && (! $item['author-name'])) + $profile_name = $item['author-link']; + + $sp = false; + $profile_link = best_link_url($item,$sp); + if($profile_link === 'mailbox') + $profile_link = ''; + if($sp) + $sparkle = ' sparkle'; + else + $profile_link = zrl($profile_link); + + $normalised = normalise_link((strlen($item['author-link'])) ? $item['author-link'] : $item['url']); + if(($normalised != 'mailbox') && (x($a->contacts,$normalised))) + $profile_avatar = $a->contacts[$normalised]['thumb']; + else + $profile_avatar = (((strlen($item['author-avatar'])) && $diff_author) ? $item['author-avatar'] : $a->get_cached_avatar_image($this->get_data_value('thumb'))); + + $locate = array('location' => $item['location'], 'coord' => $item['coord'], 'html' => ''); + call_hooks('render_location',$locate); + $location = ((strlen($locate['html'])) ? $locate['html'] : render_location_google($locate)); + + $tags=array(); + foreach(explode(',',$item['tag']) as $tag){ + $tag = trim($tag); + if ($tag!="") $tags[] = bbcode($tag); + } + + $like = ((x($alike,$item['uri'])) ? format_like($alike[$item['uri']],$alike[$item['uri'] . '-l'],'like',$item['uri']) : ''); + $dislike = ((x($dlike,$item['uri'])) ? format_like($dlike[$item['uri']],$dlike[$item['uri'] . '-l'],'dislike',$item['uri']) : ''); + + /* + * We should avoid doing this all the time, but it depends on the conversation mode + * And the conv mode may change when we change the conv, or it changes its mode + * Maybe we should establish a way to be notified about conversation changes + */ + $this->check_wall_to_wall(); + + if($this->is_wall_to_wall() && ($this->get_owner_url() == $this->get_redirect_url())) + $osparkle = ' sparkle'; + + if($this->is_toplevel()) { + if($conv->get_profile_owner() == local_user()) { + $isstarred = (($item['starred']) ? "starred" : "unstarred"); + + $star = array( + 'do' => t("add star"), + 'undo' => t("remove star"), + 'toggle' => t("toggle star status"), + 'classdo' => (($item['starred']) ? "hidden" : ""), + 'classundo' => (($item['starred']) ? "" : "hidden"), + 'starred' => t('starred'), + 'tagger' => t("add tag"), + 'classtagger' => "", + ); + } + } else { + $indent = 'comment'; + } + + if($conv->is_writable()) { + $buttons = array( + 'like' => array( t("I like this \x28toggle\x29"), t("like")), + 'dislike' => array( t("I don't like this \x28toggle\x29"), t("dislike")), + ); + if ($shareable) $buttons['share'] = array( t('Share this'), t('share')); + } + + if(strcmp(datetime_convert('UTC','UTC',$item['created']),datetime_convert('UTC','UTC','now - 12 hours')) > 0) + $indent .= ' shiny'; + + localize_item($item); + + $body = prepare_body($item,true); + + $tmp_item = array( + 'template' => $this->get_template(), + + 'type' => implode("",array_slice(explode("/",$item['verb']),-1)), + 'tags' => $tags, + 'body' => template_escape($body), + 'text' => strip_tags(template_escape($body)), + 'id' => $this->get_id(), + 'linktitle' => sprintf( t('View %s\'s profile @ %s'), $profile_name, ((strlen($item['author-link'])) ? $item['author-link'] : $item['url'])), + 'olinktitle' => sprintf( t('View %s\'s profile @ %s'), $this->get_owner_name(), ((strlen($item['owner-link'])) ? $item['owner-link'] : $item['url'])), + 'to' => t('to'), + 'wall' => t('Wall-to-Wall'), + 'vwall' => t('via Wall-To-Wall:'), + 'profile_url' => $profile_link, + 'item_photo_menu' => item_photo_menu($item), + 'name' => template_escape($profile_name), + 'thumb' => $profile_avatar, + 'osparkle' => $osparkle, + 'sparkle' => $sparkle, + 'title' => template_escape($item['title']), + 'localtime' => datetime_convert('UTC', date_default_timezone_get(), $item['created'], 'r'), + 'ago' => (($item['app']) ? sprintf( t('%s from %s'),relative_date($item['created']),$item['app']) : relative_date($item['created'])), + 'lock' => $lock, + 'location' => template_escape($location), + 'indent' => $indent, + 'owner_url' => $this->get_owner_url(), + 'owner_photo' => $this->get_owner_photo(), + 'owner_name' => template_escape($this->get_owner_name()), + 'plink' => get_plink($item), + 'edpost' => $edpost, + 'isstarred' => $isstarred, + 'star' => $star, + 'filer' => $filer, + 'drop' => $drop, + 'vote' => $buttons, + 'like' => $like, + 'dislike' => $dislike, + 'comment' => $this->get_comment_box($indent), + 'previewing' => ($conv->is_preview() ? ' preview ' : ''), + 'wait' => t('Please wait'), + 'thread_level' => $thread_level + ); + + $arr = array('item' => $item, 'output' => $tmp_item); + call_hooks('display_item', $arr); + + $result = $arr['output']; + + $result['children'] = array(); + $children = $this->get_children(); + $nb_children = count($children); + if($nb_children > 0) { + foreach($children as $child) { + $result['children'][] = $child->get_template_data($alike, $dlike, $thread_level + 1); + } + // Collapse + if(($nb_children > 2) || ($thread_level > 1)) { + $result['children'][0]['comment_firstcollapsed'] = true; + $result['children'][0]['num_comments'] = sprintf( tt('%d comment','%d comments',$total_children),$total_children ); + $result['children'][0]['hidden_comments_num'] = $total_children; + $result['children'][0]['hidden_comments_text'] = tt('comment', 'comments', $total_children); + $result['children'][0]['hide_text'] = t('show more'); + if($thread_level > 1) { + $result['children'][$nb_children - 1]['comment_lastcollapsed'] = true; + } + else { + $result['children'][$nb_children - 3]['comment_lastcollapsed'] = true; + } + } + } + + $result['private'] = $item['private']; + $result['toplevel'] = ($this->is_toplevel() ? 'toplevel_item' : ''); + + if($this->is_threaded()) { + $result['flatten'] = false; + $result['threaded'] = true; + } + else { + $result['flatten'] = true; + $result['threaded'] = false; + } + + return $result; + } + + public function get_id() { + return $this->get_data_value('id'); + } + + public function is_threaded() { + return $this->threaded; + } + + /** + * Add a child item + */ + public function add_child($item) { + $item_id = $item->get_id(); + if(!$item_id) { + logger('[ERROR] Item::add_child : Item has no ID!!', LOGGER_DEBUG); + return false; + } + if($this->get_child($item->get_id())) { + logger('[WARN] Item::add_child : Item already exists ('. $item->get_id() .').', LOGGER_DEBUG); + return false; + } + /* + * Only add what will be displayed + */ + if($item->get_data_value('network') === NETWORK_MAIL && local_user() != $item->get_data_value('uid')) { + logger('[WARN] Item::add_child : Item is a mail ('. $item->get_id() .').', LOGGER_DEBUG); + return false; + } + if($item->get_data_value('verb') === ACTIVITY_LIKE || $item->get_data_value('verb') === ACTIVITY_DISLIKE) { + logger('[WARN] Item::add_child : Item is a (dis)like ('. $item->get_id() .').', LOGGER_DEBUG); + return false; + } + + $item->set_parent($this); + $this->children[] = $item; + return end($this->children); + } + + /** + * Get a child by its ID + */ + public function get_child($id) { + foreach($this->get_children() as $child) { + if($child->get_id() == $id) + return $child; + } + return null; + } + + /** + * Get all ou children + */ + public function get_children() { + return $this->children; + } + + /** + * Set our parent + */ + protected function set_parent($item) { + $parent = $this->get_parent(); + if($parent) { + $parent->remove_child($this); + } + $this->parent = $item; + $this->set_conversation($item->get_conversation()); + } + + /** + * Remove our parent + */ + protected function remove_parent() { + $this->parent = null; + $this->conversation = null; + } + + /** + * Remove a child + */ + public function remove_child($item) { + $id = $item->get_id(); + foreach($this->get_children() as $key => $child) { + if($child->get_id() == $id) { + $child->remove_parent(); + unset($this->children[$key]); + // Reindex the array, in order to make sure there won't be any trouble on loops using count() + $this->children = array_values($this->children); + return true; + } + } + logger('[WARN] Item::remove_child : Item is not a child ('. $id .').', LOGGER_DEBUG); + return false; + } + + /** + * Get parent item + */ + protected function get_parent() { + return $this->parent; + } + + /** + * set conversation + */ + public function set_conversation($conv) { + $previous_mode = ($this->conversation ? $this->conversation->get_mode() : ''); + + $this->conversation = $conv; + + // Set it on our children too + foreach($this->get_children() as $child) + $child->set_conversation($conv); + } + + /** + * get conversation + */ + public function get_conversation() { + return $this->conversation; + } + + /** + * Get raw data + * + * We shouldn't need this + */ + public function get_data() { + return $this->data; + } + + /** + * Get a data value + * + * Returns: + * _ value on success + * _ false on failure + */ + public function get_data_value($name) { + if(!isset($this->data[$name])) { + logger('[ERROR] Item::get_data_value : Item has no value name "'. $name .'".', LOGGER_DEBUG); + return false; + } + + return $this->data[$name]; + } + + /** + * Set template + */ + private function set_template($name) { + if(!x($this->available_templates, $name)) { + logger('[ERROR] Item::set_template : Template not available ("'. $name .'").', LOGGER_DEBUG); + return false; + } + $this->template = $this->available_templates[$name]; + } + + /** + * Get template + */ + private function get_template() { + return $this->template; + } + + /** + * Check if this is a toplevel post + */ + private function is_toplevel() { + return $this->toplevel; + } + + /** + * Check if this is writable + */ + private function is_writable() { + $conv = $this->get_conversation(); + + if($conv) { + // This will allow us to comment on wall-to-wall items owned by our friends + // and community forums even if somebody else wrote the post. + return ($this->writable || ($this->is_visiting() && $conv->get_mode() == 'profile')); + } + return $this->writable; + } + + /** + * Count the total of our descendants + */ + private function count_descendants() { + $children = $this->get_children(); + $total = count($children); + if($total > 0) { + foreach($children as $child) { + $total += $child->count_descendants(); + } + } + return $total; + } + + /** + * Get the template for the comment box + */ + private function get_comment_box_template() { + return $this->comment_box_template; + } + + /** + * Get the comment box + * + * Returns: + * _ The comment box string (empty if no comment box) + * _ false on failure + */ + private function get_comment_box($indent) { + if(!$this->is_toplevel() && !get_config('system','thread_allow')) { + return ''; + } + + $comment_box = ''; + $conv = $this->get_conversation(); + $template = get_markup_template($this->get_comment_box_template()); + $ww = ''; + if( ($conv->get_mode() === 'network') && $this->is_wall_to_wall() ) + $ww = 'ww'; + + if($conv->is_writable() && $this->is_writable()) { + $a = $this->get_app(); + $qc = $qcomment = null; + + /* + * Hmmm, code depending on the presence of a particular plugin? + * This should be better if done by a hook + */ + if(in_array('qcomment',$a->plugins)) { + $qc = ((local_user()) ? get_pconfig(local_user(),'qcomment','words') : null); + $qcomment = (($qc) ? explode("\n",$qc) : null); + } + $comment_box = replace_macros($template,array( + '$return_path' => '', + '$threaded' => $this->is_threaded(), + '$jsreload' => (($conv->get_mode() === 'display') ? $_SESSION['return_url'] : ''), + '$type' => (($conv->get_mode() === 'profile') ? 'wall-comment' : 'net-comment'), + '$id' => $this->get_id(), + '$parent' => $this->get_id(), + '$qcomment' => $qcomment, + '$profile_uid' => $conv->get_profile_owner(), + '$mylink' => $a->contact['url'], + '$mytitle' => t('This is you'), + '$myphoto' => $a->contact['thumb'], + '$comment' => t('Comment'), + '$submit' => t('Submit'), + '$edbold' => t('Bold'), + '$editalic' => t('Italic'), + '$eduline' => t('Underline'), + '$edquote' => t('Quote'), + '$edcode' => t('Code'), + '$edimg' => t('Image'), + '$edurl' => t('Link'), + '$edvideo' => t('Video'), + '$preview' => t('Preview'), + '$indent' => $indent, + '$sourceapp' => t($a->sourcename), + '$ww' => (($conv->get_mode() === 'network') ? $ww : '') + )); + } + + return $comment_box; + } + + private function get_redirect_url() { + return $this->redirect_url; + } + + /** + * Check if we are a wall to wall item and set the relevant properties + */ + protected function check_wall_to_wall() { + $a = $this->get_app(); + $conv = $this->get_conversation(); + $this->wall_to_wall = false; + + if($this->is_toplevel()) { + if( (! $this->get_data_value('self')) && ($conv->get_mode() !== 'profile')) { + if($this->get_data_value('wall')) { + + // On the network page, I am the owner. On the display page it will be the profile owner. + // This will have been stored in $a->page_contact by our calling page. + // Put this person as the wall owner of the wall-to-wall notice. + + $this->owner_url = zrl($a->page_contact['url']); + $this->owner_photo = $a->page_contact['thumb']; + $this->owner_name = $a->page_contact['name']; + $this->set_template('wall2wall'); + $this->wall_to_wall = true; + } + else if($this->get_data_value('owner-link')) { + + $owner_linkmatch = (($this->get_data_value('owner-link')) && link_compare($this->get_data_value('owner-link'),$this->get_data_value('author-link'))); + $alias_linkmatch = (($this->get_data_value('alias')) && link_compare($this->get_data_value('alias'),$this->get_data_value('author-link'))); + $owner_namematch = (($this->get_data_value('owner-name')) && $this->get_data_value('owner-name') == $this->get_data_value('author-name')); + if((! $owner_linkmatch) && (! $alias_linkmatch) && (! $owner_namematch)) { + + // The author url doesn't match the owner (typically the contact) + // and also doesn't match the contact alias. + // The name match is a hack to catch several weird cases where URLs are + // all over the park. It can be tricked, but this prevents you from + // seeing "Bob Smith to Bob Smith via Wall-to-wall" and you know darn + // well that it's the same Bob Smith. + + // But it could be somebody else with the same name. It just isn't highly likely. + + + $this->owner_photo = $this->get_data_value('owner-avatar'); + $this->owner_name = $this->get_data_value('owner-name'); + $this->set_template('wall2wall'); + $this->wall_to_wall = true; + // If it is our contact, use a friendly redirect link + if((link_compare($this->get_data_value('owner-link'),$this->get_data_value('url'))) + && ($this->get_data_value('network') === NETWORK_DFRN)) { + $this->owner_url = $this->get_redirect_url(); + } + else + $this->owner_url = zrl($this->get_data_value('owner-link')); + } + } + } + } + + if(!$this->wall_to_wall) { + $this->set_template('wall'); + $this->owner_url = ''; + $this->owner_photo = ''; + $this->owner_name = ''; + } + } + + private function is_wall_to_wall() { + return $this->wall_to_wall; + } + + private function get_owner_url() { + return $this->owner_url; + } + + private function get_owner_photo() { + return $this->owner_photo; + } + + private function get_owner_name() { + return $this->owner_name; + } + + private function is_visiting() { + return $this->visiting; + } +} +?> diff --git a/update.php b/update.php index 19e6cf3bd..3d3eec6f9 100644 --- a/update.php +++ b/update.php @@ -1,6 +1,6 @@ \n" "Language-Team: LANGUAGE \n" @@ -47,8 +47,8 @@ msgstr "" #: ../../mod/group.php:19 ../../mod/viewcontacts.php:22 #: ../../mod/register.php:38 ../../mod/regmod.php:116 ../../mod/item.php:126 #: ../../mod/item.php:142 ../../mod/mood.php:114 -#: ../../mod/profile_photo.php:19 ../../mod/profile_photo.php:142 -#: ../../mod/profile_photo.php:153 ../../mod/profile_photo.php:166 +#: ../../mod/profile_photo.php:19 ../../mod/profile_photo.php:169 +#: ../../mod/profile_photo.php:180 ../../mod/profile_photo.php:193 #: ../../mod/message.php:38 ../../mod/message.php:168 #: ../../mod/allfriends.php:9 ../../mod/nogroup.php:25 #: ../../mod/wall_upload.php:64 ../../mod/follow.php:9 @@ -56,9 +56,10 @@ msgstr "" #: ../../mod/profiles.php:413 ../../mod/delegate.php:6 #: ../../mod/suggest.php:28 ../../mod/invite.php:13 ../../mod/invite.php:81 #: ../../mod/dfrn_confirm.php:53 ../../addon/facebook/facebook.php:510 -#: ../../addon/facebook/facebook.php:516 -#: ../../addon/dav/friendica/layout.fnk.php:354 ../../include/items.php:3834 -#: ../../index.php:315 +#: ../../addon/facebook/facebook.php:516 ../../addon/fbpost/fbpost.php:159 +#: ../../addon/fbpost/fbpost.php:165 +#: ../../addon/dav/friendica/layout.fnk.php:354 ../../include/items.php:3908 +#: ../../index.php:317 msgid "Permission denied." msgstr "" @@ -88,7 +89,7 @@ msgid "Return to contact editor" msgstr "" #: ../../mod/crepair.php:148 ../../mod/settings.php:545 -#: ../../mod/settings.php:571 ../../mod/admin.php:690 ../../mod/admin.php:699 +#: ../../mod/settings.php:571 ../../mod/admin.php:692 ../../mod/admin.php:702 msgid "Name" msgstr "" @@ -125,7 +126,7 @@ msgid "New photo from this URL" msgstr "" #: ../../mod/crepair.php:166 ../../mod/fsuggest.php:107 -#: ../../mod/events.php:439 ../../mod/photos.php:1005 +#: ../../mod/events.php:455 ../../mod/photos.php:1005 #: ../../mod/photos.php:1081 ../../mod/photos.php:1338 #: ../../mod/photos.php:1378 ../../mod/photos.php:1419 #: ../../mod/photos.php:1451 ../../mod/install.php:246 @@ -134,21 +135,21 @@ msgstr "" #: ../../mod/settings.php:543 ../../mod/settings.php:697 #: ../../mod/settings.php:769 ../../mod/settings.php:976 #: ../../mod/group.php:85 ../../mod/mood.php:137 ../../mod/message.php:294 -#: ../../mod/message.php:480 ../../mod/admin.php:443 ../../mod/admin.php:687 -#: ../../mod/admin.php:823 ../../mod/admin.php:1022 ../../mod/admin.php:1109 +#: ../../mod/message.php:480 ../../mod/admin.php:443 ../../mod/admin.php:689 +#: ../../mod/admin.php:826 ../../mod/admin.php:1025 ../../mod/admin.php:1112 #: ../../mod/profiles.php:583 ../../mod/invite.php:119 #: ../../addon/fromgplus/fromgplus.php:40 #: ../../addon/facebook/facebook.php:619 #: ../../addon/snautofollow/snautofollow.php:64 ../../addon/bg/bg.php:90 -#: ../../addon/yourls/yourls.php:76 ../../addon/ljpost/ljpost.php:93 -#: ../../addon/nsfw/nsfw.php:57 ../../addon/page/page.php:210 -#: ../../addon/planets/planets.php:158 +#: ../../addon/fbpost/fbpost.php:226 ../../addon/yourls/yourls.php:76 +#: ../../addon/ljpost/ljpost.php:93 ../../addon/nsfw/nsfw.php:88 +#: ../../addon/page/page.php:210 ../../addon/planets/planets.php:158 #: ../../addon/uhremotestorage/uhremotestorage.php:89 #: ../../addon/randplace/randplace.php:177 ../../addon/dwpost/dwpost.php:93 #: ../../addon/drpost/drpost.php:110 ../../addon/startpage/startpage.php:92 #: ../../addon/geonames/geonames.php:187 ../../addon/oembed.old/oembed.php:41 #: ../../addon/forumlist/forumlist.php:169 -#: ../../addon/impressum/impressum.php:82 +#: ../../addon/impressum/impressum.php:83 #: ../../addon/notimeline/notimeline.php:64 ../../addon/blockem/blockem.php:57 #: ../../addon/qcomment/qcomment.php:61 #: ../../addon/openstreetmap/openstreetmap.php:70 @@ -158,7 +159,7 @@ msgstr "" #: ../../addon/mathjax/mathjax.php:42 ../../addon/editplain/editplain.php:84 #: ../../addon/blackout/blackout.php:98 ../../addon/gravatar/gravatar.php:95 #: ../../addon/pageheader/pageheader.php:55 ../../addon/ijpost/ijpost.php:93 -#: ../../addon/jappixmini/jappixmini.php:302 +#: ../../addon/jappixmini/jappixmini.php:307 #: ../../addon/statusnet/statusnet.php:278 #: ../../addon/statusnet/statusnet.php:292 #: ../../addon/statusnet/statusnet.php:318 @@ -174,8 +175,8 @@ msgstr "" #: ../../view/theme/cleanzero/config.php:80 #: ../../view/theme/diabook/theme.php:757 #: ../../view/theme/diabook/config.php:190 -#: ../../view/theme/quattro/config.php:52 ../../view/theme/dispy/config.php:70 -#: ../../include/conversation.php:591 +#: ../../view/theme/quattro/config.php:53 ../../view/theme/dispy/config.php:70 +#: ../../include/conversation.php:608 ../../object/Item.php:532 msgid "Submit" msgstr "" @@ -188,11 +189,11 @@ msgstr "" msgid "Help" msgstr "" -#: ../../mod/help.php:38 ../../index.php:224 +#: ../../mod/help.php:38 ../../index.php:226 msgid "Not Found" msgstr "" -#: ../../mod/help.php:41 ../../index.php:227 +#: ../../mod/help.php:41 ../../index.php:229 msgid "Page not found." msgstr "" @@ -222,90 +223,91 @@ msgstr "" msgid "Event title and start time are required." msgstr "" -#: ../../mod/events.php:263 +#: ../../mod/events.php:279 msgid "l, F j" msgstr "" -#: ../../mod/events.php:285 +#: ../../mod/events.php:301 msgid "Edit event" msgstr "" -#: ../../mod/events.php:307 ../../include/text.php:1147 +#: ../../mod/events.php:323 ../../include/text.php:1147 msgid "link to source" msgstr "" -#: ../../mod/events.php:331 ../../view/theme/diabook/theme.php:131 -#: ../../include/nav.php:52 ../../boot.php:1683 +#: ../../mod/events.php:347 ../../view/theme/diabook/theme.php:131 +#: ../../include/nav.php:52 ../../boot.php:1689 msgid "Events" msgstr "" -#: ../../mod/events.php:332 +#: ../../mod/events.php:348 msgid "Create New Event" msgstr "" -#: ../../mod/events.php:333 ../../addon/dav/friendica/layout.fnk.php:263 +#: ../../mod/events.php:349 ../../addon/dav/friendica/layout.fnk.php:263 msgid "Previous" msgstr "" -#: ../../mod/events.php:334 ../../mod/install.php:205 +#: ../../mod/events.php:350 ../../mod/install.php:205 #: ../../addon/dav/friendica/layout.fnk.php:266 msgid "Next" msgstr "" -#: ../../mod/events.php:407 +#: ../../mod/events.php:423 msgid "hour:minute" msgstr "" -#: ../../mod/events.php:417 +#: ../../mod/events.php:433 msgid "Event details" msgstr "" -#: ../../mod/events.php:418 +#: ../../mod/events.php:434 #, php-format msgid "Format is %s %s. Starting date and Title are required." msgstr "" -#: ../../mod/events.php:420 +#: ../../mod/events.php:436 msgid "Event Starts:" msgstr "" -#: ../../mod/events.php:420 ../../mod/events.php:434 +#: ../../mod/events.php:436 ../../mod/events.php:450 msgid "Required" msgstr "" -#: ../../mod/events.php:423 +#: ../../mod/events.php:439 msgid "Finish date/time is not known or not relevant" msgstr "" -#: ../../mod/events.php:425 +#: ../../mod/events.php:441 msgid "Event Finishes:" msgstr "" -#: ../../mod/events.php:428 +#: ../../mod/events.php:444 msgid "Adjust for viewer timezone" msgstr "" -#: ../../mod/events.php:430 +#: ../../mod/events.php:446 msgid "Description:" msgstr "" -#: ../../mod/events.php:432 ../../mod/directory.php:134 +#: ../../mod/events.php:448 ../../mod/directory.php:134 #: ../../include/event.php:40 ../../include/bb2diaspora.php:412 #: ../../boot.php:1226 msgid "Location:" msgstr "" -#: ../../mod/events.php:434 +#: ../../mod/events.php:450 msgid "Title:" msgstr "" -#: ../../mod/events.php:436 +#: ../../mod/events.php:452 msgid "Share this event" msgstr "" -#: ../../mod/tagrm.php:11 ../../mod/tagrm.php:94 +#: ../../mod/tagrm.php:11 ../../mod/tagrm.php:94 ../../mod/editpost.php:136 #: ../../mod/dfrn_request.php:847 ../../mod/settings.php:544 #: ../../mod/settings.php:570 ../../addon/js_upload/js_upload.php:45 +#: ../../include/conversation.php:1290 msgid "Cancel" msgstr "" @@ -373,7 +375,7 @@ msgstr "" msgid "No" msgstr "" -#: ../../mod/photos.php:46 ../../boot.php:1676 +#: ../../mod/photos.php:46 ../../boot.php:1682 msgid "Photo Albums" msgstr "" @@ -398,13 +400,13 @@ msgid "Contact information unavailable" msgstr "" #: ../../mod/photos.php:149 ../../mod/photos.php:653 ../../mod/photos.php:1073 -#: ../../mod/photos.php:1088 ../../mod/profile_photo.php:60 -#: ../../mod/profile_photo.php:67 ../../mod/profile_photo.php:74 -#: ../../mod/profile_photo.php:177 ../../mod/profile_photo.php:261 -#: ../../mod/profile_photo.php:270 +#: ../../mod/photos.php:1088 ../../mod/profile_photo.php:74 +#: ../../mod/profile_photo.php:81 ../../mod/profile_photo.php:88 +#: ../../mod/profile_photo.php:204 ../../mod/profile_photo.php:296 +#: ../../mod/profile_photo.php:305 #: ../../addon/communityhome/communityhome.php:111 -#: ../../view/theme/diabook/theme.php:599 ../../include/user.php:318 -#: ../../include/user.php:325 ../../include/user.php:332 +#: ../../view/theme/diabook/theme.php:599 ../../include/user.php:324 +#: ../../include/user.php:331 ../../include/user.php:338 msgid "Profile Photos" msgstr "" @@ -428,7 +430,7 @@ msgstr "" #: ../../addon/communityhome/communityhome.php:163 #: ../../view/theme/diabook/theme.php:570 ../../include/text.php:1399 #: ../../include/diaspora.php:1824 ../../include/conversation.php:125 -#: ../../include/conversation.php:255 +#: ../../include/conversation.php:253 msgid "photo" msgstr "" @@ -444,12 +446,12 @@ msgstr "" msgid "Image file is empty." msgstr "" -#: ../../mod/photos.php:729 ../../mod/profile_photo.php:126 +#: ../../mod/photos.php:729 ../../mod/profile_photo.php:153 #: ../../mod/wall_upload.php:110 msgid "Unable to process image." msgstr "" -#: ../../mod/photos.php:756 ../../mod/profile_photo.php:266 +#: ../../mod/photos.php:756 ../../mod/profile_photo.php:301 #: ../../mod/wall_upload.php:136 msgid "Image upload failed." msgstr "" @@ -535,7 +537,7 @@ msgid "Use as profile photo" msgstr "" #: ../../mod/photos.php:1224 ../../mod/content.php:601 -#: ../../include/conversation.php:428 +#: ../../include/conversation.php:435 ../../object/Item.php:103 msgid "Private Message" msgstr "" @@ -576,49 +578,52 @@ msgid "Example: @bob, @Barbara_Jensen, @jim@example.com, #California, #camping" msgstr "" #: ../../mod/photos.php:1356 ../../mod/content.php:665 -#: ../../include/conversation.php:565 +#: ../../include/conversation.php:582 ../../object/Item.php:185 msgid "I like this (toggle)" msgstr "" #: ../../mod/photos.php:1357 ../../mod/content.php:666 -#: ../../include/conversation.php:566 +#: ../../include/conversation.php:583 ../../object/Item.php:186 msgid "I don't like this (toggle)" msgstr "" -#: ../../mod/photos.php:1358 ../../include/conversation.php:1195 +#: ../../mod/photos.php:1358 ../../include/conversation.php:1251 msgid "Share" msgstr "" #: ../../mod/photos.php:1359 ../../mod/editpost.php:112 #: ../../mod/content.php:482 ../../mod/content.php:843 #: ../../mod/wallmessage.php:152 ../../mod/message.php:293 -#: ../../mod/message.php:481 ../../include/conversation.php:659 -#: ../../include/conversation.php:891 ../../include/conversation.php:1214 +#: ../../mod/message.php:481 ../../include/conversation.php:678 +#: ../../include/conversation.php:928 ../../include/conversation.php:1270 +#: ../../object/Item.php:237 msgid "Please wait" msgstr "" #: ../../mod/photos.php:1375 ../../mod/photos.php:1416 #: ../../mod/photos.php:1448 ../../mod/content.php:688 -#: ../../include/conversation.php:588 +#: ../../include/conversation.php:605 ../../object/Item.php:529 msgid "This is you" msgstr "" #: ../../mod/photos.php:1377 ../../mod/photos.php:1418 #: ../../mod/photos.php:1450 ../../mod/content.php:690 -#: ../../include/conversation.php:590 ../../boot.php:574 +#: ../../include/conversation.php:607 ../../boot.php:574 +#: ../../object/Item.php:531 msgid "Comment" msgstr "" #: ../../mod/photos.php:1379 ../../mod/editpost.php:133 -#: ../../mod/content.php:700 ../../include/conversation.php:600 -#: ../../include/conversation.php:1232 +#: ../../mod/content.php:700 ../../include/conversation.php:617 +#: ../../include/conversation.php:1288 ../../object/Item.php:541 msgid "Preview" msgstr "" #: ../../mod/photos.php:1479 ../../mod/content.php:439 #: ../../mod/content.php:721 ../../mod/settings.php:606 -#: ../../mod/settings.php:695 ../../mod/group.php:168 ../../mod/admin.php:694 -#: ../../include/conversation.php:440 ../../include/conversation.php:847 +#: ../../mod/settings.php:695 ../../mod/group.php:168 ../../mod/admin.php:696 +#: ../../include/conversation.php:447 ../../include/conversation.php:881 +#: ../../object/Item.php:116 msgid "Delete" msgstr "" @@ -684,28 +689,29 @@ msgstr "" msgid "Edit post" msgstr "" -#: ../../mod/editpost.php:88 ../../include/conversation.php:1181 +#: ../../mod/editpost.php:88 ../../include/conversation.php:1237 msgid "Post to Email" msgstr "" #: ../../mod/editpost.php:103 ../../mod/content.php:708 -#: ../../mod/settings.php:605 ../../include/conversation.php:433 +#: ../../mod/settings.php:605 ../../include/conversation.php:440 +#: ../../object/Item.php:107 msgid "Edit" msgstr "" #: ../../mod/editpost.php:104 ../../mod/wallmessage.php:150 #: ../../mod/message.php:291 ../../mod/message.php:478 -#: ../../include/conversation.php:1196 +#: ../../include/conversation.php:1252 msgid "Upload photo" msgstr "" -#: ../../mod/editpost.php:105 ../../include/conversation.php:1198 +#: ../../mod/editpost.php:105 ../../include/conversation.php:1254 msgid "Attach file" msgstr "" #: ../../mod/editpost.php:106 ../../mod/wallmessage.php:151 #: ../../mod/message.php:292 ../../mod/message.php:479 -#: ../../include/conversation.php:1200 +#: ../../include/conversation.php:1256 msgid "Insert web link" msgstr "" @@ -721,35 +727,35 @@ msgstr "" msgid "Insert Vorbis [.ogg] audio" msgstr "" -#: ../../mod/editpost.php:110 ../../include/conversation.php:1206 +#: ../../mod/editpost.php:110 ../../include/conversation.php:1262 msgid "Set your location" msgstr "" -#: ../../mod/editpost.php:111 ../../include/conversation.php:1208 +#: ../../mod/editpost.php:111 ../../include/conversation.php:1264 msgid "Clear browser location" msgstr "" -#: ../../mod/editpost.php:113 ../../include/conversation.php:1215 +#: ../../mod/editpost.php:113 ../../include/conversation.php:1271 msgid "Permission settings" msgstr "" -#: ../../mod/editpost.php:121 ../../include/conversation.php:1224 +#: ../../mod/editpost.php:121 ../../include/conversation.php:1280 msgid "CC: email addresses" msgstr "" -#: ../../mod/editpost.php:122 ../../include/conversation.php:1225 +#: ../../mod/editpost.php:122 ../../include/conversation.php:1281 msgid "Public post" msgstr "" -#: ../../mod/editpost.php:125 ../../include/conversation.php:1211 +#: ../../mod/editpost.php:125 ../../include/conversation.php:1267 msgid "Set title" msgstr "" -#: ../../mod/editpost.php:127 ../../include/conversation.php:1213 +#: ../../mod/editpost.php:127 ../../include/conversation.php:1269 msgid "Categories (comma-separated list)" msgstr "" -#: ../../mod/editpost.php:128 ../../include/conversation.php:1227 +#: ../../mod/editpost.php:128 ../../include/conversation.php:1283 msgid "Example: bob@example.com, mary@example.com" msgstr "" @@ -870,7 +876,7 @@ msgstr "" msgid "Confirm" msgstr "" -#: ../../mod/dfrn_request.php:715 ../../include/items.php:3213 +#: ../../mod/dfrn_request.php:715 ../../include/items.php:3287 msgid "[Name Withheld]" msgstr "" @@ -1291,28 +1297,32 @@ msgid "Group: " msgstr "" #: ../../mod/content.php:438 ../../mod/content.php:720 -#: ../../include/conversation.php:439 ../../include/conversation.php:846 +#: ../../include/conversation.php:446 ../../include/conversation.php:880 +#: ../../object/Item.php:115 msgid "Select" msgstr "" #: ../../mod/content.php:455 ../../mod/content.php:813 -#: ../../mod/content.php:814 ../../include/conversation.php:627 -#: ../../include/conversation.php:628 ../../include/conversation.php:863 +#: ../../mod/content.php:814 ../../include/conversation.php:646 +#: ../../include/conversation.php:647 ../../include/conversation.php:897 +#: ../../object/Item.php:206 ../../object/Item.php:207 #, php-format msgid "View %s's profile @ %s" msgstr "" #: ../../mod/content.php:465 ../../mod/content.php:825 -#: ../../include/conversation.php:641 ../../include/conversation.php:874 +#: ../../include/conversation.php:660 ../../include/conversation.php:911 +#: ../../object/Item.php:219 #, php-format msgid "%s from %s" msgstr "" -#: ../../mod/content.php:480 ../../include/conversation.php:889 +#: ../../mod/content.php:480 ../../include/conversation.php:926 msgid "View in context" msgstr "" -#: ../../mod/content.php:586 ../../include/conversation.php:668 +#: ../../mod/content.php:586 ../../include/conversation.php:687 +#: ../../object/Item.php:256 #, php-format msgid "%d comment" msgid_plural "%d comments" @@ -1321,92 +1331,113 @@ msgstr[1] "" #: ../../mod/content.php:587 ../../addon/page/page.php:76 #: ../../addon/page/page.php:110 ../../addon/showmore/showmore.php:119 -#: ../../include/contact_widgets.php:195 ../../include/conversation.php:669 -#: ../../boot.php:575 +#: ../../include/contact_widgets.php:195 ../../include/conversation.php:688 +#: ../../boot.php:575 ../../object/Item.php:257 msgid "show more" msgstr "" -#: ../../mod/content.php:665 ../../include/conversation.php:565 +#: ../../mod/content.php:665 ../../include/conversation.php:582 +#: ../../object/Item.php:185 msgid "like" msgstr "" -#: ../../mod/content.php:666 ../../include/conversation.php:566 +#: ../../mod/content.php:666 ../../include/conversation.php:583 +#: ../../object/Item.php:186 msgid "dislike" msgstr "" -#: ../../mod/content.php:668 ../../include/conversation.php:568 +#: ../../mod/content.php:668 ../../include/conversation.php:585 +#: ../../object/Item.php:188 msgid "Share this" msgstr "" -#: ../../mod/content.php:668 ../../include/conversation.php:568 +#: ../../mod/content.php:668 ../../include/conversation.php:585 +#: ../../object/Item.php:188 msgid "share" msgstr "" -#: ../../mod/content.php:692 ../../include/conversation.php:592 +#: ../../mod/content.php:692 ../../include/conversation.php:609 +#: ../../object/Item.php:533 msgid "Bold" msgstr "" -#: ../../mod/content.php:693 ../../include/conversation.php:593 +#: ../../mod/content.php:693 ../../include/conversation.php:610 +#: ../../object/Item.php:534 msgid "Italic" msgstr "" -#: ../../mod/content.php:694 ../../include/conversation.php:594 +#: ../../mod/content.php:694 ../../include/conversation.php:611 +#: ../../object/Item.php:535 msgid "Underline" msgstr "" -#: ../../mod/content.php:695 ../../include/conversation.php:595 +#: ../../mod/content.php:695 ../../include/conversation.php:612 +#: ../../object/Item.php:536 msgid "Quote" msgstr "" -#: ../../mod/content.php:696 ../../include/conversation.php:596 +#: ../../mod/content.php:696 ../../include/conversation.php:613 +#: ../../object/Item.php:537 msgid "Code" msgstr "" -#: ../../mod/content.php:697 ../../include/conversation.php:597 +#: ../../mod/content.php:697 ../../include/conversation.php:614 +#: ../../object/Item.php:538 msgid "Image" msgstr "" -#: ../../mod/content.php:698 ../../include/conversation.php:598 +#: ../../mod/content.php:698 ../../include/conversation.php:615 +#: ../../object/Item.php:539 msgid "Link" msgstr "" -#: ../../mod/content.php:699 ../../include/conversation.php:599 +#: ../../mod/content.php:699 ../../include/conversation.php:616 +#: ../../object/Item.php:540 msgid "Video" msgstr "" -#: ../../mod/content.php:733 ../../include/conversation.php:529 +#: ../../mod/content.php:733 ../../include/conversation.php:546 +#: ../../object/Item.php:169 msgid "add star" msgstr "" -#: ../../mod/content.php:734 ../../include/conversation.php:530 +#: ../../mod/content.php:734 ../../include/conversation.php:547 +#: ../../object/Item.php:170 msgid "remove star" msgstr "" -#: ../../mod/content.php:735 ../../include/conversation.php:531 +#: ../../mod/content.php:735 ../../include/conversation.php:548 +#: ../../object/Item.php:171 msgid "toggle star status" msgstr "" -#: ../../mod/content.php:738 ../../include/conversation.php:534 +#: ../../mod/content.php:738 ../../include/conversation.php:551 +#: ../../object/Item.php:174 msgid "starred" msgstr "" -#: ../../mod/content.php:739 ../../include/conversation.php:535 +#: ../../mod/content.php:739 ../../include/conversation.php:552 +#: ../../object/Item.php:175 msgid "add tag" msgstr "" -#: ../../mod/content.php:743 ../../include/conversation.php:443 +#: ../../mod/content.php:743 ../../include/conversation.php:450 +#: ../../object/Item.php:119 msgid "save to folder" msgstr "" -#: ../../mod/content.php:815 ../../include/conversation.php:629 +#: ../../mod/content.php:815 ../../include/conversation.php:648 +#: ../../object/Item.php:208 msgid "to" msgstr "" -#: ../../mod/content.php:816 ../../include/conversation.php:630 +#: ../../mod/content.php:816 ../../include/conversation.php:649 +#: ../../object/Item.php:209 msgid "Wall-to-Wall" msgstr "" -#: ../../mod/content.php:817 ../../include/conversation.php:631 +#: ../../mod/content.php:817 ../../include/conversation.php:650 +#: ../../object/Item.php:210 msgid "via Wall-To-Wall:" msgstr "" @@ -1491,7 +1522,7 @@ msgid "if applicable" msgstr "" #: ../../mod/notifications.php:157 ../../mod/notifications.php:204 -#: ../../mod/admin.php:692 +#: ../../mod/admin.php:694 msgid "Approve" msgstr "" @@ -1692,12 +1723,12 @@ msgid "View all contacts" msgstr "" #: ../../mod/contacts.php:315 ../../mod/contacts.php:374 -#: ../../mod/admin.php:696 +#: ../../mod/admin.php:698 msgid "Unblock" msgstr "" #: ../../mod/contacts.php:315 ../../mod/contacts.php:374 -#: ../../mod/admin.php:695 +#: ../../mod/admin.php:697 msgid "Block" msgstr "" @@ -1794,7 +1825,7 @@ msgstr "" msgid "Update public posts" msgstr "" -#: ../../mod/contacts.php:371 ../../mod/admin.php:1167 +#: ../../mod/contacts.php:371 ../../mod/admin.php:1170 msgid "Update now" msgstr "" @@ -1922,9 +1953,9 @@ msgstr "" #: ../../mod/register.php:90 ../../mod/register.php:144 #: ../../mod/regmod.php:54 ../../mod/dfrn_confirm.php:752 #: ../../addon/facebook/facebook.php:702 -#: ../../addon/facebook/facebook.php:1200 +#: ../../addon/facebook/facebook.php:1200 ../../addon/fbpost/fbpost.php:661 #: ../../addon/public_server/public_server.php:62 -#: ../../addon/testdrive/testdrive.php:67 ../../include/items.php:3222 +#: ../../addon/testdrive/testdrive.php:67 ../../include/items.php:3296 #: ../../boot.php:788 msgid "Administrator" msgstr "" @@ -2008,7 +2039,7 @@ msgid "Remove account" msgstr "" #: ../../mod/settings.php:69 ../../mod/newmember.php:22 -#: ../../mod/admin.php:782 ../../mod/admin.php:987 +#: ../../mod/admin.php:785 ../../mod/admin.php:990 #: ../../addon/dav/friendica/layout.fnk.php:225 #: ../../addon/mathjax/mathjax.php:36 ../../view/theme/diabook/theme.php:643 #: ../../view/theme/diabook/theme.php:773 ../../include/nav.php:137 @@ -2072,7 +2103,7 @@ msgid "Private forum has no privacy permissions and no default privacy group." msgstr "" #: ../../mod/settings.php:471 ../../addon/facebook/facebook.php:495 -#: ../../addon/impressum/impressum.php:77 +#: ../../addon/fbpost/fbpost.php:144 ../../addon/impressum/impressum.php:78 #: ../../addon/openstreetmap/openstreetmap.php:80 #: ../../addon/mathjax/mathjax.php:66 ../../addon/piwik/piwik.php:105 #: ../../addon/twitter/twitter.php:389 @@ -2338,7 +2369,7 @@ msgstr "" msgid "Profile is not published." msgstr "" -#: ../../mod/settings.php:944 ../../mod/profile_photo.php:214 +#: ../../mod/settings.php:944 ../../mod/profile_photo.php:248 msgid "or" msgstr "" @@ -2612,13 +2643,14 @@ msgstr "" msgid "Invalid contact." msgstr "" -#: ../../mod/notes.php:44 ../../boot.php:1690 +#: ../../mod/notes.php:44 ../../boot.php:1696 msgid "Personal Notes" msgstr "" #: ../../mod/notes.php:63 ../../mod/filer.php:30 #: ../../addon/facebook/facebook.php:770 #: ../../addon/privacy_image_cache/privacy_image_cache.php:263 +#: ../../addon/fbpost/fbpost.php:267 #: ../../addon/dav/friendica/layout.fnk.php:441 #: ../../addon/dav/friendica/layout.fnk.php:488 ../../include/text.php:681 msgid "Save" @@ -2655,7 +2687,7 @@ msgstr "" #: ../../mod/wallmessage.php:123 ../../mod/wallmessage.php:131 #: ../../mod/message.php:242 ../../mod/message.php:250 -#: ../../include/conversation.php:1132 ../../include/conversation.php:1149 +#: ../../include/conversation.php:1188 ../../include/conversation.php:1205 msgid "Please enter a link URL:" msgstr "" @@ -2738,11 +2770,11 @@ msgstr "" #: ../../mod/newmember.php:32 ../../mod/profperm.php:103 #: ../../view/theme/diabook/theme.php:128 ../../include/profile_advanced.php:7 #: ../../include/profile_advanced.php:84 ../../include/nav.php:50 -#: ../../boot.php:1666 +#: ../../boot.php:1672 msgid "Profile" msgstr "" -#: ../../mod/newmember.php:36 ../../mod/profile_photo.php:211 +#: ../../mod/newmember.php:36 ../../mod/profile_photo.php:244 msgid "Upload Profile Photo" msgstr "" @@ -2780,7 +2812,7 @@ msgid "Connecting" msgstr "" #: ../../mod/newmember.php:49 ../../mod/newmember.php:51 -#: ../../addon/facebook/facebook.php:728 +#: ../../addon/facebook/facebook.php:728 ../../addon/fbpost/fbpost.php:239 #: ../../include/contact_selectors.php:81 msgid "Facebook" msgstr "" @@ -2907,7 +2939,7 @@ msgstr "" msgid "Group name changed." msgstr "" -#: ../../mod/group.php:72 ../../mod/profperm.php:19 ../../index.php:314 +#: ../../mod/group.php:72 ../../mod/profperm.php:19 ../../index.php:316 msgid "Permission denied" msgstr "" @@ -3056,32 +3088,32 @@ msgid "People Search" msgstr "" #: ../../mod/like.php:145 ../../mod/like.php:298 ../../mod/tagger.php:62 -#: ../../addon/facebook/facebook.php:1594 +#: ../../addon/facebook/facebook.php:1598 #: ../../addon/communityhome/communityhome.php:158 #: ../../addon/communityhome/communityhome.php:167 #: ../../view/theme/diabook/theme.php:565 #: ../../view/theme/diabook/theme.php:574 ../../include/diaspora.php:1824 #: ../../include/conversation.php:120 ../../include/conversation.php:129 -#: ../../include/conversation.php:250 ../../include/conversation.php:259 +#: ../../include/conversation.php:248 ../../include/conversation.php:257 msgid "status" msgstr "" -#: ../../mod/like.php:162 ../../addon/facebook/facebook.php:1598 +#: ../../mod/like.php:162 ../../addon/facebook/facebook.php:1602 #: ../../addon/communityhome/communityhome.php:172 #: ../../view/theme/diabook/theme.php:579 ../../include/diaspora.php:1840 -#: ../../include/conversation.php:137 +#: ../../include/conversation.php:136 #, php-format msgid "%1$s likes %2$s's %3$s" msgstr "" -#: ../../mod/like.php:164 ../../include/conversation.php:140 +#: ../../mod/like.php:164 ../../include/conversation.php:139 #, php-format msgid "%1$s doesn't like %2$s's %3$s" msgstr "" #: ../../mod/notice.php:15 ../../mod/viewsrc.php:15 ../../mod/admin.php:159 -#: ../../mod/admin.php:731 ../../mod/admin.php:930 ../../mod/display.php:29 -#: ../../mod/display.php:145 ../../include/items.php:3700 +#: ../../mod/admin.php:734 ../../mod/admin.php:933 ../../mod/display.php:29 +#: ../../mod/display.php:145 ../../include/items.php:3774 msgid "Item not found." msgstr "" @@ -3090,7 +3122,7 @@ msgid "Access denied." msgstr "" #: ../../mod/fbrowser.php:25 ../../view/theme/diabook/theme.php:130 -#: ../../include/nav.php:51 ../../boot.php:1673 +#: ../../include/nav.php:51 ../../boot.php:1679 msgid "Photos" msgstr "" @@ -3151,7 +3183,7 @@ msgstr "" msgid "%s posted an update." msgstr "" -#: ../../mod/mood.php:62 ../../include/conversation.php:228 +#: ../../mod/mood.php:62 ../../include/conversation.php:226 #, php-format msgid "%1$s is currently %2$s" msgstr "" @@ -3164,61 +3196,65 @@ msgstr "" msgid "Set your current mood and tell your friends" msgstr "" -#: ../../mod/profile_photo.php:30 +#: ../../mod/profile_photo.php:44 msgid "Image uploaded but image cropping failed." msgstr "" -#: ../../mod/profile_photo.php:63 ../../mod/profile_photo.php:70 -#: ../../mod/profile_photo.php:77 ../../mod/profile_photo.php:273 +#: ../../mod/profile_photo.php:77 ../../mod/profile_photo.php:84 +#: ../../mod/profile_photo.php:91 ../../mod/profile_photo.php:308 #, php-format msgid "Image size reduction [%s] failed." msgstr "" -#: ../../mod/profile_photo.php:91 +#: ../../mod/profile_photo.php:118 msgid "" "Shift-reload the page or clear browser cache if the new photo does not " "display immediately." msgstr "" -#: ../../mod/profile_photo.php:101 +#: ../../mod/profile_photo.php:128 msgid "Unable to process image" msgstr "" -#: ../../mod/profile_photo.php:117 ../../mod/wall_upload.php:88 +#: ../../mod/profile_photo.php:144 ../../mod/wall_upload.php:88 #, php-format msgid "Image exceeds size limit of %d" msgstr "" -#: ../../mod/profile_photo.php:210 +#: ../../mod/profile_photo.php:242 msgid "Upload File:" msgstr "" -#: ../../mod/profile_photo.php:212 +#: ../../mod/profile_photo.php:243 +msgid "Select a profile:" +msgstr "" + +#: ../../mod/profile_photo.php:245 #: ../../addon/dav/friendica/layout.fnk.php:152 msgid "Upload" msgstr "" -#: ../../mod/profile_photo.php:214 +#: ../../mod/profile_photo.php:248 msgid "skip this step" msgstr "" -#: ../../mod/profile_photo.php:214 +#: ../../mod/profile_photo.php:248 msgid "select a photo from your photo albums" msgstr "" -#: ../../mod/profile_photo.php:227 +#: ../../mod/profile_photo.php:262 msgid "Crop Image" msgstr "" -#: ../../mod/profile_photo.php:228 +#: ../../mod/profile_photo.php:263 msgid "Please adjust the image cropping for optimum viewing." msgstr "" -#: ../../mod/profile_photo.php:230 +#: ../../mod/profile_photo.php:265 msgid "Done Editing" msgstr "" -#: ../../mod/profile_photo.php:264 +#: ../../mod/profile_photo.php:299 msgid "Image uploaded successfully." msgstr "" @@ -3325,15 +3361,15 @@ msgstr "" msgid "Site" msgstr "" -#: ../../mod/admin.php:97 ../../mod/admin.php:686 ../../mod/admin.php:698 +#: ../../mod/admin.php:97 ../../mod/admin.php:688 ../../mod/admin.php:701 msgid "Users" msgstr "" -#: ../../mod/admin.php:98 ../../mod/admin.php:780 ../../mod/admin.php:822 +#: ../../mod/admin.php:98 ../../mod/admin.php:783 ../../mod/admin.php:825 msgid "Plugins" msgstr "" -#: ../../mod/admin.php:99 ../../mod/admin.php:985 ../../mod/admin.php:1021 +#: ../../mod/admin.php:99 ../../mod/admin.php:988 ../../mod/admin.php:1024 msgid "Themes" msgstr "" @@ -3341,7 +3377,7 @@ msgstr "" msgid "DB updates" msgstr "" -#: ../../mod/admin.php:115 ../../mod/admin.php:122 ../../mod/admin.php:1108 +#: ../../mod/admin.php:115 ../../mod/admin.php:122 ../../mod/admin.php:1111 msgid "Logs" msgstr "" @@ -3357,19 +3393,19 @@ msgstr "" msgid "User registrations waiting for confirmation" msgstr "" -#: ../../mod/admin.php:183 ../../mod/admin.php:668 +#: ../../mod/admin.php:183 ../../mod/admin.php:669 msgid "Normal Account" msgstr "" -#: ../../mod/admin.php:184 ../../mod/admin.php:669 +#: ../../mod/admin.php:184 ../../mod/admin.php:670 msgid "Soapbox Account" msgstr "" -#: ../../mod/admin.php:185 ../../mod/admin.php:670 +#: ../../mod/admin.php:185 ../../mod/admin.php:671 msgid "Community/Celebrity Account" msgstr "" -#: ../../mod/admin.php:186 ../../mod/admin.php:671 +#: ../../mod/admin.php:186 ../../mod/admin.php:672 msgid "Automatic Friend Account" msgstr "" @@ -3385,9 +3421,9 @@ msgstr "" msgid "Message queues" msgstr "" -#: ../../mod/admin.php:212 ../../mod/admin.php:441 ../../mod/admin.php:685 -#: ../../mod/admin.php:779 ../../mod/admin.php:821 ../../mod/admin.php:984 -#: ../../mod/admin.php:1020 ../../mod/admin.php:1107 +#: ../../mod/admin.php:212 ../../mod/admin.php:441 ../../mod/admin.php:687 +#: ../../mod/admin.php:782 ../../mod/admin.php:824 ../../mod/admin.php:987 +#: ../../mod/admin.php:1023 ../../mod/admin.php:1110 msgid "Administration" msgstr "" @@ -3600,13 +3636,13 @@ msgid "Allow infinite level threading for items on this site." msgstr "" #: ../../mod/admin.php:470 -msgid "No default permissions for new users" +msgid "Private posts by default for new users" msgstr "" #: ../../mod/admin.php:470 msgid "" -"New users will have no private permissions set for their posts by default, " -"making their posts public until they change it." +"Set default post permissions for all new members to the default privacy " +"group rather than public." msgstr "" #: ../../mod/admin.php:472 @@ -3812,148 +3848,152 @@ msgstr "" msgid "User '%s' blocked" msgstr "" -#: ../../mod/admin.php:688 +#: ../../mod/admin.php:690 msgid "select all" msgstr "" -#: ../../mod/admin.php:689 +#: ../../mod/admin.php:691 msgid "User registrations waiting for confirm" msgstr "" -#: ../../mod/admin.php:690 +#: ../../mod/admin.php:692 msgid "Request date" msgstr "" -#: ../../mod/admin.php:690 ../../mod/admin.php:699 +#: ../../mod/admin.php:692 ../../mod/admin.php:702 #: ../../include/contact_selectors.php:79 msgid "Email" msgstr "" -#: ../../mod/admin.php:691 +#: ../../mod/admin.php:693 msgid "No registrations." msgstr "" -#: ../../mod/admin.php:693 +#: ../../mod/admin.php:695 msgid "Deny" msgstr "" #: ../../mod/admin.php:699 +msgid "Site admin" +msgstr "" + +#: ../../mod/admin.php:702 msgid "Register date" msgstr "" -#: ../../mod/admin.php:699 +#: ../../mod/admin.php:702 msgid "Last login" msgstr "" -#: ../../mod/admin.php:699 +#: ../../mod/admin.php:702 msgid "Last item" msgstr "" -#: ../../mod/admin.php:699 +#: ../../mod/admin.php:702 msgid "Account" msgstr "" -#: ../../mod/admin.php:701 +#: ../../mod/admin.php:704 msgid "" "Selected users will be deleted!\\n\\nEverything these users had posted on " "this site will be permanently deleted!\\n\\nAre you sure?" msgstr "" -#: ../../mod/admin.php:702 +#: ../../mod/admin.php:705 msgid "" "The user {0} will be deleted!\\n\\nEverything this user has posted on this " "site will be permanently deleted!\\n\\nAre you sure?" msgstr "" -#: ../../mod/admin.php:743 +#: ../../mod/admin.php:746 #, php-format msgid "Plugin %s disabled." msgstr "" -#: ../../mod/admin.php:747 +#: ../../mod/admin.php:750 #, php-format msgid "Plugin %s enabled." msgstr "" -#: ../../mod/admin.php:757 ../../mod/admin.php:955 +#: ../../mod/admin.php:760 ../../mod/admin.php:958 msgid "Disable" msgstr "" -#: ../../mod/admin.php:759 ../../mod/admin.php:957 +#: ../../mod/admin.php:762 ../../mod/admin.php:960 msgid "Enable" msgstr "" -#: ../../mod/admin.php:781 ../../mod/admin.php:986 +#: ../../mod/admin.php:784 ../../mod/admin.php:989 msgid "Toggle" msgstr "" -#: ../../mod/admin.php:789 ../../mod/admin.php:996 +#: ../../mod/admin.php:792 ../../mod/admin.php:999 msgid "Author: " msgstr "" -#: ../../mod/admin.php:790 ../../mod/admin.php:997 +#: ../../mod/admin.php:793 ../../mod/admin.php:1000 msgid "Maintainer: " msgstr "" -#: ../../mod/admin.php:919 +#: ../../mod/admin.php:922 msgid "No themes found." msgstr "" -#: ../../mod/admin.php:978 +#: ../../mod/admin.php:981 msgid "Screenshot" msgstr "" -#: ../../mod/admin.php:1026 +#: ../../mod/admin.php:1029 msgid "[Experimental]" msgstr "" -#: ../../mod/admin.php:1027 +#: ../../mod/admin.php:1030 msgid "[Unsupported]" msgstr "" -#: ../../mod/admin.php:1054 +#: ../../mod/admin.php:1057 msgid "Log settings updated." msgstr "" -#: ../../mod/admin.php:1110 +#: ../../mod/admin.php:1113 msgid "Clear" msgstr "" -#: ../../mod/admin.php:1116 +#: ../../mod/admin.php:1119 msgid "Debugging" msgstr "" -#: ../../mod/admin.php:1117 +#: ../../mod/admin.php:1120 msgid "Log file" msgstr "" -#: ../../mod/admin.php:1117 +#: ../../mod/admin.php:1120 msgid "" "Must be writable by web server. Relative to your Friendica top-level " "directory." msgstr "" -#: ../../mod/admin.php:1118 +#: ../../mod/admin.php:1121 msgid "Log level" msgstr "" -#: ../../mod/admin.php:1168 +#: ../../mod/admin.php:1171 msgid "Close" msgstr "" -#: ../../mod/admin.php:1174 +#: ../../mod/admin.php:1177 msgid "FTP Host" msgstr "" -#: ../../mod/admin.php:1175 +#: ../../mod/admin.php:1178 msgid "FTP Path" msgstr "" -#: ../../mod/admin.php:1176 +#: ../../mod/admin.php:1179 msgid "FTP User" msgstr "" -#: ../../mod/admin.php:1177 +#: ../../mod/admin.php:1180 msgid "FTP Password" msgstr "" @@ -3969,48 +4009,48 @@ msgstr "" msgid "Tips for New Members" msgstr "" -#: ../../mod/ping.php:185 +#: ../../mod/ping.php:235 msgid "{0} wants to be your friend" msgstr "" -#: ../../mod/ping.php:190 +#: ../../mod/ping.php:240 msgid "{0} sent you a message" msgstr "" -#: ../../mod/ping.php:195 +#: ../../mod/ping.php:245 msgid "{0} requested registration" msgstr "" -#: ../../mod/ping.php:201 +#: ../../mod/ping.php:251 #, php-format msgid "{0} commented %s's post" msgstr "" -#: ../../mod/ping.php:206 +#: ../../mod/ping.php:256 #, php-format msgid "{0} liked %s's post" msgstr "" -#: ../../mod/ping.php:211 +#: ../../mod/ping.php:261 #, php-format msgid "{0} disliked %s's post" msgstr "" -#: ../../mod/ping.php:216 +#: ../../mod/ping.php:266 #, php-format msgid "{0} is now friends with %s" msgstr "" -#: ../../mod/ping.php:221 +#: ../../mod/ping.php:271 msgid "{0} posted" msgstr "" -#: ../../mod/ping.php:226 +#: ../../mod/ping.php:276 #, php-format msgid "{0} tagged %s's post with #%s" msgstr "" -#: ../../mod/ping.php:232 +#: ../../mod/ping.php:282 msgid "{0} mentioned you in a post" msgstr "" @@ -4372,8 +4412,8 @@ msgstr "" msgid "Edit visibility" msgstr "" -#: ../../mod/filer.php:29 ../../include/conversation.php:1136 -#: ../../include/conversation.php:1153 +#: ../../mod/filer.php:29 ../../include/conversation.php:1192 +#: ../../include/conversation.php:1209 msgid "Save to Folder:" msgstr "" @@ -4381,7 +4421,7 @@ msgstr "" msgid "- select -" msgstr "" -#: ../../mod/tagger.php:95 ../../include/conversation.php:267 +#: ../../mod/tagger.php:95 ../../include/conversation.php:265 #, php-format msgid "%1$s tagged %2$s's %3$s with %4$s" msgstr "" @@ -4639,7 +4679,7 @@ msgid "Unable to set contact photo." msgstr "" #: ../../mod/dfrn_confirm.php:477 ../../include/diaspora.php:608 -#: ../../include/conversation.php:173 +#: ../../include/conversation.php:171 #, php-format msgid "%1$s is now friends with %2$s" msgstr "" @@ -4714,7 +4754,7 @@ msgstr "" msgid "Updating contacts" msgstr "" -#: ../../addon/facebook/facebook.php:551 +#: ../../addon/facebook/facebook.php:551 ../../addon/fbpost/fbpost.php:192 msgid "Facebook API key is missing." msgstr "" @@ -4730,13 +4770,13 @@ msgstr "" msgid "Remove Facebook connector" msgstr "" -#: ../../addon/facebook/facebook.php:576 +#: ../../addon/facebook/facebook.php:576 ../../addon/fbpost/fbpost.php:217 msgid "" "Re-authenticate [This is necessary whenever your Facebook password is " "changed.]" msgstr "" -#: ../../addon/facebook/facebook.php:583 +#: ../../addon/facebook/facebook.php:583 ../../addon/fbpost/fbpost.php:224 msgid "Post to Facebook by default" msgstr "" @@ -4802,11 +4842,11 @@ msgstr "" msgid "Facebook Connector Settings" msgstr "" -#: ../../addon/facebook/facebook.php:744 +#: ../../addon/facebook/facebook.php:744 ../../addon/fbpost/fbpost.php:255 msgid "Facebook API Key" msgstr "" -#: ../../addon/facebook/facebook.php:754 +#: ../../addon/facebook/facebook.php:754 ../../addon/fbpost/fbpost.php:262 msgid "" "Error: it appears that you have specified the App-ID and -Secret in your ." "htconfig.php file. As long as they are specified there, they cannot be set " @@ -4829,11 +4869,11 @@ msgid "" "going on." msgstr "" -#: ../../addon/facebook/facebook.php:766 +#: ../../addon/facebook/facebook.php:766 ../../addon/fbpost/fbpost.php:264 msgid "App-ID / API-Key" msgstr "" -#: ../../addon/facebook/facebook.php:767 +#: ../../addon/facebook/facebook.php:767 ../../addon/fbpost/fbpost.php:265 msgid "Application secret" msgstr "" @@ -4868,38 +4908,38 @@ msgstr "" msgid "Activate Real-Time Updates" msgstr "" -#: ../../addon/facebook/facebook.php:799 +#: ../../addon/facebook/facebook.php:799 ../../addon/fbpost/fbpost.php:282 #: ../../addon/dav/friendica/layout.fnk.php:361 msgid "The new values have been saved." msgstr "" -#: ../../addon/facebook/facebook.php:823 +#: ../../addon/facebook/facebook.php:823 ../../addon/fbpost/fbpost.php:301 msgid "Post to Facebook" msgstr "" -#: ../../addon/facebook/facebook.php:921 +#: ../../addon/facebook/facebook.php:921 ../../addon/fbpost/fbpost.php:399 msgid "" "Post to Facebook cancelled because of multi-network access permission " "conflict." msgstr "" -#: ../../addon/facebook/facebook.php:1149 +#: ../../addon/facebook/facebook.php:1149 ../../addon/fbpost/fbpost.php:610 msgid "View on Friendica" msgstr "" -#: ../../addon/facebook/facebook.php:1182 +#: ../../addon/facebook/facebook.php:1182 ../../addon/fbpost/fbpost.php:643 msgid "Facebook post failed. Queued for retry." msgstr "" -#: ../../addon/facebook/facebook.php:1222 +#: ../../addon/facebook/facebook.php:1222 ../../addon/fbpost/fbpost.php:683 msgid "Your Facebook connection became invalid. Please Re-authenticate." msgstr "" -#: ../../addon/facebook/facebook.php:1223 +#: ../../addon/facebook/facebook.php:1223 ../../addon/fbpost/fbpost.php:684 msgid "Facebook connection became invalid" msgstr "" -#: ../../addon/facebook/facebook.php:1224 +#: ../../addon/facebook/facebook.php:1224 ../../addon/fbpost/fbpost.php:685 #, php-format msgid "" "Hi %1$s,\n" @@ -4953,6 +4993,26 @@ msgstr "" msgid "Delete the whole cache" msgstr "" +#: ../../addon/fbpost/fbpost.php:172 +msgid "Facebook Post disabled" +msgstr "" + +#: ../../addon/fbpost/fbpost.php:199 +msgid "Facebook Post" +msgstr "" + +#: ../../addon/fbpost/fbpost.php:205 +msgid "Install Facebook Post connector for this account." +msgstr "" + +#: ../../addon/fbpost/fbpost.php:212 +msgid "Remove Facebook Post connector" +msgstr "" + +#: ../../addon/fbpost/fbpost.php:240 +msgid "Facebook Post Settings" +msgstr "" + #: ../../addon/widgets/widget_like.php:58 #, php-format msgid "%d person likes this" @@ -5012,11 +5072,11 @@ msgid "did something obscenely biological to" msgstr "" #: ../../addon/morepokes/morepokes.php:22 -msgid "point out the new poke feature to" +msgid "point out the poke feature to" msgstr "" #: ../../addon/morepokes/morepokes.php:22 -msgid "pointed out the new poke feature to" +msgid "pointed out the poke feature to" msgstr "" #: ../../addon/morepokes/morepokes.php:23 @@ -5028,112 +5088,108 @@ msgid "declared undying love for" msgstr "" #: ../../addon/morepokes/morepokes.php:24 -msgid "set fire to" -msgstr "" - -#: ../../addon/morepokes/morepokes.php:25 msgid "patent" msgstr "" -#: ../../addon/morepokes/morepokes.php:25 +#: ../../addon/morepokes/morepokes.php:24 msgid "patented" msgstr "" -#: ../../addon/morepokes/morepokes.php:26 +#: ../../addon/morepokes/morepokes.php:25 msgid "stroke beard" msgstr "" -#: ../../addon/morepokes/morepokes.php:26 +#: ../../addon/morepokes/morepokes.php:25 msgid "stroked their beard at" msgstr "" -#: ../../addon/morepokes/morepokes.php:27 +#: ../../addon/morepokes/morepokes.php:26 msgid "" "bemoan the declining standards of modern secondary and tertiary education to" msgstr "" -#: ../../addon/morepokes/morepokes.php:27 +#: ../../addon/morepokes/morepokes.php:26 msgid "" "bemoans the declining standards of modern secondary and tertiary education to" msgstr "" -#: ../../addon/morepokes/morepokes.php:28 +#: ../../addon/morepokes/morepokes.php:27 msgid "hug" msgstr "" -#: ../../addon/morepokes/morepokes.php:28 +#: ../../addon/morepokes/morepokes.php:27 msgid "hugged" msgstr "" -#: ../../addon/morepokes/morepokes.php:29 +#: ../../addon/morepokes/morepokes.php:28 msgid "kiss" msgstr "" -#: ../../addon/morepokes/morepokes.php:29 +#: ../../addon/morepokes/morepokes.php:28 msgid "kissed" msgstr "" -#: ../../addon/morepokes/morepokes.php:30 +#: ../../addon/morepokes/morepokes.php:29 msgid "raise eyebrows at" msgstr "" -#: ../../addon/morepokes/morepokes.php:30 +#: ../../addon/morepokes/morepokes.php:29 msgid "raised their eyebrows at" msgstr "" -#: ../../addon/morepokes/morepokes.php:31 +#: ../../addon/morepokes/morepokes.php:30 msgid "insult" msgstr "" -#: ../../addon/morepokes/morepokes.php:31 +#: ../../addon/morepokes/morepokes.php:30 msgid "insulted" msgstr "" -#: ../../addon/morepokes/morepokes.php:32 +#: ../../addon/morepokes/morepokes.php:31 msgid "praise" msgstr "" -#: ../../addon/morepokes/morepokes.php:32 +#: ../../addon/morepokes/morepokes.php:31 msgid "praised" msgstr "" -#: ../../addon/morepokes/morepokes.php:33 +#: ../../addon/morepokes/morepokes.php:32 msgid "be dubious of" msgstr "" -#: ../../addon/morepokes/morepokes.php:33 +#: ../../addon/morepokes/morepokes.php:32 msgid "was dubious of" msgstr "" -#: ../../addon/morepokes/morepokes.php:34 +#: ../../addon/morepokes/morepokes.php:33 msgid "eat" msgstr "" -#: ../../addon/morepokes/morepokes.php:34 +#: ../../addon/morepokes/morepokes.php:33 msgid "ate" msgstr "" -#: ../../addon/morepokes/morepokes.php:35 +#: ../../addon/morepokes/morepokes.php:34 msgid "giggle and fawn at" msgstr "" -#: ../../addon/morepokes/morepokes.php:35 +#: ../../addon/morepokes/morepokes.php:34 msgid "giggled and fawned at" msgstr "" -#: ../../addon/morepokes/morepokes.php:36 +#: ../../addon/morepokes/morepokes.php:35 msgid "doubt" msgstr "" -#: ../../addon/morepokes/morepokes.php:36 +#: ../../addon/morepokes/morepokes.php:35 msgid "doubted" msgstr "" -#: ../../addon/morepokes/morepokes.php:37 +#: ../../addon/morepokes/morepokes.php:36 msgid "glare" msgstr "" -#: ../../addon/morepokes/morepokes.php:37 +#: ../../addon/morepokes/morepokes.php:36 msgid "glared at" msgstr "" @@ -5185,11 +5241,11 @@ msgstr "" msgid "Post to LiveJournal by default" msgstr "" -#: ../../addon/nsfw/nsfw.php:47 +#: ../../addon/nsfw/nsfw.php:78 msgid "Not Safe For Work (General Purpose Content Filter) settings" msgstr "" -#: ../../addon/nsfw/nsfw.php:49 +#: ../../addon/nsfw/nsfw.php:80 msgid "" "This plugin looks in posts for the words/text you specify below, and " "collapses any content containing those keywords so it is not displayed at " @@ -5199,23 +5255,23 @@ msgid "" "can thereby be used as a general purpose content filter." msgstr "" -#: ../../addon/nsfw/nsfw.php:50 +#: ../../addon/nsfw/nsfw.php:81 msgid "Enable Content filter" msgstr "" -#: ../../addon/nsfw/nsfw.php:53 +#: ../../addon/nsfw/nsfw.php:84 msgid "Comma separated list of keywords to hide" msgstr "" -#: ../../addon/nsfw/nsfw.php:58 +#: ../../addon/nsfw/nsfw.php:89 msgid "Use /expression/ to provide regular expressions" msgstr "" -#: ../../addon/nsfw/nsfw.php:74 +#: ../../addon/nsfw/nsfw.php:105 msgid "NSFW Settings saved." msgstr "" -#: ../../addon/nsfw/nsfw.php:121 +#: ../../addon/nsfw/nsfw.php:157 #, php-format msgid "%s - Click to open/close" msgstr "" @@ -5290,7 +5346,7 @@ msgstr "" #: ../../addon/communityhome/communityhome.php:155 #: ../../view/theme/diabook/theme.php:562 ../../include/text.php:1397 -#: ../../include/conversation.php:117 ../../include/conversation.php:247 +#: ../../include/conversation.php:117 ../../include/conversation.php:245 msgid "event" msgstr "" @@ -6094,68 +6150,68 @@ msgstr "" msgid "Show forumlists/forums on profile forumlist" msgstr "" -#: ../../addon/impressum/impressum.php:36 +#: ../../addon/impressum/impressum.php:37 msgid "Impressum" msgstr "" -#: ../../addon/impressum/impressum.php:49 -#: ../../addon/impressum/impressum.php:51 -#: ../../addon/impressum/impressum.php:83 +#: ../../addon/impressum/impressum.php:50 +#: ../../addon/impressum/impressum.php:52 +#: ../../addon/impressum/impressum.php:84 msgid "Site Owner" msgstr "" -#: ../../addon/impressum/impressum.php:49 -#: ../../addon/impressum/impressum.php:87 +#: ../../addon/impressum/impressum.php:50 +#: ../../addon/impressum/impressum.php:88 msgid "Email Address" msgstr "" -#: ../../addon/impressum/impressum.php:54 -#: ../../addon/impressum/impressum.php:85 +#: ../../addon/impressum/impressum.php:55 +#: ../../addon/impressum/impressum.php:86 msgid "Postal Address" msgstr "" -#: ../../addon/impressum/impressum.php:60 +#: ../../addon/impressum/impressum.php:61 msgid "" "The impressum addon needs to be configured!
    Please add at least the " "owner variable to your config file. For other variables please " "refer to the README file of the addon." msgstr "" -#: ../../addon/impressum/impressum.php:83 +#: ../../addon/impressum/impressum.php:84 msgid "The page operators name." msgstr "" -#: ../../addon/impressum/impressum.php:84 +#: ../../addon/impressum/impressum.php:85 msgid "Site Owners Profile" msgstr "" -#: ../../addon/impressum/impressum.php:84 +#: ../../addon/impressum/impressum.php:85 msgid "Profile address of the operator." msgstr "" -#: ../../addon/impressum/impressum.php:85 +#: ../../addon/impressum/impressum.php:86 msgid "How to contact the operator via snail mail. You can use BBCode here." msgstr "" -#: ../../addon/impressum/impressum.php:86 +#: ../../addon/impressum/impressum.php:87 msgid "Notes" msgstr "" -#: ../../addon/impressum/impressum.php:86 +#: ../../addon/impressum/impressum.php:87 msgid "" "Additional notes that are displayed beneath the contact information. You can " "use BBCode here." msgstr "" -#: ../../addon/impressum/impressum.php:87 +#: ../../addon/impressum/impressum.php:88 msgid "How to contact the operator via email. (will be displayed obfuscated)" msgstr "" -#: ../../addon/impressum/impressum.php:88 +#: ../../addon/impressum/impressum.php:89 msgid "Footer note" msgstr "" -#: ../../addon/impressum/impressum.php:88 +#: ../../addon/impressum/impressum.php:89 msgid "Text for the footer. You can use BBCode here." msgstr "" @@ -6465,6 +6521,58 @@ msgstr "" msgid "Post to InsaneJournal by default" msgstr "" +#: ../../addon/jappixmini/jappixmini.php:266 +msgid "Jappix Mini addon settings" +msgstr "" + +#: ../../addon/jappixmini/jappixmini.php:268 +msgid "Activate addon" +msgstr "" + +#: ../../addon/jappixmini/jappixmini.php:271 +msgid "Do not insert the Jappixmini Chat-Widget into the webinterface" +msgstr "" + +#: ../../addon/jappixmini/jappixmini.php:274 +msgid "Jabber username" +msgstr "" + +#: ../../addon/jappixmini/jappixmini.php:277 +msgid "Jabber server" +msgstr "" + +#: ../../addon/jappixmini/jappixmini.php:281 +msgid "Jabber BOSH host" +msgstr "" + +#: ../../addon/jappixmini/jappixmini.php:285 +msgid "Jabber password" +msgstr "" + +#: ../../addon/jappixmini/jappixmini.php:290 +msgid "Encrypt Jabber password with Friendica password (recommended)" +msgstr "" + +#: ../../addon/jappixmini/jappixmini.php:293 +msgid "Friendica password" +msgstr "" + +#: ../../addon/jappixmini/jappixmini.php:296 +msgid "Approve subscription requests from Friendica contacts automatically" +msgstr "" + +#: ../../addon/jappixmini/jappixmini.php:299 +msgid "Subscribe to Friendica contacts automatically" +msgstr "" + +#: ../../addon/jappixmini/jappixmini.php:302 +msgid "Purge internal list of jabber addresses of contacts" +msgstr "" + +#: ../../addon/jappixmini/jappixmini.php:308 +msgid "Add contact" +msgstr "" + #: ../../addon/viewsrc/viewsrc.php:37 msgid "View Source" msgstr "" @@ -6897,7 +7005,7 @@ msgstr "" #: ../../view/theme/cleanzero/config.php:82 #: ../../view/theme/diabook/config.php:192 -#: ../../view/theme/quattro/config.php:54 ../../view/theme/dispy/config.php:72 +#: ../../view/theme/quattro/config.php:55 ../../view/theme/dispy/config.php:72 msgid "Theme settings" msgstr "" @@ -6916,7 +7024,7 @@ msgid "Set theme width" msgstr "" #: ../../view/theme/cleanzero/config.php:86 -#: ../../view/theme/quattro/config.php:56 +#: ../../view/theme/quattro/config.php:57 msgid "Color scheme" msgstr "" @@ -7091,15 +7199,15 @@ msgstr "" msgid "Last tweets" msgstr "" -#: ../../view/theme/quattro/config.php:55 +#: ../../view/theme/quattro/config.php:56 msgid "Alignment" msgstr "" -#: ../../view/theme/quattro/config.php:55 +#: ../../view/theme/quattro/config.php:56 msgid "Left" msgstr "" -#: ../../view/theme/quattro/config.php:55 +#: ../../view/theme/quattro/config.php:56 msgid "Center" msgstr "" @@ -7377,7 +7485,7 @@ msgid "Sex Addict" msgstr "" #: ../../include/profile_selectors.php:42 ../../include/user.php:278 -#: ../../include/user.php:283 +#: ../../include/user.php:282 msgid "Friends" msgstr "" @@ -7520,7 +7628,7 @@ msgstr[1] "" msgid "poke" msgstr "" -#: ../../include/text.php:719 ../../include/conversation.php:212 +#: ../../include/text.php:719 ../../include/conversation.php:210 msgid "poked" msgstr "" @@ -7799,7 +7907,7 @@ msgstr "" msgid "End this session" msgstr "" -#: ../../include/nav.php:49 ../../boot.php:1659 +#: ../../include/nav.php:49 ../../boot.php:1665 msgid "Status" msgstr "" @@ -8029,12 +8137,12 @@ msgstr "" msgid "%1$d %2$s ago" msgstr "" -#: ../../include/datetime.php:472 ../../include/items.php:1621 +#: ../../include/datetime.php:472 ../../include/items.php:1683 #, php-format msgid "%s's birthday" msgstr "" -#: ../../include/datetime.php:473 ../../include/items.php:1622 +#: ../../include/datetime.php:473 ../../include/items.php:1684 #, php-format msgid "Happy Birthday %s" msgstr "" @@ -8308,15 +8416,15 @@ msgstr "" msgid "following" msgstr "" -#: ../../include/items.php:3220 +#: ../../include/items.php:3294 msgid "A new person is sharing with you at " msgstr "" -#: ../../include/items.php:3220 +#: ../../include/items.php:3294 msgid "You have a new follower at " msgstr "" -#: ../../include/items.php:3901 +#: ../../include/items.php:3975 msgid "Archives" msgstr "" @@ -8410,151 +8518,151 @@ msgstr "" msgid "stopped following" msgstr "" -#: ../../include/Contact.php:220 ../../include/conversation.php:1033 +#: ../../include/Contact.php:220 ../../include/conversation.php:1089 msgid "Poke" msgstr "" -#: ../../include/Contact.php:221 ../../include/conversation.php:1027 +#: ../../include/Contact.php:221 ../../include/conversation.php:1083 msgid "View Status" msgstr "" -#: ../../include/Contact.php:222 ../../include/conversation.php:1028 +#: ../../include/Contact.php:222 ../../include/conversation.php:1084 msgid "View Profile" msgstr "" -#: ../../include/Contact.php:223 ../../include/conversation.php:1029 +#: ../../include/Contact.php:223 ../../include/conversation.php:1085 msgid "View Photos" msgstr "" #: ../../include/Contact.php:224 ../../include/Contact.php:237 -#: ../../include/conversation.php:1030 +#: ../../include/conversation.php:1086 msgid "Network Posts" msgstr "" #: ../../include/Contact.php:225 ../../include/Contact.php:237 -#: ../../include/conversation.php:1031 +#: ../../include/conversation.php:1087 msgid "Edit Contact" msgstr "" #: ../../include/Contact.php:226 ../../include/Contact.php:237 -#: ../../include/conversation.php:1032 +#: ../../include/conversation.php:1088 msgid "Send PM" msgstr "" -#: ../../include/conversation.php:208 +#: ../../include/conversation.php:206 #, php-format msgid "%1$s poked %2$s" msgstr "" -#: ../../include/conversation.php:292 +#: ../../include/conversation.php:290 msgid "post/item" msgstr "" -#: ../../include/conversation.php:293 +#: ../../include/conversation.php:291 #, php-format msgid "%1$s marked %2$s's %3$s as favorite" msgstr "" -#: ../../include/conversation.php:933 +#: ../../include/conversation.php:989 msgid "Delete Selected Items" msgstr "" -#: ../../include/conversation.php:1091 +#: ../../include/conversation.php:1147 #, php-format msgid "%s likes this." msgstr "" -#: ../../include/conversation.php:1091 +#: ../../include/conversation.php:1147 #, php-format msgid "%s doesn't like this." msgstr "" -#: ../../include/conversation.php:1095 +#: ../../include/conversation.php:1151 #, php-format msgid "%2$d people like this." msgstr "" -#: ../../include/conversation.php:1097 +#: ../../include/conversation.php:1153 #, php-format msgid "%2$d people don't like this." msgstr "" -#: ../../include/conversation.php:1103 +#: ../../include/conversation.php:1159 msgid "and" msgstr "" -#: ../../include/conversation.php:1106 +#: ../../include/conversation.php:1162 #, php-format msgid ", and %d other people" msgstr "" -#: ../../include/conversation.php:1107 +#: ../../include/conversation.php:1163 #, php-format msgid "%s like this." msgstr "" -#: ../../include/conversation.php:1107 +#: ../../include/conversation.php:1163 #, php-format msgid "%s don't like this." msgstr "" -#: ../../include/conversation.php:1131 ../../include/conversation.php:1148 +#: ../../include/conversation.php:1187 ../../include/conversation.php:1204 msgid "Visible to everybody" msgstr "" -#: ../../include/conversation.php:1133 ../../include/conversation.php:1150 +#: ../../include/conversation.php:1189 ../../include/conversation.php:1206 msgid "Please enter a video link/URL:" msgstr "" -#: ../../include/conversation.php:1134 ../../include/conversation.php:1151 +#: ../../include/conversation.php:1190 ../../include/conversation.php:1207 msgid "Please enter an audio link/URL:" msgstr "" -#: ../../include/conversation.php:1135 ../../include/conversation.php:1152 +#: ../../include/conversation.php:1191 ../../include/conversation.php:1208 msgid "Tag term:" msgstr "" -#: ../../include/conversation.php:1137 ../../include/conversation.php:1154 +#: ../../include/conversation.php:1193 ../../include/conversation.php:1210 msgid "Where are you right now?" msgstr "" -#: ../../include/conversation.php:1197 +#: ../../include/conversation.php:1253 msgid "upload photo" msgstr "" -#: ../../include/conversation.php:1199 +#: ../../include/conversation.php:1255 msgid "attach file" msgstr "" -#: ../../include/conversation.php:1201 +#: ../../include/conversation.php:1257 msgid "web link" msgstr "" -#: ../../include/conversation.php:1202 +#: ../../include/conversation.php:1258 msgid "Insert video link" msgstr "" -#: ../../include/conversation.php:1203 +#: ../../include/conversation.php:1259 msgid "video link" msgstr "" -#: ../../include/conversation.php:1204 +#: ../../include/conversation.php:1260 msgid "Insert audio link" msgstr "" -#: ../../include/conversation.php:1205 +#: ../../include/conversation.php:1261 msgid "audio link" msgstr "" -#: ../../include/conversation.php:1207 +#: ../../include/conversation.php:1263 msgid "set location" msgstr "" -#: ../../include/conversation.php:1209 +#: ../../include/conversation.php:1265 msgid "clear location" msgstr "" -#: ../../include/conversation.php:1216 +#: ../../include/conversation.php:1272 msgid "permissions" msgstr "" @@ -8652,18 +8760,18 @@ msgstr "" msgid "Events this week:" msgstr "" -#: ../../boot.php:1662 +#: ../../boot.php:1668 msgid "Status Messages and Posts" msgstr "" -#: ../../boot.php:1669 +#: ../../boot.php:1675 msgid "Profile Details" msgstr "" -#: ../../boot.php:1686 +#: ../../boot.php:1692 msgid "Events and Calendar" msgstr "" -#: ../../boot.php:1693 +#: ../../boot.php:1699 msgid "Only You Can See This" msgstr "" diff --git a/view/admin_site.tpl b/view/admin_site.tpl index 6564565f7..ceba97d3f 100644 --- a/view/admin_site.tpl +++ b/view/admin_site.tpl @@ -76,7 +76,7 @@ {{ inc field_checkbox.tpl with $field=$dfrn_only }}{{ endinc }} {{ inc field_input.tpl with $field=$global_directory }}{{ endinc }} {{ inc field_checkbox.tpl with $field=$thread_allow }}{{ endinc }} - {{ inc field_checkbox.tpl with $field=$newuser_public }}{{ endinc }} + {{ inc field_checkbox.tpl with $field=$newuser_private }}{{ endinc }}
    diff --git a/view/admin_users.tpl b/view/admin_users.tpl index f67e4a0f7..c9ab0e3f7 100644 --- a/view/admin_users.tpl +++ b/view/admin_users.tpl @@ -70,11 +70,20 @@ $u.register_date $u.login_date $u.lastitem_date - $u.page-flags - + $u.page-flags {{ if $u.is_admin }}($siteadmin){{ endif }} + + {{ if $u.is_admin }} +   + {{ else }} + + {{ endif }} - - + {{ if $u.is_admin }} +   + {{ else }} + + + {{ endif }} {{ endfor }} diff --git a/view/comment_item.tpl b/view/comment_item.tpl index 98173aa30..3de24ca8d 100644 --- a/view/comment_item.tpl +++ b/view/comment_item.tpl @@ -1,10 +1,9 @@ + {{ if $threaded }} +
    + {{ else }}
    - {{ if $threaded }} - $comment -
    + + +
    diff --git a/view/theme/cleanzero/nav.tpl b/view/theme/cleanzero/nav.tpl index 9fe5ac0fe..65f018591 100644 --- a/view/theme/cleanzero/nav.tpl +++ b/view/theme/cleanzero/nav.tpl @@ -71,3 +71,15 @@ + diff --git a/view/theme/darkzero/style.css b/view/theme/darkzero/style.css index dda180bbd..8b570a84f 100644 --- a/view/theme/darkzero/style.css +++ b/view/theme/darkzero/style.css @@ -23,13 +23,23 @@ div.wall-item-content-wrapper.shiny { background-image: url('shiny.png'); } nav #banner #logo-text a { color: #ffffff; } .wall-item-content-wrapper { -border: 1px solid #444444; -background: #444; - + border: 1px solid #444444; + background: #444444; +} +.wall-item-outside-wrapper.threaded > .wall-item-content-wrapper { + -moz-border-radius: 3px 3px 0px; + border-radius: 3px 3px 0px; } .wall-item-tools { background-color: #444444; background-image: none;} -.comment-wwedit-wrapper{ background-color: #444444; } -.toplevel_item > .wall-item-comment-wrapper > .comment-wwedit-wrapper{ background-color: #333333; } +.comment-wwedit-wrapper{ + background-color: #333333; +} +.comment-wwedit-wrapper.threaded { + border: solid #444444; + border-width: 0px 3px 3px; + -moz-border-radius: 0px 0px 3px 3px; + border-radius: 0px 0px 3px 3px; +} .comment-edit-preview{ color: #000000; } .wall-item-content-wrapper.comment { background-color: #444444; border: 0px;} .photo-top-album-name{ background-color: #333333; } diff --git a/view/theme/darkzero/theme.php b/view/theme/darkzero/theme.php index e6b469bff..dcb65589c 100644 --- a/view/theme/darkzero/theme.php +++ b/view/theme/darkzero/theme.php @@ -45,11 +45,19 @@ function insertFormatting(comment,BBcode,id) { return true; } -function cmtBbOpen(id) { - $(".comment-edit-bb-" + id).show(); +function cmtBbOpen(comment, id) { + if($(comment).hasClass('comment-edit-text-full')) { + $(".comment-edit-bb-" + id).show(); + return true; + } + return false; } -function cmtBbClose(id) { - $(".comment-edit-bb-" + id).hide(); +function cmtBbClose(comment, id) { + if($(comment).hasClass('comment-edit-text-empty')) { + $(".comment-edit-bb-" + id).hide(); + return true; + } + return false; } $(document).ready(function() { @@ -96,4 +104,4 @@ $('.savedsearchterm').hover( EOT; -} \ No newline at end of file +} diff --git a/view/theme/diabook/bottom.tpl b/view/theme/diabook/bottom.tpl index 0ab7de78e..08952aad6 100644 --- a/view/theme/diabook/bottom.tpl +++ b/view/theme/diabook/bottom.tpl @@ -130,7 +130,7 @@ $(document).ready(function() { $(".comment-edit-bb-" + id).hide(); } - $(document).ready(function(){ + /*$(document).ready(function(){ var doctitle = document.title; function checkNotify() { if(document.getElementById("notify-update").innerHTML != "") @@ -139,7 +139,17 @@ $(document).ready(function() { document.title = doctitle; }; setInterval(function () {checkNotify();}, 10 * 1000); - }) - - + })*/ + + diff --git a/view/theme/dispy/bottom.tpl b/view/theme/dispy/bottom.tpl index 0bcc3aca4..82f020170 100644 --- a/view/theme/dispy/bottom.tpl +++ b/view/theme/dispy/bottom.tpl @@ -56,4 +56,16 @@ function checkNotify() { }; setInterval(function () {checkNotify();}, 10 * 1000); } + +$(document).ready(function(){ +var doctitle = document.title; +function checkNotify() { +if(document.getElementById("notify-update").innerHTML != "") +document.title = "("+document.getElementById("notify-update").innerHTML+") " + doctitle; +else +document.title = doctitle; +}; +setInterval(function () {checkNotify();}, 10 * 1000); +}) + diff --git a/view/theme/duepuntozero/comment_item.tpl b/view/theme/duepuntozero/comment_item.tpl index f64ae753b..87e060571 100755 --- a/view/theme/duepuntozero/comment_item.tpl +++ b/view/theme/duepuntozero/comment_item.tpl @@ -1,10 +1,9 @@ + {{ if $threaded }} +
    + {{ else }}
    - {{ if $threaded }} - $comment -
    diff --git a/view/theme/frost-mobile/default.php b/view/theme/frost-mobile/default.php index d076c10f0..c2a20255f 100644 --- a/view/theme/frost-mobile/default.php +++ b/view/theme/frost-mobile/default.php @@ -21,6 +21,9 @@
    +
    @@ -33,7 +36,10 @@
    module === 'contacts') && x($page,'aside')) echo $page['aside']; ?> -
    +
    diff --git a/view/theme/frost-mobile/end.tpl b/view/theme/frost-mobile/end.tpl index 993218133..623b99a24 100644 --- a/view/theme/frost-mobile/end.tpl +++ b/view/theme/frost-mobile/end.tpl @@ -5,8 +5,6 @@ --> - - @@ -16,5 +14,4 @@ - diff --git a/view/theme/frost-mobile/head.tpl b/view/theme/frost-mobile/head.tpl index a849f4459..111f5f617 100644 --- a/view/theme/frost-mobile/head.tpl +++ b/view/theme/frost-mobile/head.tpl @@ -27,4 +27,7 @@ var updateInterval = $update_interval; var localUser = {{ if $local_user }}$local_user{{ else }}false{{ endif }}; + + + diff --git a/view/theme/frost-mobile/images/noglobe.png b/view/theme/frost-mobile/images/noglobe.png new file mode 100644 index 000000000..b5aceb6d5 Binary files /dev/null and b/view/theme/frost-mobile/images/noglobe.png differ diff --git a/view/theme/frost-mobile/jot_geotag.tpl b/view/theme/frost-mobile/jot_geotag.tpl new file mode 100644 index 000000000..3f8bee91a --- /dev/null +++ b/view/theme/frost-mobile/jot_geotag.tpl @@ -0,0 +1,11 @@ + + if(navigator.geolocation) { + navigator.geolocation.getCurrentPosition(function(position) { + var lat = position.coords.latitude.toFixed(4); + var lon = position.coords.longitude.toFixed(4); + + $j('#jot-coord').val(lat + ', ' + lon); + $j('#profile-nolocation-wrapper').show(); + }); + } + diff --git a/view/theme/frost-mobile/js/main.js b/view/theme/frost-mobile/js/main.js index aaa69e707..a84b08730 100644 --- a/view/theme/frost-mobile/js/main.js +++ b/view/theme/frost-mobile/js/main.js @@ -78,7 +78,7 @@ if( last_popup_menu ) { if( '#' + last_popup_menu.attr('id') !== $j(e.target).attr('rel')) { last_popup_menu.hide(); - if (last_popup_menu.attr('id') == "nav-notifications-menu" ) $j('section').show(); + if (last_popup_menu.attr('id') == "nav-notifications-menu" ) $j('.main-container').show(); last_popup_button.removeClass("selected"); last_popup_menu = null; last_popup_button = null; @@ -100,13 +100,13 @@ if (menu.css("display") == "none") { $j(this).parent().addClass("selected"); menu.show(); - if (menu.attr('id') == "nav-notifications-menu" ) $j('section').hide(); + if (menu.attr('id') == "nav-notifications-menu" ) $j('.main-container').hide(); last_popup_menu = menu; last_popup_button = $j(this).parent(); } else { $j(this).parent().removeClass("selected"); menu.hide(); - if (menu.attr('id') == "nav-notifications-menu" ) $j('section').show(); + if (menu.attr('id') == "nav-notifications-menu" ) $j('.main-container').show(); last_popup_menu = null; last_popup_button = null; } @@ -315,6 +315,22 @@ prev = ident; }); + + var bimgs = $j(".wall-item-body > img").not(function() { return this.complete; }); + var bimgcount = bimgs.length; + + if (bimgcount) { + bimgs.load(function() { + bimgcount--; + if (! bimgcount) { + collapseHeight(); + + } + }); + } else { + collapseHeight(); + } + // reset vars for inserting individual items /*prev = 'live-' + src; @@ -349,22 +365,6 @@ } /* autocomplete @nicknames */ $j(".comment-edit-form textarea").contact_autocomplete(baseurl+"/acl"); - - var bimgs = $j(".wall-item-body > img").not(function() { return this.complete; }); - var bimgcount = bimgs.length; - - if (bimgcount) { - bimgs.load(function() { - bimgcount--; - if (! bimgcount) { - collapseHeight(); - - } - }); - } else { - collapseHeight(); - } - }); } diff --git a/view/theme/frost-mobile/js/main.min.js b/view/theme/frost-mobile/js/main.min.js index 95f99dce7..f45e50562 100644 --- a/view/theme/frost-mobile/js/main.min.js +++ b/view/theme/frost-mobile/js/main.min.js @@ -1 +1 @@ -function openClose(e){document.getElementById(e).style.display=="block"?document.getElementById(e).style.display="none":document.getElementById(e).style.display="block"}function openMenu(e){document.getElementById(e).style.display="block"}function closeMenu(e){document.getElementById(e).style.display="none"}function NavUpdate(){if(!stopped){var e="ping"+(localUser!=0?"?f=&uid="+localUser:"");$j.get(e,function(e){$j(e).find("result").each(function(){$j("nav").trigger("nav-update",this),$j("#live-network").length&&(src="network",liveUpdate()),$j("#live-profile").length&&(src="profile",liveUpdate()),$j("#live-community").length&&(src="community",liveUpdate()),$j("#live-notes").length&&(src="notes",liveUpdate()),$j("#live-display").length&&liking&&(liking=0,window.location.href=window.location.href),$j("#live-photos").length&&liking&&(liking=0,window.location.href=window.location.href)})})}timer=setTimeout(NavUpdate,updateInterval)}function liveUpdate(){if(src==null||stopped||!profile_uid){$j(".like-rotator").hide();return}if($j(".comment-edit-text-full").length||in_progress){livetime&&clearTimeout(livetime),livetime=setTimeout(liveUpdate,1e4);return}livetime!=null&&(livetime=null),prev="live-"+src,in_progress=!0;var e=netargs.length?"/"+netargs:"",t="update_"+src+e+"&p="+profile_uid+"&page="+profile_page+"&msie="+(msie?1:0);$j.get(t,function(e){in_progress=!1,$j(".toplevel_item",e).each(function(){var e=$j(this).attr("id");$j("#"+e).length==0&&profile_page==1?($j("img",this).each(function(){$j(this).attr("src",$j(this).attr("dst"))}),$j("#"+prev).after($j(this))):($j("img",this).each(function(){$j(this).attr("src",$j(this).attr("dst"))}),$j("#"+e).replaceWith($j(this))),prev=e}),$j(".like-rotator").hide(),commentBusy&&(commentBusy=!1,$j("body").css("cursor","auto")),$j(".comment-edit-form textarea").contact_autocomplete(baseurl+"/acl");var t=$j(".wall-item-body > img").not(function(){return this.complete}),n=t.length;n?t.load(function(){n--,n||collapseHeight()}):collapseHeight()})}function collapseHeight(){$j(".wall-item-body").each(function(){$j(this).height()>310&&($j(this).hasClass("divmore")||($j(this).divgrow({initialHeight:300,showBrackets:!1,speed:0}),$j(this).addClass("divmore")))})}function imgbright(e){$j(e).removeClass("drophide").addClass("drop")}function imgdull(e){$j(e).removeClass("drop").addClass("drophide")}function dolike(e,t){unpause(),$j("#like-rotator-"+e.toString()).show(),$j.get("like/"+e.toString()+"?verb="+t,NavUpdate),liking=1}function dostar(e){e=e.toString(),$j.get("starred/"+e,function(t){t.match(/1/)?($j("#starred-"+e).addClass("starred"),$j("#starred-"+e).removeClass("unstarred"),$j("#star-"+e).addClass("hidden"),$j("#unstar-"+e).removeClass("hidden")):($j("#starred-"+e).addClass("unstarred"),$j("#starred-"+e).removeClass("starred"),$j("#star-"+e).removeClass("hidden"),$j("#unstar-"+e).addClass("hidden"))})}function getPosition(e){var t={x:0,y:0};if(e.touches[0].pageX||e.touches[0].pageY)t.x=e.touches[0].pageX,t.y=e.touches[0].pageY;else if(e.touches[0].clientX||e.touches[0].clientY)t.x=e.touches[0].clientX+(document.documentElement.scrollLeft||document.body.scrollLeft)-document.documentElement.clientLeft,t.y=e.touches[0].clientY+(document.documentElement.scrollTop||document.body.scrollTop)-document.documentElement.clientTop;else if(e.touches[0].x||e.touches[0].y)t.touches[0].x=e.touches[0].x,t.touches[0].y=e.touches[0].y;return t}function lockview(e,t){e=e||window.event,cursor=getPosition(e),lockvisible?lockviewhide():(lockvisible=!0,$j.get("lockview/"+t,function(e){$j("#panel").html(e),$j("#panel").css({left:cursor.x+5,top:cursor.y+5}),$j("#panel").show()}))}function lockviewhide(){lockvisible=!1,$j("#panel").hide()}function post_comment(e){return unpause(),commentBusy=!0,$j("body").css("cursor","wait"),$j("#comment-preview-inp-"+e).val("0"),$j.post("item",$j("#comment-edit-form-"+e).serialize(),function(t){if(t.success){$j("#comment-edit-wrapper-"+e).hide(),$j("#comment-edit-text-"+e).val("");var n=document.getElementById("comment-edit-text-"+e);n&&commentClose(n,e),timer&&clearTimeout(timer),timer=setTimeout(NavUpdate,10)}t.reload&&(window.location.href=t.reload)},"json"),!1}function preview_comment(e){return $j("#comment-preview-inp-"+e).val("1"),$j("#comment-edit-preview-"+e).show(),$j.post("item",$j("#comment-edit-form-"+e).serialize(),function(t){t.preview&&($j("#comment-edit-preview-"+e).html(t.preview),$j("#comment-edit-preview-"+e+" a").click(function(){return!1}))},"json"),!0}function preview_post(){return $j("#jot-preview").val("1"),$j("#jot-preview-content").show(),tinyMCE.triggerSave(),$j.post("item",$j("#profile-jot-form").serialize(),function(e){e.preview&&($j("#jot-preview-content").html(e.preview),$j("#jot-preview-content a").click(function(){return!1}))},"json"),$j("#jot-preview").val("0"),!0}function unpause(){totStopped=!1,stopped=!1,$j("#pause").html("")}function bin2hex(e){var t,n,r=0,i=[];e+="",r=e.length;for(n=0;n'+e.desc+'
    '+e.version+'
    '+e.credits+"
    ")})}var src=null,prev=null,livetime=null,msie=!1,stopped=!1,totStopped=!1,timer=null,pr=0,liking=0,in_progress=!1,langSelect=!1,commentBusy=!1,last_popup_menu=null,last_popup_button=null;$j(function(){function e(e){last_popup_menu&&"#"+last_popup_menu.attr("id")!==$j(e.target).attr("rel")&&(last_popup_menu.hide(),last_popup_menu.attr("id")=="nav-notifications-menu"&&$j("section").show(),last_popup_button.removeClass("selected"),last_popup_menu=null,last_popup_button=null)}$j.ajaxSetup({cache:!1}),msie=$j.browser.msie,$j(".onoff input").each(function(){val=$j(this).val(),id=$j(this).attr("id"),$j("#"+id+"_onoff ."+(val==0?"on":"off")).addClass("hidden")}),$j(".onoff > a").click(function(e){e.preventDefault();var t=$j(this).siblings("input"),n=1-t.val(),r=t.attr("id");$j("#"+r+"_onoff ."+(n==0?"on":"off")).addClass("hidden"),$j("#"+r+"_onoff ."+(n==1?"on":"off")).removeClass("hidden"),t.val(n)}),$j("img[rel^=#]").click(function(t){return e(t),menu=$j($j(this).attr("rel")),t.preventDefault(),t.stopPropagation(),menu.attr("popup")=="false"?!1:(menu.css("display")=="none"?($j(this).parent().addClass("selected"),menu.show(),menu.attr("id")=="nav-notifications-menu"&&$j("section").hide(),last_popup_menu=menu,last_popup_button=$j(this).parent()):($j(this).parent().removeClass("selected"),menu.hide(),menu.attr("id")=="nav-notifications-menu"&&$j("section").show(),last_popup_menu=null,last_popup_button=null),!1)}),$j("html").click(function(t){e(t)});var t=unescape($j("#nav-notifications-template[rel=template]").html()),n=unescape($j("
    ").append($j("#nav-notifications-see-all").clone()).html()),r=unescape($j("
    ").append($j("#nav-notifications-mark-all").clone()).html()),i=unescape($j("#nav-notifications-menu").html());$j("nav").bind("nav-update",function(e,s){var o=$j(s).find("invalid").text();o==1&&(window.location.href=window.location.href);var u=$j(s).find("net").text();u==0?(u="",$j("#net-update").removeClass("show")):$j("#net-update").addClass("show"),$j("#net-update").html(u);var a=$j(s).find("home").text();a==0?(a="",$j("#home-update").removeClass("show")):$j("#home-update").addClass("show"),$j("#home-update").html(a);var f=$j(s).find("intro").text();f==0?(f="",$j("#intro-update").removeClass("show")):$j("#intro-update").addClass("show"),$j("#intro-update").html(f);var l=$j(s).find("mail").text();l==0?(l="",$j("#mail-update").removeClass("show")):$j("#mail-update").addClass("show"),$j("#mail-update").html(l);var f=$j(s).find("intro").text();f==0?(f="",$j("#intro-update-li").removeClass("show")):$j("#intro-update-li").addClass("show"),$j("#intro-update-li").html(f);var l=$j(s).find("mail").text();l==0?(l="",$j("#mail-update-li").removeClass("show")):$j("#mail-update-li").addClass("show"),$j("#mail-update-li").html(l);var c=$j(s).find("notif");c.children("note").length==0?$j("#nav-notifications-menu").html(i):(nnm=$j("#nav-notifications-menu"),nnm.html(n+r),c.children("note").each(function(){e=$j(this),text=e.text().format(""+e.attr("name")+""),html=t.format(e.attr("href"),e.attr("photo"),text,e.attr("date"),e.attr("seen")),nnm.append(html)})),notif=c.attr("count"),notif>0?$j("#nav-notifications-linkmenu").addClass("on"):$j("#nav-notifications-linkmenu").removeClass("on"),notif==0?(notif="",$j("#notify-update").removeClass("show")):$j("#notify-update").addClass("show"),$j("#notify-update").html(notif);var h=$j(s).find("sysmsgs");h.children("notice").each(function(){text=$j(this).text(),$j.jGrowl(text,{sticky:!1,theme:"notice",life:1500})}),h.children("info").each(function(){text=$j(this).text(),$j.jGrowl(text,{sticky:!1,theme:"info",life:1e3})})}),NavUpdate()});var lockvisible=!1;String.prototype.format=function(){var e=this;for(var t=0;t img").not(function(){return this.complete}),n=t.length;n?t.load(function(){n--,n||collapseHeight()}):collapseHeight(),$j(".like-rotator").hide(),commentBusy&&(commentBusy=!1,$j("body").css("cursor","auto")),$j(".comment-edit-form textarea").contact_autocomplete(baseurl+"/acl")})}function collapseHeight(){$j(".wall-item-body").each(function(){$j(this).height()>310&&($j(this).hasClass("divmore")||($j(this).divgrow({initialHeight:300,showBrackets:!1,speed:0}),$j(this).addClass("divmore")))})}function imgbright(e){$j(e).removeClass("drophide").addClass("drop")}function imgdull(e){$j(e).removeClass("drop").addClass("drophide")}function dolike(e,t){unpause(),$j("#like-rotator-"+e.toString()).show(),$j.get("like/"+e.toString()+"?verb="+t,NavUpdate),liking=1}function dostar(e){e=e.toString(),$j.get("starred/"+e,function(t){t.match(/1/)?($j("#starred-"+e).addClass("starred"),$j("#starred-"+e).removeClass("unstarred"),$j("#star-"+e).addClass("hidden"),$j("#unstar-"+e).removeClass("hidden")):($j("#starred-"+e).addClass("unstarred"),$j("#starred-"+e).removeClass("starred"),$j("#star-"+e).removeClass("hidden"),$j("#unstar-"+e).addClass("hidden"))})}function getPosition(e){var t={x:0,y:0};if(e.touches[0].pageX||e.touches[0].pageY)t.x=e.touches[0].pageX,t.y=e.touches[0].pageY;else if(e.touches[0].clientX||e.touches[0].clientY)t.x=e.touches[0].clientX+(document.documentElement.scrollLeft||document.body.scrollLeft)-document.documentElement.clientLeft,t.y=e.touches[0].clientY+(document.documentElement.scrollTop||document.body.scrollTop)-document.documentElement.clientTop;else if(e.touches[0].x||e.touches[0].y)t.touches[0].x=e.touches[0].x,t.touches[0].y=e.touches[0].y;return t}function lockview(e,t){e=e||window.event,cursor=getPosition(e),lockvisible?lockviewhide():(lockvisible=!0,$j.get("lockview/"+t,function(e){$j("#panel").html(e),$j("#panel").css({left:cursor.x+5,top:cursor.y+5}),$j("#panel").show()}))}function lockviewhide(){lockvisible=!1,$j("#panel").hide()}function post_comment(e){return unpause(),commentBusy=!0,$j("body").css("cursor","wait"),$j("#comment-preview-inp-"+e).val("0"),$j.post("item",$j("#comment-edit-form-"+e).serialize(),function(t){if(t.success){$j("#comment-edit-wrapper-"+e).hide(),$j("#comment-edit-text-"+e).val("");var n=document.getElementById("comment-edit-text-"+e);n&&commentClose(n,e),timer&&clearTimeout(timer),timer=setTimeout(NavUpdate,10)}t.reload&&(window.location.href=t.reload)},"json"),!1}function preview_comment(e){return $j("#comment-preview-inp-"+e).val("1"),$j("#comment-edit-preview-"+e).show(),$j.post("item",$j("#comment-edit-form-"+e).serialize(),function(t){t.preview&&($j("#comment-edit-preview-"+e).html(t.preview),$j("#comment-edit-preview-"+e+" a").click(function(){return!1}))},"json"),!0}function preview_post(){return $j("#jot-preview").val("1"),$j("#jot-preview-content").show(),tinyMCE.triggerSave(),$j.post("item",$j("#profile-jot-form").serialize(),function(e){e.preview&&($j("#jot-preview-content").html(e.preview),$j("#jot-preview-content a").click(function(){return!1}))},"json"),$j("#jot-preview").val("0"),!0}function unpause(){totStopped=!1,stopped=!1,$j("#pause").html("")}function bin2hex(e){var t,n,r=0,i=[];e+="",r=e.length;for(n=0;n'+e.desc+'
    '+e.version+'
    '+e.credits+"
    ")})}var src=null,prev=null,livetime=null,msie=!1,stopped=!1,totStopped=!1,timer=null,pr=0,liking=0,in_progress=!1,langSelect=!1,commentBusy=!1,last_popup_menu=null,last_popup_button=null;$j(function(){function e(e){last_popup_menu&&"#"+last_popup_menu.attr("id")!==$j(e.target).attr("rel")&&(last_popup_menu.hide(),last_popup_menu.attr("id")=="nav-notifications-menu"&&$j(".main-container").show(),last_popup_button.removeClass("selected"),last_popup_menu=null,last_popup_button=null)}$j.ajaxSetup({cache:!1}),msie=$j.browser.msie,$j(".onoff input").each(function(){val=$j(this).val(),id=$j(this).attr("id"),$j("#"+id+"_onoff ."+(val==0?"on":"off")).addClass("hidden")}),$j(".onoff > a").click(function(e){e.preventDefault();var t=$j(this).siblings("input"),n=1-t.val(),r=t.attr("id");$j("#"+r+"_onoff ."+(n==0?"on":"off")).addClass("hidden"),$j("#"+r+"_onoff ."+(n==1?"on":"off")).removeClass("hidden"),t.val(n)}),$j("img[rel^=#]").click(function(t){return e(t),menu=$j($j(this).attr("rel")),t.preventDefault(),t.stopPropagation(),menu.attr("popup")=="false"?!1:(menu.css("display")=="none"?($j(this).parent().addClass("selected"),menu.show(),menu.attr("id")=="nav-notifications-menu"&&$j(".main-container").hide(),last_popup_menu=menu,last_popup_button=$j(this).parent()):($j(this).parent().removeClass("selected"),menu.hide(),menu.attr("id")=="nav-notifications-menu"&&$j(".main-container").show(),last_popup_menu=null,last_popup_button=null),!1)}),$j("html").click(function(t){e(t)});var t=unescape($j("#nav-notifications-template[rel=template]").html()),n=unescape($j("
    ").append($j("#nav-notifications-see-all").clone()).html()),r=unescape($j("
    ").append($j("#nav-notifications-mark-all").clone()).html()),i=unescape($j("#nav-notifications-menu").html());$j("nav").bind("nav-update",function(e,s){var o=$j(s).find("invalid").text();o==1&&(window.location.href=window.location.href);var u=$j(s).find("net").text();u==0?(u="",$j("#net-update").removeClass("show")):$j("#net-update").addClass("show"),$j("#net-update").html(u);var a=$j(s).find("home").text();a==0?(a="",$j("#home-update").removeClass("show")):$j("#home-update").addClass("show"),$j("#home-update").html(a);var f=$j(s).find("intro").text();f==0?(f="",$j("#intro-update").removeClass("show")):$j("#intro-update").addClass("show"),$j("#intro-update").html(f);var l=$j(s).find("mail").text();l==0?(l="",$j("#mail-update").removeClass("show")):$j("#mail-update").addClass("show"),$j("#mail-update").html(l);var f=$j(s).find("intro").text();f==0?(f="",$j("#intro-update-li").removeClass("show")):$j("#intro-update-li").addClass("show"),$j("#intro-update-li").html(f);var l=$j(s).find("mail").text();l==0?(l="",$j("#mail-update-li").removeClass("show")):$j("#mail-update-li").addClass("show"),$j("#mail-update-li").html(l);var c=$j(s).find("notif");c.children("note").length==0?$j("#nav-notifications-menu").html(i):(nnm=$j("#nav-notifications-menu"),nnm.html(n+r),c.children("note").each(function(){e=$j(this),text=e.text().format(""+e.attr("name")+""),html=t.format(e.attr("href"),e.attr("photo"),text,e.attr("date"),e.attr("seen")),nnm.append(html)})),notif=c.attr("count"),notif>0?$j("#nav-notifications-linkmenu").addClass("on"):$j("#nav-notifications-linkmenu").removeClass("on"),notif==0?(notif="",$j("#notify-update").removeClass("show")):$j("#notify-update").addClass("show"),$j("#notify-update").html(notif);var h=$j(s).find("sysmsgs");h.children("notice").each(function(){text=$j(this).text(),$j.jGrowl(text,{sticky:!1,theme:"notice",life:1500})}),h.children("info").each(function(){text=$j(this).text(),$j.jGrowl(text,{sticky:!1,theme:"info",life:1e3})})}),NavUpdate()});var lockvisible=!1;String.prototype.format=function(){var e=this;for(var t=0;t"),r=r.replace("&","&"),r=r.replace(""",'"'),$j("#comment-edit-text-"+t).val(n+r)}function qCommentInsert(e,t){var n=$j("#comment-edit-text-"+t).val();n==window.commentEmptyText&&(n="",$j("#comment-edit-text-"+t).addClass("comment-edit-text-full"),$j("#comment-edit-text-"+t).removeClass("comment-edit-text-empty"),openMenu("comment-edit-submit-wrapper-"+t));var r=$j(e).val();r=r.replace("<","<"),r=r.replace(">",">"),r=r.replace("&","&"),r=r.replace(""",'"'),$j("#comment-edit-text-"+t).val(n+r),$j(e).val("")}function showHideComments(e){$j("#collapsed-comments-"+e).is(":visible")?($j("#collapsed-comments-"+e).hide(),$j("#hide-comments-"+e).html(window.showMore)):($j("#collapsed-comments-"+e).show(),$j("#hide-comments-"+e).html(window.showFewer))}function jotVideoURL(){reply=prompt(window.vidURL),reply&&reply.length&&addeditortext("[video]"+reply+"[/video]")}function jotAudioURL(){reply=prompt(window.audURL),reply&&reply.length&&addeditortext("[audio]"+reply+"[/audio]")}function jotGetLocation(){reply=prompt(window.whereAreU,$j("#jot-location").val()),reply&&reply.length&&$j("#jot-location").val(reply)}function jotShare(e){$j("#jot-popup").length!=0&&$j("#jot-popup").show(),$j("#like-rotator-"+e).show(),$j.get("share/"+e,function(t){editor||$j("#profile-jot-text").val(""),initEditor(function(){addeditortext(t),$j("#like-rotator-"+e).hide(),$j(window).scrollTop(0)})})}function linkdropper(e){var t=e.dataTransfer.types.contains("text/uri-list");t&&e.preventDefault()}function showEvent(e){}function itemTag(e){reply=prompt(window.term),reply&&reply.length&&(reply=reply.replace("#",""),reply.length&&(commentBusy=!0,$j("body").css("cursor","wait"),$j.get("tagger/"+e+"?term="+reply,NavUpdate),liking=1))}function itemFiler(e){$j.get("filer/",function(t){var n=$j("#id_term_label",t).text();reply=prompt(n),reply&&reply.length&&(commentBusy=!0,$j("body").css("cursor","wait"),$j.get("filer/"+e+"?term="+reply,NavUpdate),liking=1)})}function jotClearLocation(){$j("#jot-coord").val(""),$j("#profile-nolocation-wrapper").hide()}function addeditortext(e){if(plaintext=="none"){var t=$j("#profile-jot-text").val();$j("#profile-jot-text").val(t+e)}}$j(document).ready(function(){$j("#profile-jot-text").focus(enableOnUser),$j("#profile-jot-text").click(enableOnUser);if(typeof window.AjaxUpload!="undefined")switch(window.ajaxType){case"jot-header":var e=new window.AjaxUpload("wall-image-upload",{action:"wall_upload/"+window.nickname,name:"userfile",onSubmit:function(e,t){$j("#profile-rotator").show()},onComplete:function(e,t){addeditortext(t),$j("#profile-rotator").hide()}}),t=new window.AjaxUpload("wall-file-upload",{action:"wall_attach/"+window.nickname,name:"userfile",onSubmit:function(e,t){$j("#profile-rotator").show()},onComplete:function(e,t){addeditortext(t),$j("#profile-rotator").hide()}});break;case"msg-header":var e=new window.AjaxUpload("prvmail-upload",{action:"wall_upload/"+window.nickname,name:"userfile",onSubmit:function(e,t){$j("#profile-rotator").show()},onComplete:function(e,t){tinyMCE.execCommand("mceInsertRawHTML",!1,t),$j("#profile-rotator").hide()}});break;default:}typeof acl=="undefined"&&(acl=new ACL(baseurl+"/acl",[window.allowCID,window.allowGID,window.denyCID,window.denyGID])),window.autoCompleteType=="display-head"&&$j(".comment-wwedit-wrapper textarea").contact_autocomplete(baseurl+"/acl");if(window.aclType=="event_head"){$j("#events-calendar").fullCalendar({events:baseurl+"/events/json/",header:{left:"prev,next today",center:"title",right:"month,agendaWeek,agendaDay"},timeFormat:"H(:mm)",eventClick:function(e,t,n){showEvent(e.id)},eventRender:function(e,t,n){if(e.item["author-name"]==null)return;switch(n.name){case"month":t.find(".fc-event-title").html("{1} : {2}".format(e.item["author-avatar"],e.item["author-name"],e.title));break;case"agendaWeek":t.find(".fc-event-title").html("{1}

    {2}

    {3}

    ".format(e.item["author-avatar"],e.item["author-name"],e.item.desc,e.item.location));break;case"agendaDay":t.find(".fc-event-title").html("{1}

    {2}

    {3}

    ".format(e.item["author-avatar"],e.item["author-name"],e.item.desc,e.item.location))}}});var n=location.href.replace(baseurl,"").split("/");n.length>=4&&$j("#events-calendar").fullCalendar("gotoDate",n[2],n[3]-1);var r=location.hash.split("-");r.length==2&&r[0]=="#link"&&showEvent(r[1])}(window.aclType=="settings-head"||window.aclType=="photos_head"||window.aclType=="event_head")&&$j("#contact_allow, #contact_deny, #group_allow, #group_deny").change(function(){var e;$j("#contact_allow option:selected, #contact_deny option:selected, #group_allow option:selected, #group_deny option:selected").each(function(){e=$j(this).text(),$j("#jot-perms-icon").removeClass("unlock").addClass("lock"),$j("#jot-public").hide()}),e==null&&($j("#jot-perms-icon").removeClass("lock").addClass("unlock"),$j("#jot-public").show())}).trigger("change");switch(window.autocompleteType){case"msg-header":var i=$j("#recip").autocomplete({serviceUrl:baseurl+"/acl",minChars:2,width:350,onSelect:function(e,t){$j("#recip-complete").val(t)}});break;case"contacts-head":var i=$j("#contacts-search").autocomplete({serviceUrl:baseurl+"/acl",minChars:2,width:350});i.setOptions({params:{type:"a"}});break;default:}$j("#event-share-checkbox").change(function(){$j("#event-share-checkbox").is(":checked")?$j("#acl-wrapper").show():$j("#acl-wrapper").hide()}).trigger("change"),$j(".popupbox").click(function(){var e=$j($j(this).attr("href")).parent();return e.css("display")=="none"?e.show():e.hide(),!1})}),$j(function(){$j("nav").bind("nav-update",function(e,t){var n=$j("#pending-update"),r=$j(t).find("register").text();r=="0"?(r="",n.hide()):n.show(),n.html(r)})});var editor=!1,textlen=0,plaintext="none",ispublic=window.isPublic;switch(window.ajaxType){case"jot-header":function jotGetLink(){reply=prompt(window.linkURL),reply&&reply.length&&(reply=bin2hex(reply),$j("#profile-rotator").show(),$j.get("parse_url?binurl="+reply,function(e){addeditortext(e),$j("#profile-rotator").hide()}))}function linkdrop(e){var t=e.dataTransfer.getData("text/uri-list");e.target.textContent=t,e.preventDefault(),t&&t.length&&(t=bin2hex(t),$j("#profile-rotator").show(),$j.get("parse_url?binurl="+t,function(e){editor||$j("#profile-jot-text").val(""),initEditor(function(){addeditortext(e),$j("#profile-rotator").hide()})}))}break;case"msg-header":case"wallmsg-header":function jotGetLink(){reply=prompt(window.linkURL),reply&&reply.length&&($j("#profile-rotator").show(),$j.get("parse_url?url="+reply,function(e){tinyMCE.execCommand("mceInsertRawHTML",!1,e),$j("#profile-rotator").hide()}))}function linkdrop(e){var t=e.dataTransfer.getData("text/uri-list");e.target.textContent=t,e.preventDefault(),t&&t.length&&($j("#profile-rotator").show(),$j.get("parse_url?url="+t,function(e){tinyMCE.execCommand("mceInsertRawHTML",!1,e),$j("#profile-rotator").hide()}))}break;default:}typeof window.geoTag=="function"&&window.geoTag(); \ No newline at end of file +function insertFormatting(e,t,n){var r=$j("#comment-edit-text-"+n).val();r==e&&(r="",$j("#comment-edit-text-"+n).addClass("comment-edit-text-full"),$j("#comment-edit-text-"+n).removeClass("comment-edit-text-empty"),openMenu("comment-edit-submit-wrapper-"+n),$j("#comment-edit-text-"+n).val(r)),textarea=document.getElementById("comment-edit-text-"+n);if(document.selection)textarea.focus(),selected=document.selection.createRange(),t=="url"?selected.text="["+t+"]"+"http://"+selected.text+"[/"+t+"]":selected.text="["+t+"]"+selected.text+"[/"+t+"]";else if(textarea.selectionStart||textarea.selectionStart=="0"){var i=textarea.selectionStart,s=textarea.selectionEnd;t=="url"?textarea.value=textarea.value.substring(0,i)+"["+t+"]"+"http://"+textarea.value.substring(i,s)+"[/"+t+"]"+textarea.value.substring(s,textarea.value.length):textarea.value=textarea.value.substring(0,i)+"["+t+"]"+textarea.value.substring(i,s)+"[/"+t+"]"+textarea.value.substring(s,textarea.value.length)}return!0}function cmtBbOpen(e){$j(".comment-edit-bb-"+e).show()}function cmtBbClose(e){$j(".comment-edit-bb-"+e).hide()}function initEditor(e){if(editor==0){if(plaintext=="none"){$j("#profile-jot-text").css({height:200,color:"#000"}),$j("#profile-jot-text").contact_autocomplete(baseurl+"/acl"),editor=!0,$j("a#jot-perms-icon, a#settings-default-perms-menu").click(function(){var e=$j("#profile-jot-acl-wrapper").parent();return e.css("display")=="none"?e.show():e.hide(),!1}),$j(".jothidden").show(),typeof e!="undefined"&&e();return}}else typeof e!="undefined"&&e()}function enableOnUser(){if(editor)return;$j(this).val(""),initEditor()}function wallInitEditor(){var e=window.editSelect;e!="none"?tinyMCE.init({theme:"advanced",mode:"specific_textareas",editor_selector:/(profile-jot-text|prvmail-text)/,plugins:"bbcode,paste",theme_advanced_buttons1:"bold,italic,underline,undo,redo,link,unlink,image,forecolor",theme_advanced_buttons2:"",theme_advanced_buttons3:"",theme_advanced_toolbar_location:"top",theme_advanced_toolbar_align:"center",theme_advanced_blockformats:"blockquote,code",gecko_spellcheck:!0,paste_text_sticky:!0,entity_encoding:"raw",add_unload_trigger:!1,remove_linebreaks:!1,force_p_newlines:!1,force_br_newlines:!0,forced_root_block:"",convert_urls:!1,content_css:baseurl+"/view/custom_tinymce.css",theme_advanced_path:!1,setup:function(e){e.onInit.add(function(e){e.pasteAsPlainText=!0;var t=e.editorId,n=$j("#"+t);typeof n.attr("tabindex")!="undefined"&&($j("#"+t+"_ifr").attr("tabindex",n.attr("tabindex")),n.attr("tabindex",null))})}}):$j("#prvmail-text").contact_autocomplete(baseurl+"/acl")}function initCrop(){function e(e,t){$("x1").value=e.x1,$("y1").value=e.y1,$("x2").value=e.x2,$("y2").value=e.y2,$("width").value=t.width,$("height").value=t.height}Event.observe(window,"load",function(){new Cropper.ImgWithPreview("croppa",{previewWrap:"previewWrap",minWidth:175,minHeight:175,maxWidth:640,maxHeight:640,ratioDim:{x:100,y:100},displayOnInit:!0,onEndCrop:e})})}function confirmDelete(){return confirm(window.delItem)}function commentOpen(e,t){e.value==window.commentEmptyText&&(e.value="",$j("#comment-edit-text-"+t).addClass("comment-edit-text-full"),$j("#comment-edit-text-"+t).removeClass("comment-edit-text-empty"),$j("#mod-cmnt-wrap-"+t).show(),openMenu("comment-edit-submit-wrapper-"+t))}function commentClose(e,t){e.value==""&&(e.value=window.commentEmptyText,$j("#comment-edit-text-"+t).removeClass("comment-edit-text-full"),$j("#comment-edit-text-"+t).addClass("comment-edit-text-empty"),$j("#mod-cmnt-wrap-"+t).hide(),closeMenu("comment-edit-submit-wrapper-"+t))}function commentInsert(e,t){var n=$j("#comment-edit-text-"+t).val();n==window.commentEmptyText&&(n="",$j("#comment-edit-text-"+t).addClass("comment-edit-text-full"),$j("#comment-edit-text-"+t).removeClass("comment-edit-text-empty"),openMenu("comment-edit-submit-wrapper-"+t));var r=$j(e).html();r=r.replace("<","<"),r=r.replace(">",">"),r=r.replace("&","&"),r=r.replace(""",'"'),$j("#comment-edit-text-"+t).val(n+r)}function qCommentInsert(e,t){var n=$j("#comment-edit-text-"+t).val();n==window.commentEmptyText&&(n="",$j("#comment-edit-text-"+t).addClass("comment-edit-text-full"),$j("#comment-edit-text-"+t).removeClass("comment-edit-text-empty"),openMenu("comment-edit-submit-wrapper-"+t));var r=$j(e).val();r=r.replace("<","<"),r=r.replace(">",">"),r=r.replace("&","&"),r=r.replace(""",'"'),$j("#comment-edit-text-"+t).val(n+r),$j(e).val("")}function showHideComments(e){$j("#collapsed-comments-"+e).is(":visible")?($j("#collapsed-comments-"+e).hide(),$j("#hide-comments-"+e).html(window.showMore)):($j("#collapsed-comments-"+e).show(),$j("#hide-comments-"+e).html(window.showFewer))}function jotVideoURL(){reply=prompt(window.vidURL),reply&&reply.length&&addeditortext("[video]"+reply+"[/video]")}function jotAudioURL(){reply=prompt(window.audURL),reply&&reply.length&&addeditortext("[audio]"+reply+"[/audio]")}function jotGetLocation(){reply=prompt(window.whereAreU,$j("#jot-location").val()),reply&&reply.length&&$j("#jot-location").val(reply)}function jotShare(e){$j("#jot-popup").length!=0&&$j("#jot-popup").show(),$j("#like-rotator-"+e).show(),$j.get("share/"+e,function(t){editor||$j("#profile-jot-text").val(""),initEditor(function(){addeditortext(t),$j("#like-rotator-"+e).hide(),$j(window).scrollTop(0)})})}function linkdropper(e){var t=e.dataTransfer.types.contains("text/uri-list");t&&e.preventDefault()}function showEvent(e){}function itemTag(e){reply=prompt(window.term),reply&&reply.length&&(reply=reply.replace("#",""),reply.length&&(commentBusy=!0,$j("body").css("cursor","wait"),$j.get("tagger/"+e+"?term="+reply,NavUpdate),liking=1))}function itemFiler(e){$j.get("filer/",function(t){var n=$j("#id_term_label",t).text();reply=prompt(n),reply&&reply.length&&(commentBusy=!0,$j("body").css("cursor","wait"),$j.get("filer/"+e+"?term="+reply,NavUpdate),liking=1)})}function jotClearLocation(){$j("#jot-coord").val(""),$j("#profile-nolocation-wrapper").hide()}function addeditortext(e){if(plaintext=="none"){var t=$j("#profile-jot-text").val();$j("#profile-jot-text").val(t+e)}}$j(document).ready(function(){$j("#profile-jot-text").focus(enableOnUser),$j("#profile-jot-text").click(enableOnUser);if(typeof window.AjaxUpload!="undefined")switch(window.ajaxType){case"jot-header":var e=new window.AjaxUpload("wall-image-upload",{action:"wall_upload/"+window.nickname,name:"userfile",onSubmit:function(e,t){$j("#profile-rotator").show()},onComplete:function(e,t){addeditortext(t),$j("#profile-rotator").hide()}}),t=new window.AjaxUpload("wall-file-upload",{action:"wall_attach/"+window.nickname,name:"userfile",onSubmit:function(e,t){$j("#profile-rotator").show()},onComplete:function(e,t){addeditortext(t),$j("#profile-rotator").hide()}});break;case"msg-header":var e=new window.AjaxUpload("prvmail-upload",{action:"wall_upload/"+window.nickname,name:"userfile",onSubmit:function(e,t){$j("#profile-rotator").show()},onComplete:function(e,t){tinyMCE.execCommand("mceInsertRawHTML",!1,t),$j("#profile-rotator").hide()}});break;default:}typeof window.aclInit!="undefined"&&typeof acl=="undefined"&&(acl=new ACL(baseurl+"/acl",[window.allowCID,window.allowGID,window.denyCID,window.denyGID])),window.autoCompleteType=="display-head"&&$j(".comment-wwedit-wrapper textarea").contact_autocomplete(baseurl+"/acl");if(window.aclType=="event_head"){$j("#events-calendar").fullCalendar({events:baseurl+"/events/json/",header:{left:"prev,next today",center:"title",right:"month,agendaWeek,agendaDay"},timeFormat:"H(:mm)",eventClick:function(e,t,n){showEvent(e.id)},eventRender:function(e,t,n){if(e.item["author-name"]==null)return;switch(n.name){case"month":t.find(".fc-event-title").html("{1} : {2}".format(e.item["author-avatar"],e.item["author-name"],e.title));break;case"agendaWeek":t.find(".fc-event-title").html("{1}

    {2}

    {3}

    ".format(e.item["author-avatar"],e.item["author-name"],e.item.desc,e.item.location));break;case"agendaDay":t.find(".fc-event-title").html("{1}

    {2}

    {3}

    ".format(e.item["author-avatar"],e.item["author-name"],e.item.desc,e.item.location))}}});var n=location.href.replace(baseurl,"").split("/");n.length>=4&&$j("#events-calendar").fullCalendar("gotoDate",n[2],n[3]-1);var r=location.hash.split("-");r.length==2&&r[0]=="#link"&&showEvent(r[1])}(window.aclType=="settings-head"||window.aclType=="photos_head"||window.aclType=="event_head")&&$j("#contact_allow, #contact_deny, #group_allow, #group_deny").change(function(){var e;$j("#contact_allow option:selected, #contact_deny option:selected, #group_allow option:selected, #group_deny option:selected").each(function(){e=$j(this).text(),$j("#jot-perms-icon").removeClass("unlock").addClass("lock"),$j("#jot-public").hide()}),e==null&&($j("#jot-perms-icon").removeClass("lock").addClass("unlock"),$j("#jot-public").show())}).trigger("change");switch(window.autocompleteType){case"msg-header":var i=$j("#recip").autocomplete({serviceUrl:baseurl+"/acl",minChars:2,width:350,onSelect:function(e,t){$j("#recip-complete").val(t)}});break;case"contacts-head":var i=$j("#contacts-search").autocomplete({serviceUrl:baseurl+"/acl",minChars:2,width:350});i.setOptions({params:{type:"a"}});break;default:}$j("#event-share-checkbox").change(function(){$j("#event-share-checkbox").is(":checked")?$j("#acl-wrapper").show():$j("#acl-wrapper").hide()}).trigger("change"),$j(".popupbox").click(function(){var e=$j($j(this).attr("href")).parent();return e.css("display")=="none"?e.show():e.hide(),!1})}),$j(function(){$j("nav").bind("nav-update",function(e,t){var n=$j("#pending-update"),r=$j(t).find("register").text();r=="0"?(r="",n.hide()):n.show(),n.html(r)})});var editor=!1,textlen=0,plaintext="none",ispublic=window.isPublic;switch(window.ajaxType){case"jot-header":function jotGetLink(){reply=prompt(window.linkURL),reply&&reply.length&&(reply=bin2hex(reply),$j("#profile-rotator").show(),$j.get("parse_url?binurl="+reply,function(e){addeditortext(e),$j("#profile-rotator").hide()}))}function linkdrop(e){var t=e.dataTransfer.getData("text/uri-list");e.target.textContent=t,e.preventDefault(),t&&t.length&&(t=bin2hex(t),$j("#profile-rotator").show(),$j.get("parse_url?binurl="+t,function(e){editor||$j("#profile-jot-text").val(""),initEditor(function(){addeditortext(e),$j("#profile-rotator").hide()})}))}break;case"msg-header":case"wallmsg-header":function jotGetLink(){reply=prompt(window.linkURL),reply&&reply.length&&($j("#profile-rotator").show(),$j.get("parse_url?url="+reply,function(e){tinyMCE.execCommand("mceInsertRawHTML",!1,e),$j("#profile-rotator").hide()}))}function linkdrop(e){var t=e.dataTransfer.getData("text/uri-list");e.target.textContent=t,e.preventDefault(),t&&t.length&&($j("#profile-rotator").show(),$j.get("parse_url?url="+t,function(e){tinyMCE.execCommand("mceInsertRawHTML",!1,e),$j("#profile-rotator").hide()}))}break;default:}typeof window.geoTag=="function"&&window.geoTag(); \ No newline at end of file diff --git a/view/theme/frost-mobile/login-style.css b/view/theme/frost-mobile/login-style.css index 5c07aba77..37661cfbc 100644 --- a/view/theme/frost-mobile/login-style.css +++ b/view/theme/frost-mobile/login-style.css @@ -152,3 +152,9 @@ div.section-wrapper { #login-submit-wrapper { text-align: center; } + +footer { + text-align: center; + padding-top: 3em; + padding-bottom: 1em; +} diff --git a/view/theme/frost-mobile/style.css b/view/theme/frost-mobile/style.css index ef08bcb3f..aefe35071 100644 --- a/view/theme/frost-mobile/style.css +++ b/view/theme/frost-mobile/style.css @@ -12,7 +12,7 @@ html { /* width: 320px;*/ margin-left: auto; margin-right: auto; - overflow-x:hidden; +/* overflow-x:hidden;*/ } body { @@ -104,7 +104,7 @@ blockquote { #panel { background-color: ivory; position: absolute; - z-index: 2; +/* z-index: 2;*/ width: 30%; padding: 25px; border: 1px solid #444; @@ -256,7 +256,7 @@ nav .nav-link { -webkit-box-shadow: 3px 3px 5px #555; box-shadow: 3px 3px 5px #555; - z-index: 10000; + z-index: 100; } #network-menu-list { @@ -393,8 +393,8 @@ section { /* footer */ footer { - display: none; - + text-align: center; + padding-bottom: 1em; } .birthday-today, .event-today { @@ -1206,7 +1206,7 @@ input#dfrn-url { position: absolute; left: 0px; top:110px; display: none; - z-index: 10000; +/* z-index: 10000;*/ } .wall-item-photo-menu { margin:0px; padding: 0px; list-style: none } .wall-item-photo-menu li a { display: block; padding: 2px; } @@ -1236,7 +1236,7 @@ input#dfrn-url { position: absolute; left: 75px; top: 80px; - z-index: 100; +/* z-index: 100;*/ } .wall-item-wrapper { margin-left:10px; @@ -1351,12 +1351,23 @@ input#dfrn-url { } .wall-item-content img { + display: block; + margin-top: 10px; + margin-right: auto; + margin-left: auto; max-width: 290px; border-radius: 7px; /* -moz-border-radius: 7px;*/ -webkit-border-radius: 7px; } +.wall-item-content img.smiley { + display: inline; + margin: auto; + border-radius: 0; + -webkit-border-radius: 0; +} + .comment .wall-item-content img { max-width: 280px; } @@ -1415,6 +1426,7 @@ input#dfrn-url { background-repeat: repeat-x;*/ padding: 5px 5px 0px; height: 32px; + } .wall-item-author { /* margin-top: 10px;*/ @@ -2025,7 +2037,7 @@ input#dfrn-url { position: absolute; left: -30px; top: 80px; display: none; - z-index: 10000; + z-index: 101; /* -moz-box-shadow: 3px 3px 5px #555;*/ -webkit-box-shadow: 3px 3px 5px #555; box-shadow: 3px 3px 5px #555; @@ -3393,6 +3405,7 @@ aside input[type='text'] { text-decoration: none; } .field .onoff .off { + border-color:#666666; padding-left: 40px; background-position: left center; @@ -3595,7 +3608,13 @@ aside input[type='text'] { background-image: url('images/globe.png'); background-repeat: no-repeat; } -.noglobe { background-position: -16px -16px;} +/*.noglobe { background-position: -16px -16px;}*/ +.icon.noglobe { + display: block; width: 24px; height: 24px; + background-size: 100% 100%; + background-image: url('images/noglobe.png'); + background-repeat: no-repeat; +} .no { background-position: -32px -16px;} .pause { background-position: -48px -16px;} .play { background-position: -64px -16px;} @@ -3810,7 +3829,7 @@ aside input[type='text'] { max-height:150px; background-color:#ffffff; overflow:auto; - z-index:100000; + z-index:102; border:1px solid #cccccc; } .acpopupitem { @@ -3884,16 +3903,15 @@ ul.notifications-menu-popup { display: none; width: 10em; margin: 0px; - padding: 0px; + padding: 0px 0.3em; list-style: none; - z-index: 100000; - right: -55px; + right: -60px; } #nav-notifications-menu { width: 300px; /* max-height: 400px;*/ height: auto; - overflow-y: scroll;overflow-style:scrollbar; +/* overflow-y: scroll;overflow-style:scrollbar;*/ background-color:#FFFFFF; /* -moz-border-radius: 5px;*/ -webkit-border-radius: 5px; @@ -3902,6 +3920,7 @@ ul.notifications-menu-popup { /* -moz-box-shadow: 3px 3px 5px #555;*/ -webkit-box-shadow: 3px 3px 5px #555; box-shadow: 3px 3px 5px #555; +/* z-index: 103;*/ } #nav-notifications-menu .contactname { font-weight: bold; font-size: 0.9em; } #nav-notifications-menu img { float: left; margin-right: 5px; } diff --git a/view/theme/frost-mobile/theme.php b/view/theme/frost-mobile/theme.php index 018c50a88..b4ae1fcf9 100644 --- a/view/theme/frost-mobile/theme.php +++ b/view/theme/frost-mobile/theme.php @@ -4,7 +4,7 @@ * Name: Frost--mobile version * Description: Like frosted glass * Credits: Navigation icons taken from http://iconza.com. Other icons taken from http://thenounproject.com, including: Like, Dislike, Black Lock, Unlock, Pencil, Tag, Camera, Paperclip (Marie Coons), Folder (Sergio Calcara), Chain-link (Andrew Fortnum), Speaker (Harold Kim), Quotes (Henry Ryder), Video Camera (Anas Ramadan), and Left Arrow, Right Arrow, and Delete X (all three P.J. Onori). All under Attribution (CC BY 3.0). Others from The Noun Project are public domain or No Rights Reserved (CC0). - * Version: Version 0.2.11 + * Version: Version 0.2.12 * Author: Zach P * Maintainer: Zach P */ diff --git a/view/theme/frost/acl_selector.tpl b/view/theme/frost/acl_selector.tpl index 9fd7dd7ab..327f18b65 100644 --- a/view/theme/frost/acl_selector.tpl +++ b/view/theme/frost/acl_selector.tpl @@ -19,4 +19,5 @@ window.allowGID = $allowgid; window.denyCID = $denycid; window.denyGID = $denygid; + window.aclInit = "true"; diff --git a/view/theme/frost/admin_site.tpl b/view/theme/frost/admin_site.tpl index 91aeda035..087de4f7d 100644 --- a/view/theme/frost/admin_site.tpl +++ b/view/theme/frost/admin_site.tpl @@ -40,7 +40,7 @@ {{ inc field_checkbox.tpl with $field=$dfrn_only }}{{ endinc }} {{ inc field_input.tpl with $field=$global_directory }}{{ endinc }} {{ inc field_checkbox.tpl with $field=$thread_allow }}{{ endinc }} - {{ inc field_checkbox.tpl with $field=$newuser_public }}{{ endinc }} + {{ inc field_checkbox.tpl with $field=$newuser_private }}{{ endinc }}
    diff --git a/view/theme/frost/filebrowser.tpl b/view/theme/frost/filebrowser.tpl new file mode 100644 index 000000000..e9eafde1e --- /dev/null +++ b/view/theme/frost/filebrowser.tpl @@ -0,0 +1,84 @@ + + + + + + + + + +
    +
      +
    • FileBrowser
    • +
    +
    +
    + +
    +
    + {{ for $path as $p }}$p.1{{ endfor }} +
    +
    +
      + {{ for $folders as $f }}
    • $f.1
    • {{ endfor }} +
    +
    +
    +
      + {{ for $files as $f }} +
    • $f.1
    • + {{ endfor }} +
    +
    +
    +
    +
    + +
    + + + diff --git a/view/theme/frost/images/noglobe.png b/view/theme/frost/images/noglobe.png new file mode 100644 index 000000000..b5aceb6d5 Binary files /dev/null and b/view/theme/frost/images/noglobe.png differ diff --git a/view/theme/frost/jot.tpl b/view/theme/frost/jot.tpl index da47414ae..e7a89d8e0 100644 --- a/view/theme/frost/jot.tpl +++ b/view/theme/frost/jot.tpl @@ -60,6 +60,8 @@ $jotplugins
    + +
    diff --git a/view/theme/frost/jot_geotag.tpl b/view/theme/frost/jot_geotag.tpl new file mode 100644 index 000000000..3f8bee91a --- /dev/null +++ b/view/theme/frost/jot_geotag.tpl @@ -0,0 +1,11 @@ + + if(navigator.geolocation) { + navigator.geolocation.getCurrentPosition(function(position) { + var lat = position.coords.latitude.toFixed(4); + var lon = position.coords.longitude.toFixed(4); + + $j('#jot-coord').val(lat + ', ' + lon); + $j('#profile-nolocation-wrapper').show(); + }); + } + diff --git a/view/theme/frost/js/theme.js b/view/theme/frost/js/theme.js index 7c7e3c1d2..37d06c80c 100644 --- a/view/theme/frost/js/theme.js +++ b/view/theme/frost/js/theme.js @@ -17,7 +17,7 @@ $j(document).ready(function() { });*/ - if(typeof acl=="undefined"){ + if(typeof window.aclInit !="undefined" && typeof acl=="undefined"){ acl = new ACL( baseurl+"/acl", [ window.allowCID,window.allowGID,window.denyCID,window.denyGID ] @@ -935,6 +935,37 @@ function jotAudioURL() { function jotGetLocation() { + +/* if(navigator.geolocation) { + + navigator.geolocation.getCurrentPosition(function(position) { + var lat = position.coords.latitude; + var lng = position.coords.longitude; + + $j.ajax({ + type: 'GET', + url: 'http://nominatim.openstreetmap.org/reverse?format=json&lat='+lat+'&lon='+lng, + jsonp: 'json_callback', + contentType: 'application/json', + dataType: 'jsonp', + success: function(json) { + console.log(json); + var locationDisplay = json.address.building+', '+json.address.city+', '+json.address.state; + $j('#jot-location').val(locationDisplay); + $j('#jot-display-location').html('Location: '+locationDisplay); + $j('#jot-display-location').show(); + } + }); + }); + + } + else { + reply = prompt(window.whereAreU, $j('#jot-location').val()); + if(reply && reply.length) { + $j('#jot-location').val(reply); + } + }*/ + reply = prompt(window.whereAreU, $j('#jot-location').val()); if(reply && reply.length) { $j('#jot-location').val(reply); diff --git a/view/theme/frost/js/theme.min.js b/view/theme/frost/js/theme.min.js index 8c5cd16ad..c04d99b5a 100644 --- a/view/theme/frost/js/theme.min.js +++ b/view/theme/frost/js/theme.min.js @@ -1 +1 @@ -function showEvent(e){$j.get(baseurl+"/events/?id="+e,function(e){$j.fancybox(e)})}function initCrop(){function e(e,t){$("x1").value=e.x1,$("y1").value=e.y1,$("x2").value=e.x2,$("y2").value=e.y2,$("width").value=t.width,$("height").value=t.height}Event.observe(window,"load",function(){new Cropper.ImgWithPreview("croppa",{previewWrap:"previewWrap",minWidth:175,minHeight:175,maxWidth:640,maxHeight:640,ratioDim:{x:100,y:100},displayOnInit:!0,onEndCrop:e})})}function showNavMenu(e){window.navMenuTimeout[e+"-closing"]?(window.navMenuTimeout[e+"-closing"]=!1,clearTimeout(window.navMenuTimeout[e+"-timeout"])):(window.navMenuTimeout[e+"-opening"]=!0,window.navMenuTimeout[e+"-timeout"]=setTimeout(function(){$j(e).slideDown("fast").show(),window.navMenuTimeout[e+"-opening"]=!1},200))}function hideNavMenu(e){window.navMenuTimeout[e+"-opening"]?(window.navMenuTimeout[e+"-opening"]=!1,clearTimeout(window.navMenuTimeout[e+"-timeout"])):(window.navMenuTimeout[e+"-closing"]=!0,window.navMenuTimeout[e+"-timeout"]=setTimeout(function(){$j(e).slideUp("fast"),window.navMenuTimeout[e+"-closing"]=!1},500))}function insertFormatting(e,t,n){var r=$j("#comment-edit-text-"+n).val();r==e&&(r="",$j("#comment-edit-text-"+n).addClass("comment-edit-text-full"),$j("#comment-edit-text-"+n).removeClass("comment-edit-text-empty"),openMenu("comment-edit-submit-wrapper-"+n),$j("#comment-edit-text-"+n).val(r)),textarea=document.getElementById("comment-edit-text-"+n);if(document.selection)textarea.focus(),selected=document.selection.createRange(),t=="url"?selected.text="["+t+"]"+"http://"+selected.text+"[/"+t+"]":selected.text="["+t+"]"+selected.text+"[/"+t+"]";else if(textarea.selectionStart||textarea.selectionStart=="0"){var i=textarea.selectionStart,s=textarea.selectionEnd;t=="url"?textarea.value=textarea.value.substring(0,i)+"["+t+"]"+"http://"+textarea.value.substring(i,s)+"[/"+t+"]"+textarea.value.substring(s,textarea.value.length):textarea.value=textarea.value.substring(0,i)+"["+t+"]"+textarea.value.substring(i,s)+"[/"+t+"]"+textarea.value.substring(s,textarea.value.length)}return!0}function cmtBbOpen(e){$j("#comment-edit-bb-"+e).show()}function cmtBbClose(e){$j("#comment-edit-bb-"+e).hide()}function confirmDelete(){return confirm(window.delItem)}function commentOpen(e,t){e.value==window.commentEmptyText&&(e.value="",$j("#comment-edit-text-"+t).addClass("comment-edit-text-full"),$j("#comment-edit-text-"+t).removeClass("comment-edit-text-empty"),$j("#mod-cmnt-wrap-"+t).show(),openMenu("comment-edit-submit-wrapper-"+t))}function commentClose(e,t){e.value==""&&(e.value=window.commentEmptyText,$j("#comment-edit-text-"+t).removeClass("comment-edit-text-full"),$j("#comment-edit-text-"+t).addClass("comment-edit-text-empty"),$j("#mod-cmnt-wrap-"+t).hide(),closeMenu("comment-edit-submit-wrapper-"+t))}function commentInsert(e,t){var n=$j("#comment-edit-text-"+t).val();n==window.commentEmptyText&&(n="",$j("#comment-edit-text-"+t).addClass("comment-edit-text-full"),$j("#comment-edit-text-"+t).removeClass("comment-edit-text-empty"),openMenu("comment-edit-submit-wrapper-"+t));var r=$j(e).html();r=r.replace("<","<"),r=r.replace(">",">"),r=r.replace("&","&"),r=r.replace(""",'"'),$j("#comment-edit-text-"+t).val(n+r)}function qCommentInsert(e,t){var n=$j("#comment-edit-text-"+t).val();n==window.commentEmptyText&&(n="",$j("#comment-edit-text-"+t).addClass("comment-edit-text-full"),$j("#comment-edit-text-"+t).removeClass("comment-edit-text-empty"),openMenu("comment-edit-submit-wrapper-"+t));var r=$j(e).val();r=r.replace("<","<"),r=r.replace(">",">"),r=r.replace("&","&"),r=r.replace(""",'"'),$j("#comment-edit-text-"+t).val(n+r),$j(e).val("")}function showHideComments(e){$j("#collapsed-comments-"+e).is(":visible")?($j("#collapsed-comments-"+e).hide(),$j("#hide-comments-"+e).html(window.showMore)):($j("#collapsed-comments-"+e).show(),$j("#hide-comments-"+e).html(window.showFewer))}function enableOnUser(){if(editor)return;$j(this).val(""),initEditor()}function initEditor(e){if(editor==0){$j("#profile-jot-text-loading").show();if(plaintext=="none"){$j("#profile-jot-text-loading").hide(),$j("#profile-jot-text").css({height:200,color:"#000"}),$j("#profile-jot-text").contact_autocomplete(baseurl+"/acl"),editor=!0,$j("a#jot-perms-icon").fancybox({transitionIn:"elastic",transitionOut:"elastic"}),$j(".jothidden").show(),typeof e!="undefined"&&e();return}tinyMCE.init({theme:"advanced",mode:"specific_textareas",editor_selector:window.editSelect,auto_focus:"profile-jot-text",plugins:"bbcode,paste,autoresize, inlinepopups",theme_advanced_buttons1:"bold,italic,underline,undo,redo,link,unlink,image,forecolor,formatselect,code",theme_advanced_buttons2:"",theme_advanced_buttons3:"",theme_advanced_toolbar_location:"top",theme_advanced_toolbar_align:"center",theme_advanced_blockformats:"blockquote,code",gecko_spellcheck:!0,paste_text_sticky:!0,entity_encoding:"raw",add_unload_trigger:!1,remove_linebreaks:!1,force_p_newlines:!1,force_br_newlines:!0,forced_root_block:"",convert_urls:!1,content_css:window.baseURL+"/view/custom_tinymce.css",theme_advanced_path:!1,file_browser_callback:"fcFileBrowser",setup:function(t){cPopup=null,t.onKeyDown.add(function(e,t){cPopup!==null&&cPopup.onkey(t)}),t.onKeyUp.add(function(e,t){var n=tinyMCE.activeEditor.getContent();match=n.match(/@([^ \n]+)$/),match!==null?(cPopup===null&&(cPopup=new ACPopup(this,baseurl+"/acl")),cPopup.ready&&match[1]!==cPopup.searchText&&cPopup.search(match[1]),cPopup.ready||(cPopup=null)):cPopup!==null&&(cPopup.close(),cPopup=null),textlen=n.length,textlen!=0&&$j("#jot-perms-icon").is(".unlock")?$j("#profile-jot-desc").html(ispublic):$j("#profile-jot-desc").html(" "),textlen<=140&&($j("#character-counter").removeClass("red"),$j("#character-counter").removeClass("orange"),$j("#character-counter").addClass("grey")),textlen>140&&textlen<=420&&($j("#character-counter").removeClass("grey"),$j("#character-counter").removeClass("red"),$j("#character-counter").addClass("orange")),textlen>420&&($j("#character-counter").removeClass("grey"),$j("#character-counter").removeClass("orange"),$j("#character-counter").addClass("red")),$j("#character-counter").text(textlen)}),t.onInit.add(function(t){t.pasteAsPlainText=!0,$j("#profile-jot-text-loading").hide(),$j(".jothidden").show(),typeof e!="undefined"&&e()})}}),editor=!0,$j("a#jot-perms-icon").fancybox({transitionIn:"none",transitionOut:"none"})}else typeof e!="undefined"&&e()}function msgInitEditor(){plaintext!="none"?tinyMCE.init({theme:"advanced",mode:"specific_textareas",editor_selector:/(profile-jot-text|prvmail-text)/,plugins:"bbcode,paste",theme_advanced_buttons1:"bold,italic,underline,undo,redo,link,unlink,image,forecolor",theme_advanced_buttons2:"",theme_advanced_buttons3:"",theme_advanced_toolbar_location:"top",theme_advanced_toolbar_align:"center",theme_advanced_blockformats:"blockquote,code",gecko_spellcheck:!0,paste_text_sticky:!0,entity_encoding:"raw",add_unload_trigger:!1,remove_linebreaks:!1,force_p_newlines:!1,force_br_newlines:!0,forced_root_block:"",convert_urls:!1,content_css:baseurl+"/view/custom_tinymce.css",theme_advanced_path:!1,setup:function(e){e.onInit.add(function(e){e.pasteAsPlainText=!0;var t=e.editorId,n=$j("#"+t);typeof n.attr("tabindex")!="undefined"&&($j("#"+t+"_ifr").attr("tabindex",n.attr("tabindex")),n.attr("tabindex",null))})}}):$j("#prvmail-text").contact_autocomplete(baseurl+"/acl")}function profInitEditor(){tinyMCE.init({theme:"advanced",mode:window.editSelect,plugins:"bbcode,paste",theme_advanced_buttons1:"bold,italic,underline,undo,redo,link,unlink,image,forecolor,formatselect,code",theme_advanced_buttons2:"",theme_advanced_buttons3:"",theme_advanced_toolbar_location:"top",theme_advanced_toolbar_align:"center",theme_advanced_blockformats:"blockquote,code",gecko_spellcheck:!0,paste_text_sticky:!0,entity_encoding:"raw",add_unload_trigger:!1,remove_linebreaks:!1,force_p_newlines:!1,force_br_newlines:!0,forced_root_block:"",content_css:baseurl+"/view/custom_tinymce.css",theme_advanced_path:!1,setup:function(e){e.onInit.add(function(e){e.pasteAsPlainText=!0})}})}function eventInitEditor(){tinyMCE.init({theme:"advanced",mode:"textareas",plugins:"bbcode,paste",theme_advanced_buttons1:"bold,italic,underline,undo,redo,link,unlink,image,forecolor,formatselect,code",theme_advanced_buttons2:"",theme_advanced_buttons3:"",theme_advanced_toolbar_location:"top",theme_advanced_toolbar_align:"center",theme_advanced_blockformats:"blockquote,code",gecko_spellcheck:!0,paste_text_sticky:!0,entity_encoding:"raw",add_unload_trigger:!1,remove_linebreaks:!1,force_p_newlines:!1,force_br_newlines:!0,forced_root_block:"",content_css:baseurl+"/view/custom_tinymce.css",theme_advanced_path:!1,setup:function(e){e.onInit.add(function(e){e.pasteAsPlainText=!0})}})}function contactInitEditor(){tinyMCE.init({theme:"advanced",mode:window.editSelect,elements:"contact-edit-info",plugins:"bbcode",theme_advanced_buttons1:"bold,italic,underline,undo,redo,link,unlink,image,forecolor",theme_advanced_buttons2:"",theme_advanced_buttons3:"",theme_advanced_toolbar_location:"top",theme_advanced_toolbar_align:"center",theme_advanced_styles:"blockquote,code",gecko_spellcheck:!0,entity_encoding:"raw",add_unload_trigger:!1,remove_linebreaks:!1,force_p_newlines:!1,force_br_newlines:!0,forced_root_block:"",content_css:baseurl+"/view/custom_tinymce.css"})}function wallInitEditor(){var e=window.editSelect;e!="none"?tinyMCE.init({theme:"advanced",mode:"specific_textareas",editor_selector:/(profile-jot-text|prvmail-text)/,plugins:"bbcode,paste",theme_advanced_buttons1:"bold,italic,underline,undo,redo,link,unlink,image,forecolor",theme_advanced_buttons2:"",theme_advanced_buttons3:"",theme_advanced_toolbar_location:"top",theme_advanced_toolbar_align:"center",theme_advanced_blockformats:"blockquote,code",gecko_spellcheck:!0,paste_text_sticky:!0,entity_encoding:"raw",add_unload_trigger:!1,remove_linebreaks:!1,force_p_newlines:!1,force_br_newlines:!0,forced_root_block:"",convert_urls:!1,content_css:baseurl+"/view/custom_tinymce.css",theme_advanced_path:!1,setup:function(e){e.onInit.add(function(e){e.pasteAsPlainText=!0;var t=e.editorId,n=$j("#"+t);typeof n.attr("tabindex")!="undefined"&&($j("#"+t+"_ifr").attr("tabindex",n.attr("tabindex")),n.attr("tabindex",null))})}}):$j("#prvmail-text").contact_autocomplete(baseurl+"/acl")}function deleteCheckedItems(){var e="";$j(".item-select").each(function(){$j(this).is(":checked")&&(e.length!=0?e=e+","+$j(this).val():e=$j(this).val())}),$j.post("item",{dropitems:e},function(e){window.location.reload()})}function jotVideoURL(){reply=prompt(window.vidURL),reply&&reply.length&&addeditortext("[video]"+reply+"[/video]")}function jotAudioURL(){reply=prompt(window.audURL),reply&&reply.length&&addeditortext("[audio]"+reply+"[/audio]")}function jotGetLocation(){reply=prompt(window.whereAreU,$j("#jot-location").val()),reply&&reply.length&&$j("#jot-location").val(reply)}function jotShare(e){$j("#jot-popup").length!=0&&$j("#jot-popup").show(),$j("#like-rotator-"+e).show(),$j.get("share/"+e,function(t){editor||$j("#profile-jot-text").val(""),initEditor(function(){addeditortext(t),$j("#like-rotator-"+e).hide(),$j(window).scrollTop(0)})})}function linkdropper(e){var t=e.dataTransfer.types.contains("text/uri-list");t&&e.preventDefault()}function itemTag(e){reply=prompt(window.term),reply&&reply.length&&(reply=reply.replace("#",""),reply.length&&(commentBusy=!0,$j("body").css("cursor","wait"),$j.get("tagger/"+e+"?term="+reply,NavUpdate),liking=1))}function itemFiler(e){var t=$j("input").css("border-color");$j.get("filer/",function(n){$j.fancybox(n),$j("#id_term").keypress(function(){$j(this).css("border-color",t)}),$j("#select_term").change(function(){$j("#id_term").css("border-color",t)}),$j("#filer_save").click(function(t){return t.preventDefault(),reply=$j("#id_term").val(),reply&&reply.length?(commentBusy=!0,$j("body").css("cursor","wait"),$j.get("filer/"+e+"?term="+reply,NavUpdate),liking=1,$j.fancybox.close()):$j("#id_term").css("border-color","#FF0000"),!1})})}function jotClearLocation(){$j("#jot-coord").val(""),$j("#profile-nolocation-wrapper").hide()}function addeditortext(e){if(plaintext=="none"){var t=$j("#profile-jot-text").val();$j("#profile-jot-text").val(t+e)}else tinyMCE.execCommand("mceInsertRawHTML",!1,e)}$j(document).ready(function(){window.navMenuTimeout={"#network-menu-list-timeout":null,"#contacts-menu-list-timeout":null,"#system-menu-list-timeout":null,"#network-menu-list-opening":!1,"#contacts-menu-list-opening":!1,"#system-menu-list-opening":!1,"#network-menu-list-closing":!1,"#contacts-menu-list-closing":!1,"#system-menu-list-closing":!1},typeof acl=="undefined"&&(acl=new ACL(baseurl+"/acl",[window.allowCID,window.allowGID,window.denyCID,window.denyGID])),$j("#profile-jot-text").focus(enableOnUser),$j("#profile-jot-text").click(enableOnUser),$j(".nav-menu-link").hover(function(){showNavMenu($j(this).attr("rel"))},function(){hideNavMenu($j(this).attr("rel"))}),$j(".group-edit-icon").hover(function(){$j(this).addClass("icon"),$j(this).removeClass("iconspacer")},function(){$j(this).removeClass("icon"),$j(this).addClass("iconspacer")}),$j(".sidebar-group-element").hover(function(){id=$j(this).attr("id"),$j("#edit-"+id).addClass("icon"),$j("#edit-"+id).removeClass("iconspacer")},function(){id=$j(this).attr("id"),$j("#edit-"+id).removeClass("icon"),$j("#edit-"+id).addClass("iconspacer")}),$j(".savedsearchdrop").hover(function(){$j(this).addClass("drop"),$j(this).addClass("icon"),$j(this).removeClass("iconspacer")},function(){$j(this).removeClass("drop"),$j(this).removeClass("icon"),$j(this).addClass("iconspacer")}),$j(".savedsearchterm").hover(function(){id=$j(this).attr("id"),$j("#drop-"+id).addClass("icon"),$j("#drop-"+id).addClass("drophide"),$j("#drop-"+id).removeClass("iconspacer")},function(){id=$j(this).attr("id"),$j("#drop-"+id).removeClass("icon"),$j("#drop-"+id).removeClass("drophide"),$j("#drop-"+id).addClass("iconspacer")}),window.autoCompleteType=="display-head"&&$j(".comment-wwedit-wrapper textarea").contact_autocomplete(baseurl+"/acl");if(window.aclType=="event_head"){$j("#events-calendar").fullCalendar({events:baseurl+"/events/json/",header:{left:"prev,next today",center:"title",right:"month,agendaWeek,agendaDay"},timeFormat:"H(:mm)",eventClick:function(e,t,n){showEvent(e.id)},eventRender:function(e,t,n){if(e.item["author-name"]==null)return;switch(n.name){case"month":t.find(".fc-event-title").html("{1} : {2}".format(e.item["author-avatar"],e.item["author-name"],e.title));break;case"agendaWeek":t.find(".fc-event-title").html("{1}

    {2}

    {3}

    ".format(e.item["author-avatar"],e.item["author-name"],e.item.desc,e.item.location));break;case"agendaDay":t.find(".fc-event-title").html("{1}

    {2}

    {3}

    ".format(e.item["author-avatar"],e.item["author-name"],e.item.desc,e.item.location))}}});var e=location.href.replace(baseurl,"").split("/");e.length>=4&&$j("#events-calendar").fullCalendar("gotoDate",e[2],e[3]-1);var t=location.hash.split("-");t.length==2&&t[0]=="#link"&&showEvent(t[1])}$j("#event-share-checkbox").change(function(){$j("#event-share-checkbox").is(":checked")?$j("#acl-wrapper").show():$j("#acl-wrapper").hide()}).trigger("change"),(window.aclType=="settings-head"||window.aclType=="photos_head"||window.aclType=="event_head")&&$j("#contact_allow, #contact_deny, #group_allow, #group_deny").change(function(){var e;$j("#contact_allow option:selected, #contact_deny option:selected, #group_allow option:selected, #group_deny option:selected").each(function(){e=$j(this).text(),$j("#jot-perms-icon").removeClass("unlock").addClass("lock"),$j("#jot-public").hide()}),e==null&&($j("#jot-perms-icon").removeClass("lock").addClass("unlock"),$j("#jot-public").show())}).trigger("change");switch(window.autocompleteType){case"msg-header":var n=$j("#recip").autocomplete({serviceUrl:baseurl+"/acl",minChars:2,width:350,onSelect:function(e,t){$j("#recip-complete").val(t)}});break;case"contacts-head":var n=$j("#contacts-search").autocomplete({serviceUrl:baseurl+"/acl",minChars:2,width:350});n.setOptions({params:{type:"a"}});break;default:}if(typeof window.AjaxUpload!="undefined")switch(window.ajaxType){case"jot-header":var r=new window.AjaxUpload("wall-image-upload",{action:"wall_upload/"+window.nickname,name:"userfile",onSubmit:function(e,t){$j("#profile-rotator").show()},onComplete:function(e,t){addeditortext(t),$j("#profile-rotator").hide()}}),i=new window.AjaxUpload("wall-file-upload",{action:"wall_attach/"+window.nickname,name:"userfile",onSubmit:function(e,t){$j("#profile-rotator").show()},onComplete:function(e,t){addeditortext(t),$j("#profile-rotator").hide()}});break;case"msg-header":var r=new window.AjaxUpload("prvmail-upload",{action:"wall_upload/"+window.nickname,name:"userfile",onSubmit:function(e,t){$j("#profile-rotator").show()},onComplete:function(e,t){tinyMCE.execCommand("mceInsertRawHTML",!1,t),$j("#profile-rotator").hide()}});break;default:}}),$j(function(){$j("nav").bind("nav-update",function(e,t){var n=$j("#pending-update"),r=$j(t).find("register").text();r=="0"?(r="",n.hide()):n.show(),n.html(r)})}),$j(function(){$j("#cnftheme").fancybox({width:800,autoDimensions:!1,onStart:function(){var e=$j("#id_theme :selected").val(),t=$j("#id_theme_mobile :selected").val();$j("#cnftheme").attr("href",baseurl+"/admin/themes/"+e)},onComplete:function(){$j("div#fancybox-content form").submit(function(e){var t=$j(this).attr("action"),n={};return $j(this).find("input").each(function(){n[$j(this).attr("name")]=$j(this).val()}),$j(this).find("select").each(function(){n[$j(this).attr("name")]=$j(this).children(":selected").val()}),console.log(":)",t,n),$j.post(t,n,function(e){timer&&clearTimeout(timer),NavUpdate(),$j.fancybox.close()}),!1})}})}),typeof window.photoEdit!="undefined"&&$j(document).keydown(function(e){window.prevLink!=""&&e.ctrlKey&&e.keyCode==37&&(e.preventDefault(),window.location.href=window.prevLink),window.nextLink!=""&&e.ctrlKey&&e.keyCode==39&&(e.preventDefault(),window.location.href=window.nextLink)});switch(window.ajaxType){case"jot-header":function jotGetLink(){reply=prompt(window.linkURL),reply&&reply.length&&(reply=bin2hex(reply),$j("#profile-rotator").show(),$j.get("parse_url?binurl="+reply,function(e){addeditortext(e),$j("#profile-rotator").hide()}))}function linkdrop(e){var t=e.dataTransfer.getData("text/uri-list");e.target.textContent=t,e.preventDefault(),t&&t.length&&(t=bin2hex(t),$j("#profile-rotator").show(),$j.get("parse_url?binurl="+t,function(e){editor||$j("#profile-jot-text").val(""),initEditor(function(){addeditortext(e),$j("#profile-rotator").hide()})}))}break;case"msg-header":case"wallmsg-header":function jotGetLink(){reply=prompt(window.linkURL),reply&&reply.length&&($j("#profile-rotator").show(),$j.get("parse_url?url="+reply,function(e){tinyMCE.execCommand("mceInsertRawHTML",!1,e),$j("#profile-rotator").hide()}))}function linkdrop(e){var t=e.dataTransfer.getData("text/uri-list");e.target.textContent=t,e.preventDefault(),t&&t.length&&($j("#profile-rotator").show(),$j.get("parse_url?url="+t,function(e){tinyMCE.execCommand("mceInsertRawHTML",!1,e),$j("#profile-rotator").hide()}))}break;default:}var editor=!1,textlen=0,plaintext=window.editSelect,ispublic=window.isPublic;typeof window.geoTag=="function"&&window.geoTag(); \ No newline at end of file +function showEvent(e){$j.get(baseurl+"/events/?id="+e,function(e){$j.fancybox(e)})}function initCrop(){function e(e,t){$("x1").value=e.x1,$("y1").value=e.y1,$("x2").value=e.x2,$("y2").value=e.y2,$("width").value=t.width,$("height").value=t.height}Event.observe(window,"load",function(){new Cropper.ImgWithPreview("croppa",{previewWrap:"previewWrap",minWidth:175,minHeight:175,maxWidth:640,maxHeight:640,ratioDim:{x:100,y:100},displayOnInit:!0,onEndCrop:e})})}function showNavMenu(e){window.navMenuTimeout[e+"-closing"]?(window.navMenuTimeout[e+"-closing"]=!1,clearTimeout(window.navMenuTimeout[e+"-timeout"])):(window.navMenuTimeout[e+"-opening"]=!0,window.navMenuTimeout[e+"-timeout"]=setTimeout(function(){$j(e).slideDown("fast").show(),window.navMenuTimeout[e+"-opening"]=!1},200))}function hideNavMenu(e){window.navMenuTimeout[e+"-opening"]?(window.navMenuTimeout[e+"-opening"]=!1,clearTimeout(window.navMenuTimeout[e+"-timeout"])):(window.navMenuTimeout[e+"-closing"]=!0,window.navMenuTimeout[e+"-timeout"]=setTimeout(function(){$j(e).slideUp("fast"),window.navMenuTimeout[e+"-closing"]=!1},500))}function insertFormatting(e,t,n){var r=$j("#comment-edit-text-"+n).val();r==e&&(r="",$j("#comment-edit-text-"+n).addClass("comment-edit-text-full"),$j("#comment-edit-text-"+n).removeClass("comment-edit-text-empty"),openMenu("comment-edit-submit-wrapper-"+n),$j("#comment-edit-text-"+n).val(r)),textarea=document.getElementById("comment-edit-text-"+n);if(document.selection)textarea.focus(),selected=document.selection.createRange(),t=="url"?selected.text="["+t+"]"+"http://"+selected.text+"[/"+t+"]":selected.text="["+t+"]"+selected.text+"[/"+t+"]";else if(textarea.selectionStart||textarea.selectionStart=="0"){var i=textarea.selectionStart,s=textarea.selectionEnd;t=="url"?textarea.value=textarea.value.substring(0,i)+"["+t+"]"+"http://"+textarea.value.substring(i,s)+"[/"+t+"]"+textarea.value.substring(s,textarea.value.length):textarea.value=textarea.value.substring(0,i)+"["+t+"]"+textarea.value.substring(i,s)+"[/"+t+"]"+textarea.value.substring(s,textarea.value.length)}return!0}function cmtBbOpen(e){$j("#comment-edit-bb-"+e).show()}function cmtBbClose(e){$j("#comment-edit-bb-"+e).hide()}function confirmDelete(){return confirm(window.delItem)}function commentOpen(e,t){e.value==window.commentEmptyText&&(e.value="",$j("#comment-edit-text-"+t).addClass("comment-edit-text-full"),$j("#comment-edit-text-"+t).removeClass("comment-edit-text-empty"),$j("#mod-cmnt-wrap-"+t).show(),openMenu("comment-edit-submit-wrapper-"+t))}function commentClose(e,t){e.value==""&&(e.value=window.commentEmptyText,$j("#comment-edit-text-"+t).removeClass("comment-edit-text-full"),$j("#comment-edit-text-"+t).addClass("comment-edit-text-empty"),$j("#mod-cmnt-wrap-"+t).hide(),closeMenu("comment-edit-submit-wrapper-"+t))}function commentInsert(e,t){var n=$j("#comment-edit-text-"+t).val();n==window.commentEmptyText&&(n="",$j("#comment-edit-text-"+t).addClass("comment-edit-text-full"),$j("#comment-edit-text-"+t).removeClass("comment-edit-text-empty"),openMenu("comment-edit-submit-wrapper-"+t));var r=$j(e).html();r=r.replace("<","<"),r=r.replace(">",">"),r=r.replace("&","&"),r=r.replace(""",'"'),$j("#comment-edit-text-"+t).val(n+r)}function qCommentInsert(e,t){var n=$j("#comment-edit-text-"+t).val();n==window.commentEmptyText&&(n="",$j("#comment-edit-text-"+t).addClass("comment-edit-text-full"),$j("#comment-edit-text-"+t).removeClass("comment-edit-text-empty"),openMenu("comment-edit-submit-wrapper-"+t));var r=$j(e).val();r=r.replace("<","<"),r=r.replace(">",">"),r=r.replace("&","&"),r=r.replace(""",'"'),$j("#comment-edit-text-"+t).val(n+r),$j(e).val("")}function showHideComments(e){$j("#collapsed-comments-"+e).is(":visible")?($j("#collapsed-comments-"+e).hide(),$j("#hide-comments-"+e).html(window.showMore)):($j("#collapsed-comments-"+e).show(),$j("#hide-comments-"+e).html(window.showFewer))}function enableOnUser(){if(editor)return;$j(this).val(""),initEditor()}function initEditor(e){if(editor==0){$j("#profile-jot-text-loading").show();if(plaintext=="none"){$j("#profile-jot-text-loading").hide(),$j("#profile-jot-text").css({height:200,color:"#000"}),$j("#profile-jot-text").contact_autocomplete(baseurl+"/acl"),editor=!0,$j("a#jot-perms-icon").fancybox({transitionIn:"elastic",transitionOut:"elastic"}),$j(".jothidden").show(),typeof e!="undefined"&&e();return}tinyMCE.init({theme:"advanced",mode:"specific_textareas",editor_selector:window.editSelect,auto_focus:"profile-jot-text",plugins:"bbcode,paste,autoresize, inlinepopups",theme_advanced_buttons1:"bold,italic,underline,undo,redo,link,unlink,image,forecolor,formatselect,code",theme_advanced_buttons2:"",theme_advanced_buttons3:"",theme_advanced_toolbar_location:"top",theme_advanced_toolbar_align:"center",theme_advanced_blockformats:"blockquote,code",gecko_spellcheck:!0,paste_text_sticky:!0,entity_encoding:"raw",add_unload_trigger:!1,remove_linebreaks:!1,force_p_newlines:!1,force_br_newlines:!0,forced_root_block:"",convert_urls:!1,content_css:window.baseURL+"/view/custom_tinymce.css",theme_advanced_path:!1,file_browser_callback:"fcFileBrowser",setup:function(t){cPopup=null,t.onKeyDown.add(function(e,t){cPopup!==null&&cPopup.onkey(t)}),t.onKeyUp.add(function(e,t){var n=tinyMCE.activeEditor.getContent();match=n.match(/@([^ \n]+)$/),match!==null?(cPopup===null&&(cPopup=new ACPopup(this,baseurl+"/acl")),cPopup.ready&&match[1]!==cPopup.searchText&&cPopup.search(match[1]),cPopup.ready||(cPopup=null)):cPopup!==null&&(cPopup.close(),cPopup=null),textlen=n.length,textlen!=0&&$j("#jot-perms-icon").is(".unlock")?$j("#profile-jot-desc").html(ispublic):$j("#profile-jot-desc").html(" "),textlen<=140&&($j("#character-counter").removeClass("red"),$j("#character-counter").removeClass("orange"),$j("#character-counter").addClass("grey")),textlen>140&&textlen<=420&&($j("#character-counter").removeClass("grey"),$j("#character-counter").removeClass("red"),$j("#character-counter").addClass("orange")),textlen>420&&($j("#character-counter").removeClass("grey"),$j("#character-counter").removeClass("orange"),$j("#character-counter").addClass("red")),$j("#character-counter").text(textlen)}),t.onInit.add(function(t){t.pasteAsPlainText=!0,$j("#profile-jot-text-loading").hide(),$j(".jothidden").show(),typeof e!="undefined"&&e()})}}),editor=!0,$j("a#jot-perms-icon").fancybox({transitionIn:"none",transitionOut:"none"})}else typeof e!="undefined"&&e()}function msgInitEditor(){plaintext!="none"?tinyMCE.init({theme:"advanced",mode:"specific_textareas",editor_selector:/(profile-jot-text|prvmail-text)/,plugins:"bbcode,paste",theme_advanced_buttons1:"bold,italic,underline,undo,redo,link,unlink,image,forecolor",theme_advanced_buttons2:"",theme_advanced_buttons3:"",theme_advanced_toolbar_location:"top",theme_advanced_toolbar_align:"center",theme_advanced_blockformats:"blockquote,code",gecko_spellcheck:!0,paste_text_sticky:!0,entity_encoding:"raw",add_unload_trigger:!1,remove_linebreaks:!1,force_p_newlines:!1,force_br_newlines:!0,forced_root_block:"",convert_urls:!1,content_css:baseurl+"/view/custom_tinymce.css",theme_advanced_path:!1,setup:function(e){e.onInit.add(function(e){e.pasteAsPlainText=!0;var t=e.editorId,n=$j("#"+t);typeof n.attr("tabindex")!="undefined"&&($j("#"+t+"_ifr").attr("tabindex",n.attr("tabindex")),n.attr("tabindex",null))})}}):$j("#prvmail-text").contact_autocomplete(baseurl+"/acl")}function profInitEditor(){tinyMCE.init({theme:"advanced",mode:window.editSelect,plugins:"bbcode,paste",theme_advanced_buttons1:"bold,italic,underline,undo,redo,link,unlink,image,forecolor,formatselect,code",theme_advanced_buttons2:"",theme_advanced_buttons3:"",theme_advanced_toolbar_location:"top",theme_advanced_toolbar_align:"center",theme_advanced_blockformats:"blockquote,code",gecko_spellcheck:!0,paste_text_sticky:!0,entity_encoding:"raw",add_unload_trigger:!1,remove_linebreaks:!1,force_p_newlines:!1,force_br_newlines:!0,forced_root_block:"",content_css:baseurl+"/view/custom_tinymce.css",theme_advanced_path:!1,setup:function(e){e.onInit.add(function(e){e.pasteAsPlainText=!0})}})}function eventInitEditor(){tinyMCE.init({theme:"advanced",mode:"textareas",plugins:"bbcode,paste",theme_advanced_buttons1:"bold,italic,underline,undo,redo,link,unlink,image,forecolor,formatselect,code",theme_advanced_buttons2:"",theme_advanced_buttons3:"",theme_advanced_toolbar_location:"top",theme_advanced_toolbar_align:"center",theme_advanced_blockformats:"blockquote,code",gecko_spellcheck:!0,paste_text_sticky:!0,entity_encoding:"raw",add_unload_trigger:!1,remove_linebreaks:!1,force_p_newlines:!1,force_br_newlines:!0,forced_root_block:"",content_css:baseurl+"/view/custom_tinymce.css",theme_advanced_path:!1,setup:function(e){e.onInit.add(function(e){e.pasteAsPlainText=!0})}})}function contactInitEditor(){tinyMCE.init({theme:"advanced",mode:window.editSelect,elements:"contact-edit-info",plugins:"bbcode",theme_advanced_buttons1:"bold,italic,underline,undo,redo,link,unlink,image,forecolor",theme_advanced_buttons2:"",theme_advanced_buttons3:"",theme_advanced_toolbar_location:"top",theme_advanced_toolbar_align:"center",theme_advanced_styles:"blockquote,code",gecko_spellcheck:!0,entity_encoding:"raw",add_unload_trigger:!1,remove_linebreaks:!1,force_p_newlines:!1,force_br_newlines:!0,forced_root_block:"",content_css:baseurl+"/view/custom_tinymce.css"})}function wallInitEditor(){var e=window.editSelect;e!="none"?tinyMCE.init({theme:"advanced",mode:"specific_textareas",editor_selector:/(profile-jot-text|prvmail-text)/,plugins:"bbcode,paste",theme_advanced_buttons1:"bold,italic,underline,undo,redo,link,unlink,image,forecolor",theme_advanced_buttons2:"",theme_advanced_buttons3:"",theme_advanced_toolbar_location:"top",theme_advanced_toolbar_align:"center",theme_advanced_blockformats:"blockquote,code",gecko_spellcheck:!0,paste_text_sticky:!0,entity_encoding:"raw",add_unload_trigger:!1,remove_linebreaks:!1,force_p_newlines:!1,force_br_newlines:!0,forced_root_block:"",convert_urls:!1,content_css:baseurl+"/view/custom_tinymce.css",theme_advanced_path:!1,setup:function(e){e.onInit.add(function(e){e.pasteAsPlainText=!0;var t=e.editorId,n=$j("#"+t);typeof n.attr("tabindex")!="undefined"&&($j("#"+t+"_ifr").attr("tabindex",n.attr("tabindex")),n.attr("tabindex",null))})}}):$j("#prvmail-text").contact_autocomplete(baseurl+"/acl")}function deleteCheckedItems(){var e="";$j(".item-select").each(function(){$j(this).is(":checked")&&(e.length!=0?e=e+","+$j(this).val():e=$j(this).val())}),$j.post("item",{dropitems:e},function(e){window.location.reload()})}function jotVideoURL(){reply=prompt(window.vidURL),reply&&reply.length&&addeditortext("[video]"+reply+"[/video]")}function jotAudioURL(){reply=prompt(window.audURL),reply&&reply.length&&addeditortext("[audio]"+reply+"[/audio]")}function jotGetLocation(){reply=prompt(window.whereAreU,$j("#jot-location").val()),reply&&reply.length&&$j("#jot-location").val(reply)}function jotShare(e){$j("#jot-popup").length!=0&&$j("#jot-popup").show(),$j("#like-rotator-"+e).show(),$j.get("share/"+e,function(t){editor||$j("#profile-jot-text").val(""),initEditor(function(){addeditortext(t),$j("#like-rotator-"+e).hide(),$j(window).scrollTop(0)})})}function linkdropper(e){var t=e.dataTransfer.types.contains("text/uri-list");t&&e.preventDefault()}function itemTag(e){reply=prompt(window.term),reply&&reply.length&&(reply=reply.replace("#",""),reply.length&&(commentBusy=!0,$j("body").css("cursor","wait"),$j.get("tagger/"+e+"?term="+reply,NavUpdate),liking=1))}function itemFiler(e){var t=$j("input").css("border-color");$j.get("filer/",function(n){$j.fancybox(n),$j("#id_term").keypress(function(){$j(this).css("border-color",t)}),$j("#select_term").change(function(){$j("#id_term").css("border-color",t)}),$j("#filer_save").click(function(t){return t.preventDefault(),reply=$j("#id_term").val(),reply&&reply.length?(commentBusy=!0,$j("body").css("cursor","wait"),$j.get("filer/"+e+"?term="+reply,NavUpdate),liking=1,$j.fancybox.close()):$j("#id_term").css("border-color","#FF0000"),!1})})}function jotClearLocation(){$j("#jot-coord").val(""),$j("#profile-nolocation-wrapper").hide()}function addeditortext(e){if(plaintext=="none"){var t=$j("#profile-jot-text").val();$j("#profile-jot-text").val(t+e)}else tinyMCE.execCommand("mceInsertRawHTML",!1,e)}$j(document).ready(function(){window.navMenuTimeout={"#network-menu-list-timeout":null,"#contacts-menu-list-timeout":null,"#system-menu-list-timeout":null,"#network-menu-list-opening":!1,"#contacts-menu-list-opening":!1,"#system-menu-list-opening":!1,"#network-menu-list-closing":!1,"#contacts-menu-list-closing":!1,"#system-menu-list-closing":!1},typeof window.aclInit!="undefined"&&typeof acl=="undefined"&&(acl=new ACL(baseurl+"/acl",[window.allowCID,window.allowGID,window.denyCID,window.denyGID])),$j("#profile-jot-text").focus(enableOnUser),$j("#profile-jot-text").click(enableOnUser),$j(".nav-menu-link").hover(function(){showNavMenu($j(this).attr("rel"))},function(){hideNavMenu($j(this).attr("rel"))}),$j(".group-edit-icon").hover(function(){$j(this).addClass("icon"),$j(this).removeClass("iconspacer")},function(){$j(this).removeClass("icon"),$j(this).addClass("iconspacer")}),$j(".sidebar-group-element").hover(function(){id=$j(this).attr("id"),$j("#edit-"+id).addClass("icon"),$j("#edit-"+id).removeClass("iconspacer")},function(){id=$j(this).attr("id"),$j("#edit-"+id).removeClass("icon"),$j("#edit-"+id).addClass("iconspacer")}),$j(".savedsearchdrop").hover(function(){$j(this).addClass("drop"),$j(this).addClass("icon"),$j(this).removeClass("iconspacer")},function(){$j(this).removeClass("drop"),$j(this).removeClass("icon"),$j(this).addClass("iconspacer")}),$j(".savedsearchterm").hover(function(){id=$j(this).attr("id"),$j("#drop-"+id).addClass("icon"),$j("#drop-"+id).addClass("drophide"),$j("#drop-"+id).removeClass("iconspacer")},function(){id=$j(this).attr("id"),$j("#drop-"+id).removeClass("icon"),$j("#drop-"+id).removeClass("drophide"),$j("#drop-"+id).addClass("iconspacer")}),window.autoCompleteType=="display-head"&&$j(".comment-wwedit-wrapper textarea").contact_autocomplete(baseurl+"/acl");if(window.aclType=="event_head"){$j("#events-calendar").fullCalendar({events:baseurl+"/events/json/",header:{left:"prev,next today",center:"title",right:"month,agendaWeek,agendaDay"},timeFormat:"H(:mm)",eventClick:function(e,t,n){showEvent(e.id)},eventRender:function(e,t,n){if(e.item["author-name"]==null)return;switch(n.name){case"month":t.find(".fc-event-title").html("{1} : {2}".format(e.item["author-avatar"],e.item["author-name"],e.title));break;case"agendaWeek":t.find(".fc-event-title").html("{1}

    {2}

    {3}

    ".format(e.item["author-avatar"],e.item["author-name"],e.item.desc,e.item.location));break;case"agendaDay":t.find(".fc-event-title").html("{1}

    {2}

    {3}

    ".format(e.item["author-avatar"],e.item["author-name"],e.item.desc,e.item.location))}}});var e=location.href.replace(baseurl,"").split("/");e.length>=4&&$j("#events-calendar").fullCalendar("gotoDate",e[2],e[3]-1);var t=location.hash.split("-");t.length==2&&t[0]=="#link"&&showEvent(t[1])}$j("#event-share-checkbox").change(function(){$j("#event-share-checkbox").is(":checked")?$j("#acl-wrapper").show():$j("#acl-wrapper").hide()}).trigger("change"),(window.aclType=="settings-head"||window.aclType=="photos_head"||window.aclType=="event_head")&&$j("#contact_allow, #contact_deny, #group_allow, #group_deny").change(function(){var e;$j("#contact_allow option:selected, #contact_deny option:selected, #group_allow option:selected, #group_deny option:selected").each(function(){e=$j(this).text(),$j("#jot-perms-icon").removeClass("unlock").addClass("lock"),$j("#jot-public").hide()}),e==null&&($j("#jot-perms-icon").removeClass("lock").addClass("unlock"),$j("#jot-public").show())}).trigger("change");switch(window.autocompleteType){case"msg-header":var n=$j("#recip").autocomplete({serviceUrl:baseurl+"/acl",minChars:2,width:350,onSelect:function(e,t){$j("#recip-complete").val(t)}});break;case"contacts-head":var n=$j("#contacts-search").autocomplete({serviceUrl:baseurl+"/acl",minChars:2,width:350});n.setOptions({params:{type:"a"}});break;default:}if(typeof window.AjaxUpload!="undefined")switch(window.ajaxType){case"jot-header":var r=new window.AjaxUpload("wall-image-upload",{action:"wall_upload/"+window.nickname,name:"userfile",onSubmit:function(e,t){$j("#profile-rotator").show()},onComplete:function(e,t){addeditortext(t),$j("#profile-rotator").hide()}}),i=new window.AjaxUpload("wall-file-upload",{action:"wall_attach/"+window.nickname,name:"userfile",onSubmit:function(e,t){$j("#profile-rotator").show()},onComplete:function(e,t){addeditortext(t),$j("#profile-rotator").hide()}});break;case"msg-header":var r=new window.AjaxUpload("prvmail-upload",{action:"wall_upload/"+window.nickname,name:"userfile",onSubmit:function(e,t){$j("#profile-rotator").show()},onComplete:function(e,t){tinyMCE.execCommand("mceInsertRawHTML",!1,t),$j("#profile-rotator").hide()}});break;default:}}),$j(function(){$j("nav").bind("nav-update",function(e,t){var n=$j("#pending-update"),r=$j(t).find("register").text();r=="0"?(r="",n.hide()):n.show(),n.html(r)})}),$j(function(){$j("#cnftheme").fancybox({width:800,autoDimensions:!1,onStart:function(){var e=$j("#id_theme :selected").val(),t=$j("#id_theme_mobile :selected").val();$j("#cnftheme").attr("href",baseurl+"/admin/themes/"+e)},onComplete:function(){$j("div#fancybox-content form").submit(function(e){var t=$j(this).attr("action"),n={};return $j(this).find("input").each(function(){n[$j(this).attr("name")]=$j(this).val()}),$j(this).find("select").each(function(){n[$j(this).attr("name")]=$j(this).children(":selected").val()}),console.log(":)",t,n),$j.post(t,n,function(e){timer&&clearTimeout(timer),NavUpdate(),$j.fancybox.close()}),!1})}})}),typeof window.photoEdit!="undefined"&&$j(document).keydown(function(e){window.prevLink!=""&&e.ctrlKey&&e.keyCode==37&&(e.preventDefault(),window.location.href=window.prevLink),window.nextLink!=""&&e.ctrlKey&&e.keyCode==39&&(e.preventDefault(),window.location.href=window.nextLink)});switch(window.ajaxType){case"jot-header":function jotGetLink(){reply=prompt(window.linkURL),reply&&reply.length&&(reply=bin2hex(reply),$j("#profile-rotator").show(),$j.get("parse_url?binurl="+reply,function(e){addeditortext(e),$j("#profile-rotator").hide()}))}function linkdrop(e){var t=e.dataTransfer.getData("text/uri-list");e.target.textContent=t,e.preventDefault(),t&&t.length&&(t=bin2hex(t),$j("#profile-rotator").show(),$j.get("parse_url?binurl="+t,function(e){editor||$j("#profile-jot-text").val(""),initEditor(function(){addeditortext(e),$j("#profile-rotator").hide()})}))}break;case"msg-header":case"wallmsg-header":function jotGetLink(){reply=prompt(window.linkURL),reply&&reply.length&&($j("#profile-rotator").show(),$j.get("parse_url?url="+reply,function(e){tinyMCE.execCommand("mceInsertRawHTML",!1,e),$j("#profile-rotator").hide()}))}function linkdrop(e){var t=e.dataTransfer.getData("text/uri-list");e.target.textContent=t,e.preventDefault(),t&&t.length&&($j("#profile-rotator").show(),$j.get("parse_url?url="+t,function(e){tinyMCE.execCommand("mceInsertRawHTML",!1,e),$j("#profile-rotator").hide()}))}break;default:}var editor=!1,textlen=0,plaintext=window.editSelect,ispublic=window.isPublic;typeof window.geoTag=="function"&&window.geoTag(); \ No newline at end of file diff --git a/view/theme/frost/nav.tpl b/view/theme/frost/nav.tpl index 89e1168ab..755f8a628 100644 --- a/view/theme/frost/nav.tpl +++ b/view/theme/frost/nav.tpl @@ -8,7 +8,7 @@ diff --git a/view/theme/quattro/quattro.less b/view/theme/quattro/quattro.less index 84aa13ac0..51fdfcf7c 100644 --- a/view/theme/quattro/quattro.less +++ b/view/theme/quattro/quattro.less @@ -314,6 +314,18 @@ aside { li { padding: 0px; margin: 0px; list-style: none; } } + #wallmessage-link { + display: block; + .rounded(); + color: @AsideConnect; + background: @AsideConnectBg url('../../../images/connect-bg.png') no-repeat left center; + font-weight: bold; + text-transform:uppercase; + padding: 4px 2px 2px 35px; + margin-top: 3px; + + &:hover { text-decoration: none; background-color: @AsideConnectHoverBg; } + } #dfrn-request-link { display: block; .rounded(); diff --git a/view/theme/slackr/theme.php b/view/theme/slackr/theme.php index 988700860..65a92c184 100644 --- a/view/theme/slackr/theme.php +++ b/view/theme/slackr/theme.php @@ -37,13 +37,22 @@ function insertFormatting(comment,BBcode,id) { return true; } -function cmtBbOpen(id) { - $(".comment-edit-bb-" + id).show(); +function cmtBbOpen(comment, id) { + if($(comment).hasClass('comment-edit-text-full')) { + $(".comment-edit-bb-" + id).show(); + return true; + } + return false; } -function cmtBbClose(id) { - $(".comment-edit-bb-" + id).hide(); +function cmtBbClose(comment, id) { +// if($(comment).hasClass('comment-edit-text-empty')) { +// $(".comment-edit-bb-" + id).hide(); +// return true; +// } + return false; } + function hidecal() { if(editor) return; $('.fc').hide(); diff --git a/view/theme/smoothly/arrow.png b/view/theme/smoothly/arrow.png new file mode 100644 index 000000000..1fabe88b6 Binary files /dev/null and b/view/theme/smoothly/arrow.png differ diff --git a/view/theme/smoothly/bottom.tpl b/view/theme/smoothly/bottom.tpl new file mode 100644 index 000000000..347d87094 --- /dev/null +++ b/view/theme/smoothly/bottom.tpl @@ -0,0 +1,52 @@ + + diff --git a/view/theme/smoothly/categories_widget.tpl b/view/theme/smoothly/categories_widget.tpl new file mode 100644 index 000000000..773f3d7d6 --- /dev/null +++ b/view/theme/smoothly/categories_widget.tpl @@ -0,0 +1,12 @@ +
    +

    $title

    +
    $desc
    + + + +
    diff --git a/view/theme/smoothly/default.php b/view/theme/smoothly/default.php new file mode 100644 index 000000000..a136a82d3 --- /dev/null +++ b/view/theme/smoothly/default.php @@ -0,0 +1,30 @@ + + + + <?php if(x($page,'title')) echo $page['title'] ?> + + + + +
    + +
    + + + + + +
    + +
    + + + +
    + +
    + + + + + diff --git a/view/theme/smoothly/down.png b/view/theme/smoothly/down.png new file mode 100644 index 000000000..ab6f9fd49 Binary files /dev/null and b/view/theme/smoothly/down.png differ diff --git a/view/theme/smoothly/events_reminder.tpl b/view/theme/smoothly/events_reminder.tpl new file mode 100644 index 000000000..0a12d3ee4 --- /dev/null +++ b/view/theme/smoothly/events_reminder.tpl @@ -0,0 +1,41 @@ + + + + +
    +
    +
    diff --git a/view/theme/smoothly/follow.tpl b/view/theme/smoothly/follow.tpl index 9c8a6bf3f..09258b9c3 100644 --- a/view/theme/smoothly/follow.tpl +++ b/view/theme/smoothly/follow.tpl @@ -1,7 +1,7 @@

    $connect

    $desc
    - +
    diff --git a/view/theme/smoothly/footer.tpl b/view/theme/smoothly/footer.tpl new file mode 100644 index 000000000..25058a7ff --- /dev/null +++ b/view/theme/smoothly/footer.tpl @@ -0,0 +1,3 @@ + \ No newline at end of file diff --git a/view/theme/smoothly/generic_links_widget.tpl b/view/theme/smoothly/generic_links_widget.tpl new file mode 100644 index 000000000..a1159f5bc --- /dev/null +++ b/view/theme/smoothly/generic_links_widget.tpl @@ -0,0 +1,11 @@ +
    + {{if $title}}

    $title

    {{endif}} + {{if $desc}}
    $desc
    {{endif}} + +
      + {{ for $items as $item }} +
    • $item.label
    • + {{ endfor }} +
    + +
    diff --git a/view/theme/smoothly/group_edit.tpl b/view/theme/smoothly/group_edit.tpl deleted file mode 100644 index a8b3f92a0..000000000 --- a/view/theme/smoothly/group_edit.tpl +++ /dev/null @@ -1,16 +0,0 @@ -

    $title

    - - -
    -
    -
    - - - - $drop -
    -
    -
    $desc
    -
    -
    -
    diff --git a/view/theme/smoothly/header.tpl b/view/theme/smoothly/header.tpl new file mode 100644 index 000000000..e69de29bb diff --git a/view/theme/smoothly/jot.tpl b/view/theme/smoothly/jot.tpl index 5f711cf24..437eec437 100644 --- a/view/theme/smoothly/jot.tpl +++ b/view/theme/smoothly/jot.tpl @@ -14,11 +14,18 @@ -
    -
    +
    + +
    +
    + +
    - - +
    +
    -
    {{ if $item.location }}$item.location {{ endif }}
    +
    + {{ if $item.location }} + $item.location + {{ endif }} +
    - {{ if $item.lock }}
    $item.lock
    {{ else }}
    {{ endif }} + {{ if $item.lock }} +
    + $item.lock +
    + {{ else }} +
    + {{ endif }}
    @@ -58,34 +68,45 @@
    --> -
    + + +
    + {{ if $item.edpost }} + + {{ endif }} +
    - {{ if $item.drop.dropping }}{{ endif }} + {{ if $item.drop.dropping }} + + {{ endif }}
    - {{ if $item.drop.dropping }}{{ endif }} + + {{ if $item.drop.dropping }} + {{ endif }} +
    -
    diff --git a/view/theme/smoothly/wallwall_item.tpl b/view/theme/smoothly/wallwall_item.tpl index e4849cf0b..eb9539681 100644 --- a/view/theme/smoothly/wallwall_item.tpl +++ b/view/theme/smoothly/wallwall_item.tpl @@ -12,45 +12,59 @@ $item.name menu -
    -
      - $item.item_photo_menu -
    -
    +
    +
      + $item.item_photo_menu +
    +
    +
    -
    {{ if $item.location }}$item.location {{ endif }}
    +
    + {{ if $item.location }} + $item.location + {{ endif }} +
    +
    - {{ if $item.lock }}
    $item.lock
    - {{ else }}
    {{ endif }} + {{ if $item.lock }} +
    + $item.lock +
    + {{ else }} +
    + {{ endif }}
    +
    $item.title
    $item.body -
    - {{ for $item.tags as $tag }} - $tag - {{ endfor }} -
    +
    + {{ for $item.tags as $tag }} + $tag + {{ endfor }} +
    -
    + + + +
    + {{ if $item.edpost }} + + {{ endif }} +
    - {{ if $item.drop.dropping }}{{ endif }} + {{ if $item.drop.dropping }} + + {{ endif }}
    - {{ if $item.drop.dropping }}{{ endif }} + + {{ if $item.drop.dropping }} + {{ endif }} +
    +
    $item.dislike
    -
    - $item.comment -
    +
    $item.comment
    - diff --git a/view/theme/smoothly/wallwall_thread.tpl b/view/theme/smoothly/wallwall_thread.tpl index a660aacfd..06822d013 100644 --- a/view/theme/smoothly/wallwall_thread.tpl +++ b/view/theme/smoothly/wallwall_thread.tpl @@ -1,9 +1,11 @@ {{if $item.comment_firstcollapsed}}
    - $item.num_comments $item.hide_text + $item.num_comments + $item.hide_text