diff --git a/app/views/profile/_more_comments.rhtml b/app/views/profile/_more_comments.rhtml
index 875c1e9..b24637a 100644
--- a/app/views/profile/_more_comments.rhtml
+++ b/app/views/profile/_more_comments.rhtml
@@ -1,3 +1,3 @@
diff --git a/app/views/profile/_more_replies.rhtml b/app/views/profile/_more_replies.rhtml
index 800b608..1043046 100644
--- a/app/views/profile/_more_replies.rhtml
+++ b/app/views/profile/_more_replies.rhtml
@@ -1,3 +1,3 @@
- <%= link_to_remote(_('More'), :url => { :profile => @profile.identifier, :controller => 'profile', :action => 'more_replies', :activity => activity, :comment_page => (comment_page + 1)}) %>
+ <%= link_to(_('More'), :profile => @profile.identifier, :controller => 'profile', :action => 'more_replies', :activity => activity, :comment_page => (comment_page + 1)) %>
diff --git a/app/views/profile/_profile_comments.rhtml b/app/views/profile/_profile_comments.rhtml
index c4a4db1..e010237 100644
--- a/app/views/profile/_profile_comments.rhtml
+++ b/app/views/profile/_profile_comments.rhtml
@@ -5,7 +5,7 @@
<% if activity.comments_count > 0 %>
<% end %>
diff --git a/app/views/profile/_profile_scraps.rhtml b/app/views/profile/_profile_scraps.rhtml
index 2f9564f..aab0f70 100644
--- a/app/views/profile/_profile_scraps.rhtml
+++ b/app/views/profile/_profile_scraps.rhtml
@@ -21,12 +21,12 @@
<% if scrap.replies.count > 0 %>
-
+
<% end %>
<%= render :partial => 'profile_scrap_reply_form', :locals => { :scrap => scrap } %>
-
-
\ No newline at end of file
+
+
diff --git a/public/javascripts/application.js b/public/javascripts/application.js
index 2379353..1b448de 100644
--- a/public/javascripts/application.js
+++ b/public/javascripts/application.js
@@ -853,6 +853,12 @@ Array.min = function(array) {
return Math.min.apply(Math, array);
};
+function hideAndGetUrl(link) {
+ link.hide();
+ url = jQuery(link).attr('href');
+ jQuery.get(url);
+}
+
jQuery(function($){
$('.submit-with-keypress').live('keydown', function(e) {
field = this;
@@ -875,12 +881,21 @@ jQuery(function($){
}
});
- $('.view-all-comments').live('click', function(e) {
- var link = this;
- $(link).parent().find('.profile-wall-activities-comments').show();
- $(link).hide();
+ $('#content').delegate( '.view-all-comments a', 'click', function(e) {
+ hideAndGetUrl(this);
return false;
+ });
+
+ $('#content').delegate('.view-more-replies a', 'click', function(e) {
+ hideAndGetUrl(this);
+ return false;
});
+
+ $('#content').delegate('.view-more-comments a', 'click', function(e) {
+ hideAndGetUrl(this);
+ return false;
+ });
+
$('.focus-on-comment').live('click', function(e) {
var link = this;
$(link).parents('.profile-activity-item').find('textarea').focus();
--
libgit2 0.21.2