diff --git a/public/language/en_GB/topic.json b/public/language/en_GB/topic.json index c6fe5bc4ad..1fa24dbe23 100644 --- a/public/language/en_GB/topic.json +++ b/public/language/en_GB/topic.json @@ -86,7 +86,7 @@ "topic_will_be_moved_to": "This topic will be moved to the category", "fork_topic_instruction": "Click the posts you want to fork", "fork_no_pids": "No posts selected!", - "fork_success": "Succesfully forked topic!", + "fork_success": "Succesfully forked topic! Click here to go to the forked topic.", "composer.title_placeholder": "Enter your topic title here...", "composer.discard": "Discard", diff --git a/public/src/forum/topic/fork.js b/public/src/forum/topic/fork.js index 38052fa35b..6c462b4566 100644 --- a/public/src/forum/topic/fork.js +++ b/public/src/forum/topic/fork.js @@ -42,18 +42,26 @@ define('forum/topic/fork', function() { socket.emit('topics.createTopicFromPosts', { title: forkModal.find('#fork-title').val(), pids: pids - }, function(err) { + }, function(err, newTopic) { function fadeOutAndRemove(pid) { $('#post-container li[data-pid="' + pid + '"]').fadeOut(500, function() { $(this).remove(); }); } - if(err) { + if (err) { return app.alertError(err.message); } - app.alertSuccess('[[topic:fork_success]]'); + app.alert({ + timeout: 5000, + title: '[[global:alert.success]]', + message: '[[topic:fork_success]]', + type: 'success', + clickfn: function() { + ajaxify.go('topic/' + newTopic.slug); + } + }); for(var i=0; i