diff --git a/public/src/app.js b/public/src/app.js index 8b50d34af6..64dd8378ff 100644 --- a/public/src/app.js +++ b/public/src/app.js @@ -78,12 +78,16 @@ var socket, } } - var post_window = null; - app.open_post_window = function() { + var post_window = null, + mode = 'topic', + topic_id = null; + app.open_post_window = function(post_mode, id) { post_window = post_window || document.getElementById('post_window'); jQuery(post_window).slideToggle(250); document.getElementById('post_title').focus(); + mode = (post_mode == null) ? 'topic' : mode; + topic_id = (mode == 'reply') ? topic_id : null; }; app.post_topic = function() { diff --git a/public/templates/topic.tpl b/public/templates/topic.tpl index 56c230a31f..ed5de86aa8 100644 --- a/public/templates/topic.tpl +++ b/public/templates/topic.tpl @@ -5,4 +5,12 @@
Posted on {posts.timestamp} by user {posts.uid}.
- \ No newline at end of file + +