aboutsummaryrefslogtreecommitdiff
path: root/web/post3.js
diff options
context:
space:
mode:
Diffstat (limited to 'web/post3.js')
-rw-r--r--web/post3.js7
1 files changed, 6 insertions, 1 deletions
diff --git a/web/post3.js b/web/post3.js
index 31b3f8f2..3267f9c0 100644
--- a/web/post3.js
+++ b/web/post3.js
@@ -25,7 +25,12 @@ function addLocation() {
}
function addTag(tag) {
- document.forms["postmsg"].body.value='*'+tag+' '+document.forms["postmsg"].body.value;
+ var s = document.forms["postmsg"].body.value;
+ if (s.indexOf ('#') == 0) {
+ document.forms["postmsg"].body.value = s + ' *' + tag;
+ } else {
+ document.forms["postmsg"].body.value = '*' + tag + ' ' + s;
+ }
return false;
}