diff options
author | Andrew Manning <tamanning@zoho.com> | 2018-03-31 13:41:29 -0400 |
---|---|---|
committer | Andrew Manning <tamanning@zoho.com> | 2018-03-31 13:41:29 -0400 |
commit | 6decffb00c00fabcb4ef581084eaca038e340686 (patch) | |
tree | 34471f015e0b33007ad40059dfdd09c83a768fbb | |
parent | 1dc795722a8e748ebb98e8fab778cd4686a0654f (diff) | |
parent | 6433ce70a19be8c57edbc72f8df3a4c7ef52f389 (diff) | |
download | volse-hubzilla-6decffb00c00fabcb4ef581084eaca038e340686.tar.gz volse-hubzilla-6decffb00c00fabcb4ef581084eaca038e340686.tar.bz2 volse-hubzilla-6decffb00c00fabcb4ef581084eaca038e340686.zip |
Merge branch 'dev' into oauth2
-rw-r--r-- | Zotlabs/Module/Acl.php | 2 | ||||
-rw-r--r-- | Zotlabs/Module/Connedit.php | 6 | ||||
-rw-r--r-- | Zotlabs/Module/Directory.php | 4 | ||||
-rw-r--r-- | Zotlabs/Module/Display.php | 10 | ||||
-rw-r--r-- | Zotlabs/Module/Hashtags.php | 2 | ||||
-rw-r--r-- | Zotlabs/Module/Mail.php | 4 | ||||
-rw-r--r-- | Zotlabs/Module/Rpost.php | 4 | ||||
-rw-r--r-- | Zotlabs/Module/Tagger.php | 13 | ||||
-rw-r--r-- | Zotlabs/Module/Uexport.php | 4 | ||||
-rw-r--r-- | Zotlabs/Module/Wiki.php | 4 | ||||
-rw-r--r-- | Zotlabs/Widget/Newmember.php | 12 | ||||
-rwxr-xr-x | boot.php | 12 | ||||
-rw-r--r-- | include/account.php | 3 | ||||
-rw-r--r-- | include/attach.php | 10 | ||||
-rw-r--r-- | include/auth.php | 5 | ||||
-rw-r--r-- | include/channel.php | 15 | ||||
-rw-r--r-- | include/connections.php | 1 | ||||
-rw-r--r-- | include/features.php | 13 | ||||
-rw-r--r-- | include/hubloc.php | 3 | ||||
-rw-r--r-- | include/import.php | 5 | ||||
-rw-r--r-- | include/text.php | 10 | ||||
-rw-r--r-- | view/js/autocomplete.js | 3 | ||||
-rw-r--r-- | view/pdl/mod_display.pdl | 3 | ||||
-rw-r--r-- | view/tpl/wiki.tpl | 1 |
24 files changed, 99 insertions, 50 deletions
diff --git a/Zotlabs/Module/Acl.php b/Zotlabs/Module/Acl.php index 245b0a9b7..ef901aef1 100644 --- a/Zotlabs/Module/Acl.php +++ b/Zotlabs/Module/Acl.php @@ -95,7 +95,7 @@ class Acl extends \Zotlabs\Web\Controller { . "' IN xchan_name) else position('" . protect_sprintf(dbesc(punify($search))) . "' IN xchan_addr) end, "; $col = ((strpos($search,'@') !== false) ? 'xchan_addr' : 'xchan_name' ); - $sql_extra3 = "AND $col like " . protect_sprintf( "'%" . dbesc($search) . "%'" ) . " "; + $sql_extra3 = "AND $col like " . protect_sprintf( "'%" . dbesc(($col === 'xchan_addr') ? punify($search) : $search) . "%'" ) . " "; } else { diff --git a/Zotlabs/Module/Connedit.php b/Zotlabs/Module/Connedit.php index f359175c1..cb9c19cf0 100644 --- a/Zotlabs/Module/Connedit.php +++ b/Zotlabs/Module/Connedit.php @@ -828,7 +828,7 @@ class Connedit extends \Zotlabs\Web\Controller { $locstr = locations_by_netid($contact['xchan_hash']); if(! $locstr) - $locstr = $contact['xchan_url']; + $locstr = unpunify($contact['xchan_url']); $clone_warn = ''; $clonable = (in_array($contact['xchan_network'],['zot','rss']) ? true : false); @@ -852,8 +852,8 @@ class Connedit extends \Zotlabs\Web\Controller { '$permcat' => [ 'permcat', t('Permission role'), '', '<span class="loading invisible">' . t('Loading') . '<span class="jumping-dots"><span class="dot-1">.</span><span class="dot-2">.</span><span class="dot-3">.</span></span></span>',$permcats ], '$permcat_new' => t('Add permission role'), '$permcat_enable' => feature_enabled(local_channel(),'permcats'), - '$addr' => $contact['xchan_addr'], - '$primeurl' => $contact['xchan_url'], + '$addr' => unpunify($contact['xchan_addr']), + '$primeurl' => unpunify($contact['xchan_url']), '$section' => $section, '$sections' => $sections, '$vcard' => $vcard, diff --git a/Zotlabs/Module/Directory.php b/Zotlabs/Module/Directory.php index 62a1670f9..87387ef56 100644 --- a/Zotlabs/Module/Directory.php +++ b/Zotlabs/Module/Directory.php @@ -299,9 +299,9 @@ class Directory extends \Zotlabs\Web\Controller { if(strlen($out)) $out .= ', '; if($marr && in_arrayi($k,$marr)) - $out .= '<strong>' . $k . '</strong>'; + $out .= '<a href="' . z_root() . '/directory/f=&keywords=' . urlencode($k) .'"><strong>' . $k . '</strong></a>'; else - $out .= $k; + $out .= '<a href="' . z_root() . '/directory/f=&keywords=' . urlencode($k) .'">' . $k . '</a>'; } } diff --git a/Zotlabs/Module/Display.php b/Zotlabs/Module/Display.php index fa29ce66c..d3047bc59 100644 --- a/Zotlabs/Module/Display.php +++ b/Zotlabs/Module/Display.php @@ -102,7 +102,7 @@ class Display extends \Zotlabs\Web\Controller { if($decoded) $item_hash = $decoded; - $r = q("select id, uid, mid, parent_mid, thr_parent, verb, item_type, item_deleted, item_blocked from item where mid like '%s' limit 1", + $r = q("select id, uid, mid, parent_mid, thr_parent, verb, item_type, item_deleted, author_xchan, item_blocked from item where mid like '%s' limit 1", dbesc($item_hash . '%') ); @@ -110,6 +110,13 @@ class Display extends \Zotlabs\Web\Controller { $target_item = $r[0]; } + $x = q("select * from xchan where xchan_hash = '%s' limit 1", + dbesc($target_item['author_xchan']) + ); + if($x) { + \App::$poi = $x[0]; + } + //if the item is to be moderated redirect to /moderate if($target_item['item_blocked'] == ITEM_MODERATED) { goaway(z_root() . '/moderate/' . $target_item['id']); @@ -169,6 +176,7 @@ class Display extends \Zotlabs\Web\Controller { } } + $static = ((array_key_exists('static',$_REQUEST)) ? intval($_REQUEST['static']) : 0); diff --git a/Zotlabs/Module/Hashtags.php b/Zotlabs/Module/Hashtags.php index edb631871..300485196 100644 --- a/Zotlabs/Module/Hashtags.php +++ b/Zotlabs/Module/Hashtags.php @@ -18,7 +18,7 @@ class Hashtags extends \Zotlabs\Web\Controller { ); if($r) { foreach($r as $rv) { - $result[] = [ 'text' => strtolower($rv['term']) ]; + $result[] = [ 'text' => $rv['term'] ]; } } diff --git a/Zotlabs/Module/Mail.php b/Zotlabs/Module/Mail.php index b58b169d0..ca183f644 100644 --- a/Zotlabs/Module/Mail.php +++ b/Zotlabs/Module/Mail.php @@ -67,14 +67,14 @@ class Mail extends \Zotlabs\Web\Controller { if(! $recipient) { $channel = \App::get_channel(); - $j = \Zotlabs\Zot\Finger::run($rstr,$channel); + $j = \Zotlabs\Zot\Finger::run(punify($rstr),$channel); if(! $j['success']) { notice( t('Unable to lookup recipient.') . EOL); return; } - logger('message_post: lookup: ' . $url . ' ' . print_r($j,true)); + logger('message_post: lookup: ' . $rstr . ' ' . print_r($j,true)); if(! $j['guid']) { notice( t('Unable to communicate with requested channel.')); diff --git a/Zotlabs/Module/Rpost.php b/Zotlabs/Module/Rpost.php index e6ea52845..f0c4a06b9 100644 --- a/Zotlabs/Module/Rpost.php +++ b/Zotlabs/Module/Rpost.php @@ -45,7 +45,9 @@ class Rpost extends \Zotlabs\Web\Controller { $url = get_rpost_path(\App::get_observer()); // make sure we're not looping to our own hub if(($url) && (! stristr($url, \App::get_hostname()))) { - foreach($_REQUEST as $key => $arg) { + foreach($_GET as $key => $arg) { + if($key === 'q') + continue; $url .= '&' . $key . '=' . $arg; } goaway($url); diff --git a/Zotlabs/Module/Tagger.php b/Zotlabs/Module/Tagger.php index 603a95f2b..24adf1bde 100644 --- a/Zotlabs/Module/Tagger.php +++ b/Zotlabs/Module/Tagger.php @@ -80,6 +80,8 @@ class Tagger extends \Zotlabs\Web\Controller { break; } + + $clean_term = trim($term,'"\' '); $links = array(array('rel' => 'alternate','type' => 'text/html', 'href' => z_root() . '/display/' . gen_link_id($item['mid']))); @@ -103,15 +105,15 @@ class Tagger extends \Zotlabs\Web\Controller { ), )); - $tagid = z_root() . '/search?tag=' . $term; + $tagid = z_root() . '/search?tag=' . $clean_term; $objtype = ACTIVITY_OBJ_TAGTERM; $obj = json_encode(array( 'type' => $objtype, 'id' => $tagid, 'link' => array(array('rel' => 'alternate','type' => 'text/html', 'href' => $tagid)), - 'title' => $term, - 'content' => $term + 'title' => $clean_term, + 'content' => $clean_term )); $bodyverb = t('%1$s tagged %2$s\'s %3$s with %4$s'); @@ -119,7 +121,7 @@ class Tagger extends \Zotlabs\Web\Controller { // saving here for reference // also check out x22d5 and x2317 and x0d6b and x0db8 and x24d0 and xff20 !!! - $termlink = html_entity_decode('⋕') . '[zrl=' . z_root() . '/search?tag=' . urlencode($term) . ']'. $term . '[/zrl]'; + $termlink = html_entity_decode('⋕') . '[zrl=' . z_root() . '/search?tag=' . urlencode($clean_term) . ']'. $clean_term . '[/zrl]'; $channel = \App::get_channel(); @@ -143,8 +145,7 @@ class Tagger extends \Zotlabs\Web\Controller { $arr['obj_type'] = $objtype; $arr['obj'] = $obj; $arr['parent_mid'] = $item['mid']; - - store_item_tag($item['uid'],$item['id'],TERM_OBJ_POST,TERM_COMMUNITYTAG,$term,$tagid); + store_item_tag($item['uid'],$item['id'],TERM_OBJ_POST,TERM_COMMUNITYTAG,$clean_term,$tagid); $ret = post_activity_item($arr); if($ret['success']) { diff --git a/Zotlabs/Module/Uexport.php b/Zotlabs/Module/Uexport.php index 28c840ceb..9af1887dc 100644 --- a/Zotlabs/Module/Uexport.php +++ b/Zotlabs/Module/Uexport.php @@ -22,8 +22,8 @@ class Uexport extends \Zotlabs\Web\Controller { $month = intval(argv(2)); } - header('content-type: application/octet_stream'); - header('content-disposition: attachment; filename="' . $channel['channel_address'] . (($year) ? '-' . $year : '') . (($month) ? '-' . $month : '') . '.json"' ); + header('content-type: application/json'); + header('content-disposition: attachment; filename="' . $channel['channel_address'] . (($year) ? '-' . $year : '') . (($month) ? '-' . $month : '') . (($_REQUEST['sections']) ? '-' . $_REQUEST['sections'] : '') . '.json"' ); if($year) { echo json_encode(identity_export_year(local_channel(),$year,$month)); diff --git a/Zotlabs/Module/Wiki.php b/Zotlabs/Module/Wiki.php index ae543eb98..696191f70 100644 --- a/Zotlabs/Module/Wiki.php +++ b/Zotlabs/Module/Wiki.php @@ -284,6 +284,8 @@ class Wiki extends \Zotlabs\Web\Controller { $wikiheaderPage = urldecode($pageUrlName); $renamePage = (($wikiheaderPage === 'Home') ? '' : t('Rename page')); + $sharePage = t('Share'); + $p = []; if(! $ignore_language) { @@ -354,6 +356,8 @@ class Wiki extends \Zotlabs\Web\Controller { '$wikiheaderName' => $wikiheaderName, '$wikiheaderPage' => $wikiheaderPage, '$renamePage' => $renamePage, + '$sharePage' => $sharePage, + '$shareLink' => urlencode('#^[zrl=' . z_root() . '/wiki/' . argv(1) . '/' . $wikiUrlName . '/' . $pageUrlName . ']' . '[ ' . $owner['channel_name'] . ' ] - ' . $wikiheaderName . ' - ' . $wikiheaderPage . '[/zrl]'), '$showPageControls' => $showPageControls, '$editOrSourceLabel' => (($showPageControls) ? t('Edit') : t('Source')), '$tools_label' => 'Page Tools', diff --git a/Zotlabs/Widget/Newmember.php b/Zotlabs/Widget/Newmember.php index afa808e6f..1a4b575b9 100644 --- a/Zotlabs/Widget/Newmember.php +++ b/Zotlabs/Widget/Newmember.php @@ -9,9 +9,6 @@ class Newmember { if(! local_channel()) return EMPTY_STR; - if(get_pconfig(local_channel(), 'system', 'disable_newmemberwidget')) - return EMPTY_STR; - $c = \App::get_channel(); if(! $c) return EMPTY_STR; @@ -20,16 +17,9 @@ class Newmember { if(! $a) return EMPTY_STR; - if(datetime_convert('UTC','UTC',$a['account_created']) < datetime_convert('UTC','UTC', 'now - 60 days')) - return EMPTY_STR; - - // This could be a new account that was used to clone a very old channel - - $ob = \App::get_observer(); - if($ob && array_key_exists('xchan_name_date',$ob) && $ob['xchan_name_date'] < datetime_convert('UTC','UTC','now - 60 days')) + if(! feature_enabled(local_channel(),'start_menu')) return EMPTY_STR; - $options = [ t('Profile Creation'), [ @@ -50,7 +50,7 @@ require_once('include/attach.php'); require_once('include/bbcode.php'); define ( 'PLATFORM_NAME', 'hubzilla' ); -define ( 'STD_VERSION', '3.3.2' ); +define ( 'STD_VERSION', '3.3.3' ); define ( 'ZOT_REVISION', '6.0a' ); @@ -857,7 +857,7 @@ class App { self::$scheme = 'https'; if(x($_SERVER,'SERVER_NAME')) { - self::$hostname = $_SERVER['SERVER_NAME']; + self::$hostname = punify($_SERVER['SERVER_NAME']); if(x($_SERVER,'SERVER_PORT') && $_SERVER['SERVER_PORT'] != 80 && $_SERVER['SERVER_PORT'] != 443) self::$hostname .= ':' . $_SERVER['SERVER_PORT']; @@ -954,14 +954,14 @@ class App { && is_array(self::$config['system']) && array_key_exists('baseurl',self::$config['system']) && strlen(self::$config['system']['baseurl'])) { - $url = self::$config['system']['baseurl']; + $url = punify(self::$config['system']['baseurl']); $url = trim($url,'\\/'); return $url; } $scheme = self::$scheme; - self::$baseurl = $scheme . "://" . self::$hostname . ((isset(self::$path) && strlen(self::$path)) ? '/' . self::$path : '' ); + self::$baseurl = $scheme . "://" . punify(self::$hostname) . ((isset(self::$path) && strlen(self::$path)) ? '/' . self::$path : '' ); return self::$baseurl; } @@ -972,7 +972,7 @@ class App { && is_array(self::$config['system']) && array_key_exists('baseurl',self::$config['system']) && strlen(self::$config['system']['baseurl'])) { - $url = self::$config['system']['baseurl']; + $url = punify(self::$config['system']['baseurl']); $url = trim($url,'\\/'); } @@ -983,7 +983,7 @@ class App { if($parsed !== false) { self::$scheme = $parsed['scheme']; - self::$hostname = $parsed['host']; + self::$hostname = punify($parsed['host']); if(x($parsed,'port')) self::$hostname .= ':' . $parsed['port']; if(x($parsed,'path')) diff --git a/include/account.php b/include/account.php index 40cf281c3..2b24364f4 100644 --- a/include/account.php +++ b/include/account.php @@ -23,6 +23,7 @@ function get_account_by_id($account_id) { function check_account_email($email) { + $email = punify($email); $result = array('error' => false, 'message' => ''); // Caution: empty email isn't counted as an error in this function. @@ -139,7 +140,7 @@ function create_account($arr) { $result = array('success' => false, 'email' => '', 'password' => '', 'message' => ''); $invite_code = ((x($arr,'invite_code')) ? notags(trim($arr['invite_code'])) : ''); - $email = ((x($arr,'email')) ? notags(trim($arr['email'])) : ''); + $email = ((x($arr,'email')) ? notags(punify(trim($arr['email']))) : ''); $password = ((x($arr,'password')) ? trim($arr['password']) : ''); $password2 = ((x($arr,'password2')) ? trim($arr['password2']) : ''); $parent = ((x($arr,'parent')) ? intval($arr['parent']) : 0 ); diff --git a/include/attach.php b/include/attach.php index 39269eb03..363005029 100644 --- a/include/attach.php +++ b/include/attach.php @@ -948,6 +948,16 @@ function attach_store($channel, $observer_hash, $options = '', $arr = null) { return $ret; } + // Update the folder timestamp @todo recurse to the storage root folder + + if($folder_hash) { + q("UPDATE attach set edited = '%s' where hash = '%s' and uid = %d and is_dir = 1", + dbesc($edited), + dbesc($folder_hash), + intval($channel_id) + ); + } + // Caution: This re-uses $sql_options set further above $r = q("select * from attach where uid = %d and hash = '%s' $sql_options limit 1", diff --git a/include/auth.php b/include/auth.php index 6f5e58361..844566919 100644 --- a/include/auth.php +++ b/include/auth.php @@ -37,6 +37,7 @@ require_once('include/security.php'); function account_verify_password($login, $pass) { $ret = [ 'account' => null, 'channel' => null, 'xchan' => null ]; + $login = punify($login); $email_verify = get_config('system', 'verify_email'); $register_policy = get_config('system', 'register_policy'); @@ -235,7 +236,7 @@ else { $record = null; $addon_auth = array( - 'username' => trim($_POST['username']), + 'username' => punify(trim($_POST['username'])), 'password' => trim($_POST['password']), 'authenticated' => 0, 'user_record' => null @@ -261,7 +262,7 @@ else { $verify = account_verify_password($_POST['username'], $_POST['password']); if($verify && array_key_exists('reason',$verify) && $verify['reason'] === 'unvalidated') { notice( t('Email validation is incomplete. Please check your email.')); - goaway(z_root() . '/email_validation/' . bin2hex(trim(escape_tags($_POST['username'])))); + goaway(z_root() . '/email_validation/' . bin2hex(punify(trim(escape_tags($_POST['username']))))); } elseif($verify) { $atoken = $verify['xchan']; diff --git a/include/channel.php b/include/channel.php index c94f5c657..460c818da 100644 --- a/include/channel.php +++ b/include/channel.php @@ -1573,14 +1573,25 @@ function advanced_profile() { $profile['howlong'] = relative_date(App::$profile['howlong'], t('for %1$d %2$s')); } + if(App::$profile['keywords']) { + $keywords = str_replace(',',' ', App::$profile['keywords']); + $keywords = str_replace(' ',' ', $keywords); + $karr = explode(' ', $keywords); + if($karr) { + for($cnt = 0; $cnt < count($karr); $cnt ++) { + $karr[$cnt] = '<a href="' . z_root() . '/directory/f=&keywords=' . trim($karr[$cnt]) . '">' . $karr[$cnt] . '</a>'; + } + } + $profile['keywords'] = array( t('Tags:'), implode(' ', $karr)); + } + + if(App::$profile['sexual']) $profile['sexual'] = array( t('Sexual Preference:'), App::$profile['sexual'] ); if(App::$profile['homepage']) $profile['homepage'] = array( t('Homepage:'), linkify(App::$profile['homepage']) ); if(App::$profile['hometown']) $profile['hometown'] = array( t('Hometown:'), linkify(App::$profile['hometown']) ); - if(App::$profile['keywords']) $profile['keywords'] = array( t('Tags:'), App::$profile['keywords']); - if(App::$profile['politic']) $profile['politic'] = array( t('Political Views:'), App::$profile['politic']); if(App::$profile['religion']) $profile['religion'] = array( t('Religion:'), App::$profile['religion']); diff --git a/include/connections.php b/include/connections.php index c5d74d4ca..8d1b9e07f 100644 --- a/include/connections.php +++ b/include/connections.php @@ -100,7 +100,6 @@ function vcard_from_xchan($xchan, $observer = null, $mode = '') { if(! $xchan) return; -// FIXME - show connect button to observer if appropriate $connect = false; if(local_channel()) { $r = q("select * from abook where abook_xchan = '%s' and abook_channel = %d limit 1", diff --git a/include/features.php b/include/features.php index 993266977..5481c37a4 100644 --- a/include/features.php +++ b/include/features.php @@ -28,8 +28,9 @@ function get_feature_default($feature) { $f = get_features(false); foreach($f as $cat) { foreach($cat as $feat) { - if(is_array($feat) && $feat[0] === $feature) + if(is_array($feat) && $feat[0] === $feature) { return $feat[3]; + } } } return false; @@ -45,6 +46,7 @@ function feature_level($feature,$def) { function get_features($filtered = true) { + $account = \App::get_account(); $arr = [ @@ -53,7 +55,14 @@ function get_features($filtered = true) { t('General Features'), - + [ + 'start_menu', + t('New Member Links'), + t('Display new member quick links menu'), + (($account['account_created'] > datetime_convert('','','now - 60 days')) ? true : false), + get_config('feature_lock','start_menu'), + feature_level('start_menu',1), + ], [ 'advanced_profiles', diff --git a/include/hubloc.php b/include/hubloc.php index 0d1a2e560..33d5dcbb2 100644 --- a/include/hubloc.php +++ b/include/hubloc.php @@ -270,7 +270,8 @@ function locations_by_netid($netid) { dbesc($netid) ); - return array_elm_to_str($locs,'location',', '); + + return array_elm_to_str($locs,'location',', ','trim_and_unpunify'); } diff --git a/include/import.php b/include/import.php index 9920df8be..d8b7030b6 100644 --- a/include/import.php +++ b/include/import.php @@ -21,6 +21,11 @@ function import_channel($channel, $account_id, $seize) { $channel['channel_removed'] = (($channel['channel_pageflags'] & 0x8000) ? 1 : 0); } + if(intval($channel['channel_removed'])) { + notice( t('Unable to import a removed channel.') . EOL); + return false; + } + // Ignore the hash provided and re-calculate $channel['channel_hash'] = make_xchan_hash($channel['channel_guid'],$channel['channel_guid_sig']); diff --git a/include/text.php b/include/text.php index c1e064857..f634f0d55 100644 --- a/include/text.php +++ b/include/text.php @@ -1491,7 +1491,7 @@ function format_hashtags(&$item) { $term = htmlspecialchars($t['term'], ENT_COMPAT, 'UTF-8', false) ; if(! trim($term)) continue; - if(strpos($item['body'], $t['url'])) + if($t['url'] && strpos($item['body'], $t['url'])) continue; if($s) $s .= ' '; @@ -2189,13 +2189,13 @@ function ids_to_querystr($arr,$idx = 'id',$quote = false) { * @returns string */ -function array_elm_to_str($arr,$elm,$delim = ',') { +function array_elm_to_str($arr,$elm,$delim = ',',$each = 'trim') { $tmp = []; if($arr && is_array($arr)) { foreach($arr as $x) { if(is_array($x) && array_key_exists($elm,$x)) { - $z = trim($x[$elm]); + $z = $each($x[$elm]); if(($z) && (! in_array($z,$tmp))) { $tmp[] = $z; } @@ -2205,7 +2205,9 @@ function array_elm_to_str($arr,$elm,$delim = ',') { return implode($delim,$tmp); } - +function trim_and_unpunify($s) { + return unpunify(trim($s)); +} /** diff --git a/view/js/autocomplete.js b/view/js/autocomplete.js index 2d017db18..7a1a7673d 100644 --- a/view/js/autocomplete.js +++ b/view/js/autocomplete.js @@ -210,8 +210,9 @@ function string2bb(element) { tags = { match: /(^|\s)(\#)([^ \n]{2,})$/, index: 3, - search: function(term, callback) { $.getJSON('/hashtags/' + '$f=&t=' + term).done(function(data) { callback($.map(data, function(entry) { return entry.text.indexOf(term) === 0 ? entry : null; })); }); }, + search: function(term, callback) { $.getJSON('/hashtags/' + '$f=&t=' + term).done(function(data) { callback($.map(data, function(entry) { return entry.text.toLowerCase().indexOf(term.toLowerCase()) === 0 ? entry : null; })); }); }, replace: function(item) { return "$1$2" + item.text + ' '; }, + context: function(text) { return text.toLowerCase(); }, template: tag_format }; diff --git a/view/pdl/mod_display.pdl b/view/pdl/mod_display.pdl index 95f069031..a5461df50 100644 --- a/view/pdl/mod_display.pdl +++ b/view/pdl/mod_display.pdl @@ -1,3 +1,6 @@ +[region=aside] +[widget=vcard][/widget] +[/region] [region=right_aside] [widget=notifications][/widget] [widget=newmember][/widget] diff --git a/view/tpl/wiki.tpl b/view/tpl/wiki.tpl index 2be323deb..6ca4b0c77 100644 --- a/view/tpl/wiki.tpl +++ b/view/tpl/wiki.tpl @@ -15,6 +15,7 @@ </div> </div> {{/if}} + <button type="button" class="btn btn-outline-secondary btn-sm" title="{{$sharePage}}" onclick="window.location.href='rpost?f=&body={{$shareLink}}';"><i class="fa fa-fw fa-share"></i></button> <button id="fullscreen-btn" type="button" class="btn btn-outline-secondary btn-sm" onclick="makeFullScreen(); adjustFullscreenEditorHeight();"><i class="fa fa-expand"></i></button> <button id="inline-btn" type="button" class="btn btn-outline-secondary btn-sm" onclick="makeFullScreen(false); adjustInlineEditorHeight()"><i class="fa fa-compress"></i></button> </div> |