Moved comment box on photos to be after the last comment, added text for the Preview link

This commit is contained in:
Michael Johnston 2012-10-14 14:30:10 -04:00
parent f5a458d139
commit 939227e820

View file

@ -1447,6 +1447,7 @@ function photos_content(&$a) {
'$myphoto' => $contact['thumb'], '$myphoto' => $contact['thumb'],
'$comment' => t('Comment'), '$comment' => t('Comment'),
'$submit' => t('Submit'), '$submit' => t('Submit'),
'$preview' => t('Preview'),
'$sourceapp' => t($a->sourcename), '$sourceapp' => t($a->sourcename),
'$ww' => '' '$ww' => ''
)); ));
@ -1464,27 +1465,6 @@ function photos_content(&$a) {
$redirect_url = $a->get_baseurl() . '/redir/' . $item['cid'] ; $redirect_url = $a->get_baseurl() . '/redir/' . $item['cid'] ;
if($can_post || can_write_wall($a,$owner_uid)) {
if($item['last-child']) {
$comments .= replace_macros($cmnt_tpl,array(
'$return_path' => '',
'$jsreload' => $return_url,
'$type' => 'wall-comment',
'$id' => $item['item_id'],
'$parent' => $item['parent'],
'$profile_uid' => $owner_uid,
'$mylink' => $contact['url'],
'$mytitle' => t('This is you'),
'$myphoto' => $contact['thumb'],
'$comment' => t('Comment'),
'$submit' => t('Submit'),
'$sourceapp' => t($a->sourcename),
'$ww' => ''
));
}
}
if(local_user() && ($item['contact-uid'] == local_user()) if(local_user() && ($item['contact-uid'] == local_user())
&& ($item['network'] == 'dfrn') && (! $item['self'] )) { && ($item['network'] == 'dfrn') && (! $item['self'] )) {
@ -1522,6 +1502,28 @@ function photos_content(&$a) {
'$drop' => $drop, '$drop' => $drop,
'$comment' => $comment '$comment' => $comment
)); ));
if($can_post || can_write_wall($a,$owner_uid)) {
if($item['last-child']) {
$comments .= replace_macros($cmnt_tpl,array(
'$return_path' => '',
'$jsreload' => $return_url,
'$type' => 'wall-comment',
'$id' => $item['item_id'],
'$parent' => $item['parent'],
'$profile_uid' => $owner_uid,
'$mylink' => $contact['url'],
'$mytitle' => t('This is you'),
'$myphoto' => $contact['thumb'],
'$comment' => t('Comment'),
'$submit' => t('Submit'),
'$preview' => t('Preview'),
'$sourceapp' => t($a->sourcename),
'$ww' => ''
));
}
}
} }
} }