Merge remote-tracking branch 'friendika/master'
This commit is contained in:
commit
ac6945eed1
33 changed files with 842 additions and 269 deletions
|
@ -27,7 +27,7 @@ function community_content(&$a, $update = 0) {
|
|||
if(! $update) {
|
||||
$o .= '<script> $(document).ready(function() { $(\'#nav-community-link\').addClass(\'nav-selected\'); });</script>';
|
||||
$o .= '<div id="live-community"></div>' . "\r\n";
|
||||
$o .= "<script> var profile_uid = -1; var netargs = ''; var profile_page = " . $a->pager['page'] . "; </script>\r\n";
|
||||
$o .= "<script> var profile_uid = -1; var netargs = '/?f='; var profile_page = " . $a->pager['page'] . "; </script>\r\n";
|
||||
}
|
||||
|
||||
if(x($a->data,'search'))
|
||||
|
|
|
@ -704,6 +704,7 @@ function dfrn_notify_post(&$a) {
|
|||
$ev['uid'] = $importer['uid'];
|
||||
$ev['uri'] = $item_id;
|
||||
$ev['edited'] = $datarray['edited'];
|
||||
$ev['private'] = $datarray['private'];
|
||||
|
||||
$r = q("SELECT * FROM `event` WHERE `uri` = '%s' AND `uid` = %d LIMIT 1",
|
||||
dbesc($item_id),
|
||||
|
|
|
@ -297,6 +297,12 @@ function events_content(&$a) {
|
|||
$fhour = ((x($orig_event)) ? datetime_convert('UTC', $tz, $fdt, 'H') : 0);
|
||||
$fminute = ((x($orig_event)) ? datetime_convert('UTC', $tz, $fdt, 'i') : 0);
|
||||
|
||||
$f = get_config('system','event_input_format');
|
||||
if(! $f)
|
||||
$f = 'ymd';
|
||||
|
||||
$dateformat = datesel_format($f);
|
||||
$timeformat = t('hour:minute');
|
||||
|
||||
require_once('include/acl_selectors.php');
|
||||
|
||||
|
@ -306,14 +312,14 @@ function events_content(&$a) {
|
|||
'$cid' => $cid,
|
||||
'$uri' => $uri,
|
||||
'$e_text' => t('Event details'),
|
||||
'$e_desc' => t('Format is year-month-day hour:minute. Starting date and Description are required.'),
|
||||
'$e_desc' => sprintf( t('Format is %s %s. Starting date and Description are required.'),$dateformat,$timeformat),
|
||||
'$s_text' => t('Event Starts:') . ' <span class="required">*</span> ',
|
||||
'$s_dsel' => datesel('start',$syear+5,$syear,false,$syear,$smonth,$sday),
|
||||
'$s_dsel' => datesel($f,'start',$syear+5,$syear,false,$syear,$smonth,$sday),
|
||||
'$s_tsel' => timesel('start',$shour,$sminute),
|
||||
'$n_text' => t('Finish date/time is not known or not relevant'),
|
||||
'$n_checked' => $n_checked,
|
||||
'$f_text' => t('Event Finishes:'),
|
||||
'$f_dsel' => datesel('finish',$fyear+5,$fyear,false,$fyear,$fmonth,$fday),
|
||||
'$f_dsel' => datesel($f,'finish',$fyear+5,$fyear,false,$fyear,$fmonth,$fday),
|
||||
'$f_tsel' => timesel('finish',$fhour,$fminute),
|
||||
'$a_text' => t('Adjust for viewer timezone'),
|
||||
'$a_checked' => $a_checked,
|
||||
|
|
|
@ -123,15 +123,15 @@ function install_content(&$a) {
|
|||
$o .= replace_macros($tpl, array(
|
||||
'$lbl_01' => t('Friendika Social Network'),
|
||||
'$lbl_02' => t('Installation'),
|
||||
'$lbl_03' => t('In order to install Friendika we need to know how to contact your database.'),
|
||||
'$lbl_03' => t('In order to install Friendika we need to know how to connect to your database.'),
|
||||
'$lbl_04' => t('Please contact your hosting provider or site administrator if you have questions about these settings.'),
|
||||
'$lbl_05' => t('The database you specify below must already exist. If it does not, please create it before continuing.'),
|
||||
'$lbl_05' => t('The database you specify below should already exist. If it does not, please create it before continuing.'),
|
||||
'$lbl_06' => t('Database Server Name'),
|
||||
'$lbl_07' => t('Database Login Name'),
|
||||
'$lbl_08' => t('Database Login Password'),
|
||||
'$lbl_09' => t('Database Name'),
|
||||
'$lbl_10' => t('Please select a default timezone for your website'),
|
||||
'$lbl_11' => t('Site administrator email address. Your account email address will need match this.'),
|
||||
'$lbl_11' => t('Site administrator email address. Your account email address must match this in order to use the web admin panel.'),
|
||||
'$baseurl' => $a->get_baseurl(),
|
||||
'$tzselect' => ((x($_POST,'timezone')) ? select_timezone($_POST['timezone']) : select_timezone()),
|
||||
'$submit' => t('Submit'),
|
||||
|
|
|
@ -125,10 +125,11 @@ function network_content(&$a, $update = 0) {
|
|||
|
||||
$o .= '<div id="live-network"></div>' . "\r\n";
|
||||
$o .= "<script> var profile_uid = " . $_SESSION['uid']
|
||||
. "; var netargs = '" . substr($a->cmd,8)
|
||||
. ((x($_GET,'cid')) ? '?cid=' . $_GET['cid'] : '')
|
||||
. ((x($_GET,'search')) ? '?search=' . $_GET['search'] : '')
|
||||
. ((x($_GET,'star')) ? '?star=' . $_GET['star'] : '')
|
||||
. "; var netargs = '" . substr($a->cmd,8)
|
||||
. '?f='
|
||||
. ((x($_GET,'cid')) ? '&cid=' . $_GET['cid'] : '')
|
||||
. ((x($_GET,'search')) ? '&search=' . $_GET['search'] : '')
|
||||
. ((x($_GET,'star')) ? '&star=' . $_GET['star'] : '')
|
||||
. "'; var profile_page = " . $a->pager['page'] . "; </script>\r\n";
|
||||
|
||||
}
|
||||
|
@ -208,7 +209,6 @@ function network_content(&$a, $update = 0) {
|
|||
$sql_extra .= " AND `item`.`body` REGEXP '" . dbesc(escape_tags($_GET['search'])) . "' ";
|
||||
|
||||
|
||||
|
||||
$r = q("SELECT COUNT(*) AS `total`
|
||||
FROM `item` LEFT JOIN `contact` ON `contact`.`id` = `item`.`contact-id`
|
||||
WHERE `item`.`uid` = %d AND `item`.`visible` = 1 AND `item`.`deleted` = 0
|
||||
|
|
|
@ -903,7 +903,7 @@ function photos_content(&$a) {
|
|||
$album = hex2bin($datum);
|
||||
|
||||
$r = q("SELECT `resource-id`, max(`scale`) AS `scale` FROM `photo` WHERE `uid` = %d AND `album` = '%s'
|
||||
$sql_extra GROUP BY `resource-id`",
|
||||
AND `scale` <= 4 $sql_extra GROUP BY `resource-id`",
|
||||
intval($owner_uid),
|
||||
dbesc($album)
|
||||
);
|
||||
|
@ -913,7 +913,7 @@ function photos_content(&$a) {
|
|||
}
|
||||
|
||||
$r = q("SELECT `resource-id`, `id`, `filename`, max(`scale`) AS `scale`, `desc` FROM `photo` WHERE `uid` = %d AND `album` = '%s'
|
||||
$sql_extra GROUP BY `resource-id` ORDER BY `created` DESC LIMIT %d , %d",
|
||||
AND `scale` <= 4 $sql_extra GROUP BY `resource-id` ORDER BY `created` DESC LIMIT %d , %d",
|
||||
intval($owner_uid),
|
||||
dbesc($album),
|
||||
intval($a->pager['start']),
|
||||
|
|
|
@ -21,7 +21,7 @@ function profile_init(&$a) {
|
|||
|
||||
profile_load($a,$which,$profile);
|
||||
|
||||
if((x($a->profile,'page-flags')) && ($a->profile['page-flags'] & PAGE_COMMUNITY)) {
|
||||
if((x($a->profile,'page-flags')) && ($a->profile['page-flags'] == PAGE_COMMUNITY)) {
|
||||
$a->page['htmlhead'] .= '<meta name="friendika.community" content="true" />';
|
||||
}
|
||||
if(x($a->profile,'openidserver'))
|
||||
|
@ -160,7 +160,7 @@ function profile_content(&$a, $update = 0) {
|
|||
if($tab === 'posts') {
|
||||
$o .= '<div id="live-profile"></div>' . "\r\n";
|
||||
$o .= "<script> var profile_uid = " . $a->profile['profile_uid']
|
||||
. "; var netargs = ''; var profile_page = " . $a->pager['page'] . "; </script>\r\n";
|
||||
. "; var netargs = '/?f='; var profile_page = " . $a->pager['page'] . "; </script>\r\n";
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -361,6 +361,9 @@ function profiles_content(&$a) {
|
|||
$a->page['htmlhead'] .= replace_macros($tpl, array('$baseurl' => $a->get_baseurl()));
|
||||
$a->page['htmlhead'] .= "<script type=\"text/javascript\" src=\"include/country.js\" ></script>";
|
||||
|
||||
$f = get_config('system','birthday_input_format');
|
||||
if(! $f)
|
||||
$f = 'ymd';
|
||||
|
||||
$is_default = (($r[0]['is-default']) ? 1 : 0);
|
||||
$tpl = get_markup_template("profile_edit.tpl");
|
||||
|
@ -375,7 +378,7 @@ function profiles_content(&$a) {
|
|||
'$lbl_fullname' => t('Your Full Name:'),
|
||||
'$lbl_title' => t('Title/Description:'),
|
||||
'$lbl_gender' => t('Your Gender:'),
|
||||
'$lbl_bd' => t("Birthday \x28y/m/d\x29:"),
|
||||
'$lbl_bd' => sprintf( t("Birthday \x28%s\x29:"),datesel_format($f)),
|
||||
'$lbl_address' => t('Street Address:'),
|
||||
'$lbl_city' => t('Locality/City:'),
|
||||
'$lbl_zip' => t('Postal/Zip Code:'),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue