aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorfriendica <info@friendica.com>2012-05-10 20:01:13 -0700
committerfriendica <info@friendica.com>2012-05-10 20:01:13 -0700
commit8a5dcf64d84b98bda80e0346d508efc072c50002 (patch)
treec1c90892400ef5d5916f35e1d65a23b860480875
parent547007e1993a21347db327f5c030dd1dac60f28f (diff)
downloadvolse-hubzilla-8a5dcf64d84b98bda80e0346d508efc072c50002.tar.gz
volse-hubzilla-8a5dcf64d84b98bda80e0346d508efc072c50002.tar.bz2
volse-hubzilla-8a5dcf64d84b98bda80e0346d508efc072c50002.zip
fix PM replies after autocomplete changes
-rw-r--r--mod/message.php9
-rw-r--r--view/theme/duepuntozero/prv_message.tpl4
2 files changed, 10 insertions, 3 deletions
diff --git a/mod/message.php b/mod/message.php
index 29a2fa253..71f83b47a 100644
--- a/mod/message.php
+++ b/mod/message.php
@@ -172,7 +172,7 @@ function message_content(&$a) {
));
$preselect = (isset($a->argv[2])?array($a->argv[2]):false);
-
+
$prename = $preurl = $preid = '';
@@ -188,7 +188,7 @@ function message_content(&$a) {
}
}
- $prefill = (($preselect) ? $prename . ' [' . $preurl . ']' : '');
+ $prefill = (($preselect) ? $prename : '');
// the ugly select box
@@ -198,6 +198,7 @@ function message_content(&$a) {
$o .= replace_macros($tpl,array(
'$header' => t('Send Private Message'),
'$to' => t('To:'),
+ '$showinputs' => 'true',
'$prefill' => $prefill,
'$autocomp' => $autocomp,
'$preid' => $preid,
@@ -376,9 +377,10 @@ function message_content(&$a) {
$seen = $message['seen'];
}
+
+
$select = $message['name'] . '<input type="hidden" name="messageto" value="' . $contact_id . '" />';
$parent = '<input type="hidden" name="replyto" value="' . $message['parent-uri'] . '" />';
-
$tpl = get_markup_template('mail_display.tpl');
$o = replace_macros($tpl, array(
@@ -393,6 +395,7 @@ function message_content(&$a) {
// reply
'$header' => t('Send Reply'),
'$to' => t('To:'),
+ '$showinputs' => '',
'$subject' => t('Subject:'),
'$subjtxt' => template_escape($message['title']),
'$readonly' => ' readonly="readonly" style="background: #BBBBBB;" ',
diff --git a/view/theme/duepuntozero/prv_message.tpl b/view/theme/duepuntozero/prv_message.tpl
index 5d884fe96..b5cda9c85 100644
--- a/view/theme/duepuntozero/prv_message.tpl
+++ b/view/theme/duepuntozero/prv_message.tpl
@@ -8,8 +8,12 @@ $parent
<div id="prvmail-to-label">$to</div>
+{{ if $showinputs }}
<input type="text" id="recip" name="messageto" value="$prefill" maxlength="255" size="64" tabindex="10" />
<input type="hidden" id="recip-complete" name="messageto" value="$preid">
+{{ else }}
+$select
+{{ endif }}
<div id="prvmail-subject-label">$subject</div>
<input type="text" size="64" maxlength="255" id="prvmail-subject" name="subject" value="$subjtxt" $readonly tabindex="11" />