diff options
Diffstat (limited to 'mod')
-rw-r--r-- | mod/channel.php | 2 | ||||
-rw-r--r-- | mod/chat.php | 4 | ||||
-rw-r--r-- | mod/connedit.php | 5 | ||||
-rw-r--r-- | mod/dirsearch.php | 4 | ||||
-rw-r--r-- | mod/editpost.php | 2 | ||||
-rw-r--r-- | mod/home.php | 6 | ||||
-rw-r--r-- | mod/import.php | 6 | ||||
-rw-r--r-- | mod/item.php | 3 | ||||
-rw-r--r-- | mod/mail.php | 92 | ||||
-rw-r--r-- | mod/photos.php | 113 | ||||
-rw-r--r-- | mod/pubsites.php | 4 | ||||
-rw-r--r-- | mod/search.php | 4 | ||||
-rwxr-xr-x | mod/setup.php | 6 | ||||
-rw-r--r-- | mod/siteinfo.php | 2 | ||||
-rw-r--r-- | mod/zfinger.php | 1 |
15 files changed, 148 insertions, 106 deletions
diff --git a/mod/channel.php b/mod/channel.php index f1b74136e..0af2666cc 100644 --- a/mod/channel.php +++ b/mod/channel.php @@ -173,7 +173,7 @@ function channel_content(&$a, $update = 0, $load = false) { $r = q("SELECT distinct parent AS `item_id`, created from item left join abook on ( item.owner_xchan = abook.abook_xchan $abook_uids ) WHERE uid = %d $item_normal - AND item_wall = 1 AND item_unseen = 1 + AND item_wall = 1 $simple_update AND (abook.abook_blocked = 0 or abook.abook_flags is null) $sql_extra ORDER BY created DESC", diff --git a/mod/chat.php b/mod/chat.php index ef9089b6f..79a5c050b 100644 --- a/mod/chat.php +++ b/mod/chat.php @@ -59,6 +59,9 @@ function chat_post(&$a) { $arr = $acl->get(); $arr['name'] = $room; + $arr['expire'] = intval($_POST['chat_expire']); + if(intval($arr['expire']) < 0) + $arr['expire'] = 0; chatroom_create($channel,$arr); @@ -204,6 +207,7 @@ function chat_content(&$a) { $o = replace_macros(get_markup_template('chatroom_new.tpl'),array( '$header' => t('New Chatroom'), '$name' => array('room_name',t('Chatroom Name'),'', ''), + '$chat_expire' => array('chat_expire',t('Expiration of chats (minutes)'),120,''), '$permissions' => t('Permissions'), '$acl' => populate_acl($channel_acl,false), '$submit' => t('Submit') diff --git a/mod/connedit.php b/mod/connedit.php index 75a5fd719..65eba885a 100644 --- a/mod/connedit.php +++ b/mod/connedit.php @@ -190,7 +190,7 @@ function connedit_post(&$a) { } } - $abook_pending = $new_friend ? 0 : $orig_record[0]['abook_pending']; + $abook_pending = (($new_friend) ? 0 : $orig_record[0]['abook_pending']); $r = q("UPDATE abook SET abook_profile = '%s', abook_my_perms = %d , abook_closeness = %d, abook_pending = %d, abook_incl = '%s', abook_excl = '%s' @@ -214,7 +214,6 @@ function connedit_post(&$a) { } - if($r) info( t('Connection updated.') . EOL); else @@ -222,7 +221,7 @@ function connedit_post(&$a) { if($a->poi && $a->poi['abook_my_perms'] != $abook_my_perms && (! intval($a->poi['abook_self']))) { - proc_run('php', 'include/notifier.php', 'permission_update', $contact_id); + proc_run('php', 'include/notifier.php', (($new_friend) ? 'permission_create' : 'permission_update'), $contact_id); } if($new_friend) { diff --git a/mod/dirsearch.php b/mod/dirsearch.php index ec730b28d..937564a79 100644 --- a/mod/dirsearch.php +++ b/mod/dirsearch.php @@ -436,9 +436,9 @@ function list_public_sites() { $register = 'closed'; if(strpos($rr['site_url'],'https://') !== false) - $ret['sites'][] = array('url' => $rr['site_url'], 'access' => $access, 'register' => $register, 'sellpage' => $rr['site_sellpage'], 'location' => $rr['site_location']); + $ret['sites'][] = array('url' => $rr['site_url'], 'access' => $access, 'register' => $register, 'sellpage' => $rr['site_sellpage'], 'location' => $rr['site_location'], 'project' => $rr['site_project']); else - $insecure[] = array('url' => $rr['site_url'], 'access' => $access, 'register' => $register, 'sellpage' => $rr['site_sellpage'], 'location' => $rr['site_location']); + $insecure[] = array('url' => $rr['site_url'], 'access' => $access, 'register' => $register, 'sellpage' => $rr['site_sellpage'], 'location' => $rr['site_location'], 'project' => $rr['site_project']); } if($insecure) { $ret['sites'] = array_merge($ret['sites'],$insecure); diff --git a/mod/editpost.php b/mod/editpost.php index d4dc35ef8..1bee16ee7 100644 --- a/mod/editpost.php +++ b/mod/editpost.php @@ -129,7 +129,7 @@ function editpost_content(&$a) { '$consensus' => intval($itm[0]['item_consensus']), '$wait' => t('Please wait'), '$permset' => t('Permission settings'), - '$ptyp' => $itm[0]['type'], + '$ptyp' => $itm[0]['obj_type'], '$content' => undo_post_tagging($itm[0]['body']), '$post_id' => $post_id, '$parent' => (($itm[0]['parent'] != $itm[0]['id']) ? $itm[0]['parent'] : ''), diff --git a/mod/home.php b/mod/home.php index 242b2dcec..bf2463bbc 100644 --- a/mod/home.php +++ b/mod/home.php @@ -59,12 +59,14 @@ function home_content(&$a, $update = 0, $load = false) { return $o; } } + if(strpos($frontpage,'http') !== 0) + $frontpage = z_root() . '/' . $frontpage; if(intval(get_config('system','mirror_frontpage'))) { - $o = '<html><head><title>' . t('$Projectname') . '</title></head><body style="margin: 0; padding: 0; border: none;" ><iframe src="' . z_root() . '/' . $frontpage . '" width="100%" height="100%" style="margin: 0; padding: 0; border: none;" ></iframe></body></html>'; + $o = '<html><head><title>' . t('$Projectname') . '</title></head><body style="margin: 0; padding: 0; border: none;" ><iframe src="' . $frontpage . '" width="100%" height="100%" style="margin: 0; padding: 0; border: none;" ></iframe></body></html>'; echo $o; killme(); } - goaway(z_root() . '/' . $frontpage); + goaway($frontpage); } diff --git a/mod/import.php b/mod/import.php index b6e36d734..72d8f92e9 100644 --- a/mod/import.php +++ b/mod/import.php @@ -441,6 +441,12 @@ function import_post(&$a) { if(is_array($data['chatroom'])) import_chatrooms($channel,$data['chatroom']); + if(is_array($data['conv'])) + import_conv($channel,$data['conv']); + + if(is_array($data['mail'])) + import_mail($channel,$data['mail']); + if(is_array($data['event'])) import_events($channel,$data['event']); diff --git a/mod/item.php b/mod/item.php index 7488e709b..4dcf8edd7 100644 --- a/mod/item.php +++ b/mod/item.php @@ -96,7 +96,7 @@ function item_post(&$a) { $owner_hash = null; $message_id = ((x($_REQUEST,'message_id') && $api_source) ? strip_tags($_REQUEST['message_id']) : ''); - $created = ((x($_REQUEST,'created')) ? datetime_convert('UTC','UTC',$_REQUEST['created']) : datetime_convert()); + $created = ((x($_REQUEST,'created')) ? datetime_convert(date_default_timezone_get(),'UTC',$_REQUEST['created']) : datetime_convert()); $post_id = ((x($_REQUEST,'post_id')) ? intval($_REQUEST['post_id']) : 0); $app = ((x($_REQUEST,'source')) ? strip_tags($_REQUEST['source']) : ''); $return_path = ((x($_REQUEST,'return')) ? $_REQUEST['return'] : ''); @@ -107,7 +107,6 @@ function item_post(&$a) { $layout_mid = ((x($_REQUEST,'layout_mid')) ? escape_tags($_REQUEST['layout_mid']): ''); $plink = ((x($_REQUEST,'permalink')) ? escape_tags($_REQUEST['permalink']) : ''); $obj_type = ((x($_REQUEST,'obj_type')) ? escape_tags($_REQUEST['obj_type']) : ACTIVITY_OBJ_NOTE); - // allow API to bulk load a bunch of imported items with sending out a bunch of posts. $nopush = ((x($_REQUEST,'nopush')) ? intval($_REQUEST['nopush']) : 0); diff --git a/mod/mail.php b/mod/mail.php index 525127a71..884c41565 100644 --- a/mod/mail.php +++ b/mod/mail.php @@ -97,7 +97,11 @@ function mail_post(&$a) { $ret = send_message(0, $recipient, $body, $subject, $replyto, $expires); - if(! $ret['success']) { + if($ret['success']) { + xchan_mail_query($ret['mail']); + build_sync_packet(0,array('conv' => array($ret['conv']),'mail' => array(encode_mail($ret['mail'],true)))); + } + else { notice($ret['message']); } @@ -149,6 +153,14 @@ function mail_content(&$a) { intval(argv(3)), intval(local_channel()) ); + $x = q("select * from mail where id = %d and channel_id = %d", + intval(argv(3)), + intval(local_channel()) + ); + if($x) { + build_sync_packet(local_channel(),array('mail' => encode_mail($x[0],true))); + } + proc_run('php','include/notifier.php','mail',intval(argv(3))); if($r) { @@ -185,68 +197,48 @@ function mail_content(&$a) { $a->page['htmlhead'] .= $header; - - $preselect = (isset($a->argv[2])?array($a->argv[2]):false); - $prename = $preurl = $preid = ''; - + $prename = ''; + $preid = ''; + if(x($_REQUEST,'hash')) { + $r = q("select abook.*, xchan.* from abook left join xchan on abook_xchan = xchan_hash where abook_channel = %d and abook_xchan = '%s' limit 1", intval(local_channel()), dbesc($_REQUEST['hash']) ); - if($r) { - $prename = $r[0]['xchan_name']; - $preurl = $r[0]['xchan_url']; - $preid = $r[0]['abook_id']; - $preselect = array($preid); - } - } + if(!$r) { + $r = q("select * from xchan where xchan_hash = '%s' and xchan_network = 'zot' limit 1", + dbesc($_REQUEST['hash']) + ); + } - if($preselect) { - $r = q("select abook.*, xchan.* from abook left join xchan on abook_xchan = xchan_hash - where abook_channel = %d and abook_id = %d limit 1", - intval(local_channel()), - intval(argv(2)) - ); if($r) { - $prename = $r[0]['xchan_name']; + $prename = (($r[0]['abook_id']) ? $r[0]['xchan_name'] : $r[0]['xchan_addr']); $preurl = $r[0]['xchan_url']; - $preid = $r[0]['abook_id']; + $preid = (($r[0]['abook_id']) ? ($r[0]['xchan_hash']) : ''); + } + else { + notice( t('Requested channel is not in this network') . EOL ); } - } - - $prefill = (($preselect) ? $prename : ''); - if(! $prefill) { - if(array_key_exists('to',$_REQUEST)) - $prefill = $_REQUEST['to']; } - // the ugly select box - - $select = contact_select('messageto','message-to-select', $preselect, 4, true, false, false, 10); - $tpl = get_markup_template('prv_message.tpl'); $o .= replace_macros($tpl,array( + '$new' => true, '$header' => t('Send Private Message'), '$to' => t('To:'), - '$showinputs' => 'true', - '$prefill' => $prefill, - '$autocomp' => $autocomp, + '$prefill' => $prename, '$preid' => $preid, '$subject' => t('Subject:'), '$subjtxt' => ((x($_REQUEST,'subject')) ? strip_tags($_REQUEST['subject']) : ''), '$text' => ((x($_REQUEST,'body')) ? htmlspecialchars($_REQUEST['body'], ENT_COMPAT, 'UTF-8') : ''), - '$readonly' => '', '$yourmessage' => t('Your message:'), - '$select' => $select, '$parent' => '', - '$upload' => t('Upload photo'), '$attach' => t('Attach file'), '$insert' => t('Insert web link'), - '$wait' => t('Please wait'), '$submit' => t('Send'), '$defexpire' => '', '$feature_expire' => ((feature_enabled(local_channel(),'content_expire')) ? true : false), @@ -254,8 +246,6 @@ function mail_content(&$a) { '$feature_encrypt' => ((feature_enabled(local_channel(),'content_encrypt')) ? true : false), '$encrypt' => t('Encrypt text'), '$cipher' => $cipher, - - )); return $o; @@ -285,7 +275,14 @@ function mail_content(&$a) { // if( local_channel() && feature_enabled(local_channel(),'richtext') ) // $plaintext = false; - $messages = private_messages_fetch_conversation(local_channel(), $mid, true); + + + if($mailbox == 'combined') { + $messages = private_messages_fetch_conversation(local_channel(), $mid, true); + } + else { + $messages = private_messages_fetch_message(local_channel(), $mid, true); + } if(! $messages) { //info( t('Message not found.') . EOL); @@ -347,10 +344,6 @@ function mail_content(&$a) { $recp = (($message['from_xchan'] === $channel['channel_hash']) ? 'to' : 'from'); -// FIXME - move this HTML to template - - $select = $message[$recp]['xchan_name'] . '<input type="hidden" name="messageto" value="' . $message[$recp]['xchan_hash'] . '" />'; - $parent = '<input type="hidden" name="replyto" value="' . $message['parent_mid'] . '" />'; $tpl = get_markup_template('mail_display.tpl'); $o = replace_macros($tpl, array( '$mailbox' => $mailbox, @@ -366,19 +359,16 @@ function mail_content(&$a) { // reply '$header' => t('Send Reply'), '$to' => t('To:'), - '$showinputs' => '', + '$reply' => true, '$subject' => t('Subject:'), '$subjtxt' => $message['title'], - '$readonly' => 'readonly="readonly"', - '$yourmessage' => t('Your message:'), + '$yourmessage' => sprintf(t('Your message for %s (%s):'), $message[$recp]['xchan_name'], $message[$recp]['xchan_addr']), '$text' => '', - '$select' => $select, - '$parent' => $parent, - '$upload' => t('Upload photo'), + '$parent' => $message['parent_mid'], + '$recphash' => $message[$recp]['xchan_hash'], '$attach' => t('Attach file'), '$insert' => t('Insert web link'), '$submit' => t('Submit'), - '$wait' => t('Please wait'), '$defexpire' => '', '$feature_expire' => ((feature_enabled(local_channel(),'content_expire')) ? true : false), '$expires' => t('Set expiration date'), diff --git a/mod/photos.php b/mod/photos.php index cd293b39d..33a895fdf 100644 --- a/mod/photos.php +++ b/mod/photos.php @@ -149,8 +149,9 @@ function photos_post(&$a) { if($r) { foreach($r as $i) { attach_delete($page_owner_uid, $i['resource_id'], 1 ); - drop_item($i['id'],false,DROPITEM_PHASE1,true /* force removal of linked items */); - proc_run('php','include/notifier.php','drop',$i['id']); + // This is now being done in attach_delete() + // drop_item($i['id'],false,DROPITEM_PHASE1,true /* force removal of linked items */); + // proc_run('php','include/notifier.php','drop',$i['id']); } } @@ -182,12 +183,14 @@ function photos_post(&$a) { ); if($r) { +/* q("DELETE FROM `photo` WHERE `uid` = %d AND `resource_id` = '%s'", intval($page_owner_uid), dbesc($r[0]['resource_id']) ); +*/ attach_delete($page_owner_uid, $r[0]['resource_id'], 1 ); - +/* $i = q("SELECT * FROM `item` WHERE `resource_id` = '%s' AND resource_type = 'photo' and `uid` = %d LIMIT 1", dbesc($r[0]['resource_id']), intval($page_owner_uid) @@ -196,6 +199,7 @@ function photos_post(&$a) { drop_item($i[0]['id'],true,DROPITEM_PHASE1); $url = $a->get_baseurl(); } +*/ } goaway($a->get_baseurl() . '/photos/' . $a->data['channel']['channel_address'] . '/album/' . $_SESSION['album_return']); @@ -229,15 +233,46 @@ function photos_post(&$a) { intval($page_owner_uid) ); if(count($r)) { - $ph = photo_factory(dbunescbin($r[0]['data']), $r[0]['type']); + $d = (($r[0]['os_storage']) ? @file_get_contents($r[0]['data']) : dbunescbin($r[0]['data'])); + $ph = photo_factory($d, $r[0]['type']); if($ph->is_valid()) { $rotate_deg = ( (intval($_POST['rotate']) == 1) ? 270 : 90 ); $ph->rotate($rotate_deg); $width = $ph->getWidth(); $height = $ph->getHeight(); + + if(intval($r[0]['os_storage'])) { + @file_put_contents($r[0]['data'],$ph->imageString()); + $data = $r[0]['data']; + $fsize = @filesize($r[0]['data']); + q("update attach set filesize = %d where hash = '%s' and uid = %d limit 1", + intval($fsize), + dbesc($resource_id), + intval($page_owner_uid) + ); + } + else { + $data = $ph->imageString(); + $fsize = strlen($data); + } + + $x = q("update photo set data = '%s', `size` = %d, height = %d, width = %d where `resource_id` = '%s' and uid = %d and scale = 0", + dbescbin($data), + intval($fsize), + intval($height), + intval($width), + dbesc($resource_id), + intval($page_owner_uid) + ); + + if($width > 1024 || $height > 1024) + $ph->scaleImage(1024); + + $width = $ph->getWidth(); + $height = $ph->getHeight(); - $x = q("update photo set data = '%s', height = %d, width = %d where `resource_id` = '%s' and uid = %d and scale = 0", + $x = q("update photo set data = '%s', height = %d, width = %d where `resource_id` = '%s' and uid = %d and scale = 1", dbescbin($ph->imageString()), intval($height), intval($width), @@ -245,38 +280,40 @@ function photos_post(&$a) { intval($page_owner_uid) ); - if($width > 640 || $height > 640) { + + if($width > 640 || $height > 640) $ph->scaleImage(640); - $width = $ph->getWidth(); - $height = $ph->getHeight(); - - $x = q("update photo set data = '%s', height = %d, width = %d where `resource_id` = '%s' and uid = %d and scale = 1", - dbescbin($ph->imageString()), - intval($height), - intval($width), - dbesc($resource_id), - intval($page_owner_uid) - ); - } - if($width > 320 || $height > 320) { + $width = $ph->getWidth(); + $height = $ph->getHeight(); + + $x = q("update photo set data = '%s', height = %d, width = %d where `resource_id` = '%s' and uid = %d and scale = 2", + dbescbin($ph->imageString()), + intval($height), + intval($width), + dbesc($resource_id), + intval($page_owner_uid) + ); + + + if($width > 320 || $height > 320) $ph->scaleImage(320); - $width = $ph->getWidth(); - $height = $ph->getHeight(); - $x = q("update photo set data = '%s', height = %d, width = %d where `resource_id` = '%s' and uid = %d and scale = 2", - dbescbin($ph->imageString()), - intval($height), - intval($width), - dbesc($resource_id), - intval($page_owner_uid) - ); - } + $width = $ph->getWidth(); + $height = $ph->getHeight(); + + $x = q("update photo set data = '%s', height = %d, width = %d where `resource_id` = '%s' and uid = %d and scale = 3", + dbescbin($ph->imageString()), + intval($height), + intval($width), + dbesc($resource_id), + intval($page_owner_uid) + ); } } } - $p = q("SELECT * FROM `photo` WHERE `resource_id` = '%s' AND `uid` = %d ORDER BY `scale` DESC", + $p = q("SELECT type, is_nsfw, description, resource_id, scale, allow_cid, allow_gid, deny_cid, deny_gid FROM photo WHERE resource_id = '%s' AND uid = %d ORDER BY scale DESC", dbesc($resource_id), intval($page_owner_uid) ); @@ -586,7 +623,9 @@ function photos_content(&$a) { '$nickname' => $a->data['channel']['channel_address'], '$newalbum_label' => t('Enter an album name'), '$newalbum_placeholder' => t('or select an existing album (doubleclick)'), - '$visible' => array('visible', t('Create a status post for this upload'), 0, '', array(t('No'), t('Yes'))), + '$visible' => array('visible', t('Create a status post for this upload'), 0,'', array(t('No'), t('Yes')), 'onclick="showHideBodyTextarea();"'), + '$caption' => array('description', t('Caption (optional):')), + '$body' => array('body', t('Description (optional):'),'', 'Description will only appear in the status post'), '$albums' => $albums['albums'], '$selname' => $selname, '$permissions' => t('Permissions'), @@ -982,13 +1021,13 @@ function photos_content(&$a) { $likebuttons = ''; if($can_post || $can_comment) { - $likebuttons = replace_macros($like_tpl,array( - '$id' => $link_item['id'], - '$likethis' => t("I like this \x28toggle\x29"), - '$nolike' => t("I don't like this \x28toggle\x29"), - '$share' => t('Share'), - '$wait' => t('Please wait') - )); + $likebuttons = array( + 'id' => $link_item['id'], + 'likethis' => t("I like this \x28toggle\x29"), + 'nolike' => t("I don't like this \x28toggle\x29"), + 'share' => t('Share'), + 'wait' => t('Please wait') + ); } $comments = ''; diff --git a/mod/pubsites.php b/mod/pubsites.php index 62990c70c..726c681fa 100644 --- a/mod/pubsites.php +++ b/mod/pubsites.php @@ -23,12 +23,12 @@ function pubsites_content(&$a) { $j = json_decode($ret['body'],true); if($j) { $rate_meta = ((local_channel()) ? '<td>' . t('Rate this hub') . '</td>' : ''); - $o .= '<table border="1"><tr><td>' . t('Site URL') . '</td><td>' . t('Access Type') . '</td><td>' . t('Registration Policy') . '</td><td>' . t('Location') . '</td><td>' . t('View hub ratings') . '</td>' . $rate_meta . '</tr>'; + $o .= '<table border="1"><tr><td>' . t('Site URL') . '</td><td>' . t('Access Type') . '</td><td>' . t('Registration Policy') . '</td><td>' . t('Location') . '</td><td>' . t('Project') . '</td><td>' . t('View hub ratings') . '</td>' . $rate_meta . '</tr>'; if($j['sites']) { foreach($j['sites'] as $jj) { $host = strtolower(substr($jj['url'],strpos($jj['url'],'://')+3)); $rate_links = ((local_channel()) ? '<td><a href="rate?f=&target=' . $host . '" class="btn-btn-default"><i class="icon-check"></i> ' . t('Rate') . '</a></td>' : ''); - $o .= '<tr><td>' . '<a href="'. (($jj['sellpage']) ? $jj['sellpage'] : $jj['url'] . '/register' ) . '" >' . $jj['url'] . '</a>' . '</td><td>' . $jj['access'] . '</td><td>' . $jj['register'] . '</td><td>' . $jj['location'] . '</td><td><a href="ratings/' . $host . '" class="btn-btn-default"><i class="icon-eye-open"></i> ' . t('View ratings') . '</a></td>' . $rate_links . '</tr>'; + $o .= '<tr><td>' . '<a href="'. (($jj['sellpage']) ? $jj['sellpage'] : $jj['url'] . '/register' ) . '" >' . $jj['url'] . '</a>' . '</td><td>' . $jj['access'] . '</td><td>' . $jj['register'] . '</td><td>' . $jj['location'] . '</td><td>' . $jj['project'] . '</td><td><a href="ratings/' . $host . '" class="btn-btn-default"><i class="icon-eye-open"></i> ' . t('View ratings') . '</a></td>' . $rate_links . '</tr>'; } } diff --git a/mod/search.php b/mod/search.php index ce8357fb9..a0085fca9 100644 --- a/mod/search.php +++ b/mod/search.php @@ -35,6 +35,8 @@ function search_content(&$a,$update = 0, $load = false) { $o = '<div id="live-search"></div>' . "\r\n"; + $o = '<div class="generic-content-wrapper-styled">' . "\r\n"; + $o .= '<h3>' . t('Search') . '</h3>'; if(x($a->data,'search')) @@ -212,6 +214,8 @@ function search_content(&$a,$update = 0, $load = false) { $o .= conversation($a,$items,'search',$update,'client'); + $o .= '</div>'; + return $o; } diff --git a/mod/setup.php b/mod/setup.php index 15820f14e..e5ac25965 100755 --- a/mod/setup.php +++ b/mod/setup.php @@ -292,7 +292,7 @@ function setup_content(&$a) { case 2: { // Database config - $dbhost = ((x($_POST,'dbhost')) ? notags(trim($_POST['dbhost'])) : 'localhost'); + $dbhost = ((x($_POST,'dbhost')) ? notags(trim($_POST['dbhost'])) : '127.0.0.1'); $dbuser = notags(trim($_POST['dbuser'])); $dbport = intval(notags(trim($_POST['dbport']))); $dbpass = notags(trim($_POST['dbpass'])); @@ -312,7 +312,7 @@ function setup_content(&$a) { '$status' => $wizard_status, - '$dbhost' => array('dbhost', t('Database Server Name'), $dbhost, t('Default is localhost')), + '$dbhost' => array('dbhost', t('Database Server Name'), $dbhost, t('Default is 127.0.0.1')), '$dbport' => array('dbport', t('Database Port'), $dbport, t('Communication port number - use 0 for default')), '$dbuser' => array('dbuser', t('Database Login Name'), $dbuser, ''), '$dbpass' => array('dbpass', t('Database Login Password'), $dbpass, ''), @@ -334,7 +334,7 @@ function setup_content(&$a) { }; break; case 3: { // Site settings require_once('include/datetime.php'); - $dbhost = ((x($_POST,'dbhost')) ? notags(trim($_POST['dbhost'])) : 'localhost'); + $dbhost = ((x($_POST,'dbhost')) ? notags(trim($_POST['dbhost'])) : '127.0.0.1'); $dbport = intval(notags(trim($_POST['dbuser']))); $dbuser = notags(trim($_POST['dbuser'])); $dbpass = notags(trim($_POST['dbpass'])); diff --git a/mod/siteinfo.php b/mod/siteinfo.php index 14aaef144..2fffccc73 100644 --- a/mod/siteinfo.php +++ b/mod/siteinfo.php @@ -165,7 +165,7 @@ function siteinfo_content(&$a) { '$loadavg_all' => $loadavg[0] . ', ' . $loadavg[1] . ', ' . $loadavg[2], '$commit' => $commit, '$web_location' => t('Running at web location') . ' ' . z_root(), - '$visit' => t('Please visit <a href="https://redmatrix.me">redmatrix.me</a> to learn more about $Projectname.'), + '$visit' => t('Please visit <a href="http://hubzilla.org">hubzilla.org</a> to learn more about $Projectname.'), '$bug_text' => t('Bug reports and issues: please visit'), '$bug_link_url' => 'https://github.com/redmatrix/hubzilla/issues', '$bug_link_text' => t('$projectname issues'), diff --git a/mod/zfinger.php b/mod/zfinger.php index fb3333280..fff7c9e1b 100644 --- a/mod/zfinger.php +++ b/mod/zfinger.php @@ -9,5 +9,4 @@ function zfinger_init(&$a) { $x = zotinfo($_REQUEST); json_return_and_die($x); - } |